picofuse

Files | Functions
Sleep and Halt

Pauses execution for a specified duration, or stops it permanently. More...

Collaboration diagram for Sleep and Halt:

Files

file  halt.h
 Defines the sys_halt function.
 

Functions

void sys_halt (void)
 Halts the system and never returns. More...
 
void sys_sleep_ms (uint32_t ms)
 Pauses the current thread for a specified duration. More...
 

Detailed Description

Pauses execution for a specified duration, or stops it permanently.

This file declares functions that pause execution for a specified duration; sys/halt.h declares the counterpart that stops it permanently.

Function Documentation

◆ sys_halt()

void sys_halt ( void  )

Halts the system and never returns.

This function stops normal program execution using the platform-specific halt mechanism. Callers should treat this as terminal control flow.

◆ sys_sleep_ms()

void sys_sleep_ms ( uint32_t  ms)

Pauses the current thread for a specified duration.

Parameters
msThe number of milliseconds to sleep.

This function blocks only the calling thread for approximately the requested duration.