zephyr::raw

Function k_timer_status_sync

source
pub unsafe extern "C" fn k_timer_status_sync(
    timer: *mut k_timer,
) -> u32
Expand description

@brief Synchronize thread to timer expiration.

This routine blocks the calling thread until the timer’s status is non-zero (indicating that it has expired at least once since it was last examined) or the timer is stopped. If the timer status is already non-zero, or the timer is already stopped, the caller continues without waiting.

Calling this routine resets the timer’s status to zero.

This routine must not be used by interrupt handlers, since they are not allowed to block.

@param timer Address of timer.

@return Timer status.