muwerk Timeout Class 
Implements a helper class for handling timeouts in milliseconds. See ustd::utimeout for a high precision implmentation with microsecond resolution.
The following example based on a reconnection timeout illustrates the usage of this class:
#include <scheduler.h>
#include <timeout>
 
 
void appLoop();
 
void someTask() {
    
    
 
    state == getCurrentState();
 
    if ( state == RECONNECTING ) {
        if ( connectTimeout.
test() ) {
 
            
            DBG("Failed to connect");
            
        }
    } else if ( state == CONNECTED ) {
 
    } else if ( state == DISCONNECTED ) {
        state == RECONNECTING
        
    }
}
 
void setup() {
    
    int tID = sched.
add(appLoop, 
"main");
 
 
    
    sched.
add(someTask, 
"someTask", 50000L);
 
}
muwerk Scheduler Class
Definition scheduler.h:199
 
int add(T_TASK task, String name, unsigned long minMicroSecs=100000L, T_PRIO prio=PRIO_NORMAL)
Definition scheduler.h:475
 
muwerk Timeout Class
Definition timeout.h:59
 
void reset()
Definition timeout.h:94
 
bool test() const
Definition timeout.h:87