#ifndef __VHEX_KEYBOARD_KEYVENT__ # define __VHEX_KEYBOARD_KEYVENT__ #include //--- // Event-level functions //--- /* keyvent_poll(): Poll the next keyboard event This function returns the next event from the event queue, chronologically. If no event is available, it returns a dummy event with type=KEYEV_NONE and time set to the current driver time. This function always returns events with mod=0. */ extern key_event_t keyvent_poll(void); /* waitevent(): Wait for the next keyboard event This function works as pollevent() but waits if no event is available. When timeout=NULL, it waits indefinitely. Otherwise, it waits until *timeout becomes non-zero (by using a timer for exemple). */ extern key_event_t keyvent_wait(volatile int *timeout); /* clearevents(): Clear all events waiting in the queue */ extern void keyvent_clear(void); #endif /* __VHEX_KEYBOARD_KEYVENT__ */