OSDN Git Service

Update lejos_osek to nxtOSEK_v205b0.zip
[nxt-jsp/etrobo-atk.git] / nxtOSEK / lejos_nxj / src / nxtvm / javavm / poll.h
1 /**
2  * poll.h
3  * Contains conterparts of special classes as C structs.
4  */
5  
6 #ifndef _POLL_H
7 #define _POLL_H
8
9 #include "constants.h"
10 #include "classes.h"
11
12 /**
13  * Poll class native structure
14  */
15 typedef struct S_Poll
16 {
17   Object _super;             // Superclass object storage
18   JSHORT changed;            // Mask of inputs that have changed
19 } Poll;
20
21 extern void set_poller(Poll*);
22 extern void poll_inputs();
23
24 extern Poll *poller;
25 extern byte throttle;
26 extern byte throttle_count;
27
28 static inline void init_poller()
29 {
30   poller = (Poll *)null;
31   throttle = 1;
32   throttle_count = 1;
33 }
34
35 #endif // _POLL_H