Welcome to the EyeBot  Version 7 - RPi1
A Controller For Various Hardware IO
irtv.h
Go to the documentation of this file.
1 
7 #ifndef IRTV_H_
8 #define IRTV_H_
9 
10 #include "spi.h"
11 #include <lirc/lirc_client.h>
12 
13 
14 //IR remote control button defines
15 // Define name char config file name
16 #define IR_KEY_1 '1' //KEY_1
17 #define IR_KEY_2 '2' //KEY_2
18 #define IR_KEY_3 '3' //KEY_3
19 #define IR_KEY_4 '4' //KEY_4
20 #define IR_KEY_5 '5' //KEY_5
21 #define IR_KEY_6 '6' //KEY_6
22 #define IR_KEY_7 '7' //KEY_7
23 #define IR_KEY_8 '8' //KEY_8
24 #define IR_KEY_9 '9' //KEY_9
25 #define IR_KEY_0 '0' //KEY_0
26 #define IR_KEY_RED 'R' //KEY_RED
27 #define IR_KEY_GREEN 'G' //KEY_GREEN
28 #define IR_KEY_YELLOW 'Y' //KEY_YELLOW
29 #define IR_KEY_BLUE 'B' //KEY_BLUE
30 #define IR_KEY_LEFT 'L' //KEY_LEFT
31 #define IR_KEY_RIGHT '>' //KEY_RIGHT
32 #define IR_KEY_UP 'U' //KEY_UP
33 #define IR_KEY_DOWN 'D' //KEY_DOWN
34 #define IR_KEY_OK 'O' //KEY_OK
35 #define IR_KEY_POWER 'P' //KEY_POWER
36 
37 void* IRTVThread;
38 
39 int IRTVInit(int semantics);
40 int IRTVGet(void);
41 void IRTVRelease(void);
42 int IRTVGetStatus(void);
43 int IRTVGetControllerCode();
44 void IRTVSetControllerCode(int semantics);
45 void IRTVSetHoldDelay(int delay);
46 
47 void *IRTVInputThread(void *data);
48 
49 //new functions
50 int IRTVRead(void); // Non-blocking read, return 0 if nothing
51 int IRTVFlush(void); // Empty IRTV buffers
52 
53 #endif /* IRTV_H_ */
void IRTVSetHoldDelay(int delay)
sets the hold to prevent multiple presses being registered when a IR remote button is pressed ...
Definition: irtv.c:233
int IRTVGetStatus(void)
Checks to see if IR input is enabled;.
Definition: irtv.c:212
int IRTVInit(int semantics)
Initializes the IR remote control decoder by calling IRTVInit() with the device name found in the cor...
Definition: irtv.c:23
void IRTVRelease(void)
Terminates the remote control decoder and releases the irtv thread.
Definition: irtv.c:190
int IRTVGet(void)
Waits for IR input and returns the keycode.
Definition: irtv.c:140