Available Languages?:

OSA : OS_Wait_TO

OS_Wait_TO (condition, timeout)

Allowed only in taskSwitches contextUses timer

Wait until condition is true. If timeout expires before this event occurs, then stop waiting with Timeout flag set (see OS_IsTimeout)

Call allowed:

Only in task


condition Any boolean expression
timeout Time of waiting in system ticks - calling OS_Timer periods


timeout If timeout expired then system service OS_IsTimeout will return true


void Task (void)
    for (;;) {
        OS_Wait_TO(RB1 == 1, 50);  // Wait 50 ticks for RB1 == 1
        if (!OS_IsTimeout()) {

Old style name



See also

en/osa/ref/allservices/os_wait_to.txt · Last modified: 07.10.2010 13:58 (external edit)
Creative Commons License Powered by PHP Valid XHTML 1.0 Valid CSS Driven by DokuWiki