IR_sensor.hpp
Go to the documentation of this file.
1 /*
2  * SocialLedge.com - Copyright (C) 2013
3  *
4  * This file is part of free software framework for embedded processors.
5  * You can use it and/or distribute it as long as this copyright header
6  * remains unmodified. The code is free for personal use and requires
7  * permission to use in a commercial product.
8  *
9  * THIS SOFTWARE IS PROVIDED "AS IS". NO WARRANTIES, WHETHER EXPRESS, IMPLIED
10  * OR STATUTORY, INCLUDING, BUT NOT LIMITED TO, IMPLIED WARRANTIES OF
11  * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE APPLY TO THIS SOFTWARE.
12  * I SHALL NOT, IN ANY CIRCUMSTANCES, BE LIABLE FOR SPECIAL, INCIDENTAL, OR
13  * CONSEQUENTIAL DAMAGES, FOR ANY REASON WHATSOEVER.
14  *
15  * You can reach the author of this software at :
16  * p r e e t . w i k i @ g m a i l . c o m
17  */
18 
24 #ifndef IR_SENSOR_HPP_
25 #define IR_SENSOR_HPP_
26 #include <stdint.h>
27 
28 
29 
43 class IR_Sensor : public SingletonTemplate<IR_Sensor>
44 {
45  public:
46  bool init();
47 
49  bool isIRCodeReceived();
50 
52  uint32_t getLastIRCode();
53 
55  void storeIrCode(uint32_t);
56  void decodeIrCode(void);
59  private:
61  IR_Sensor() {}
62  friend class SingletonTemplate<IR_Sensor>;
63 };
64 
65 #endif /* IR_SENSOR_HPP_ */
Definition: IR_sensor.hpp:43
uint32_t getLastIRCode()
Definition: io_source.cpp:217
bool init()
Initializes this device,.
Definition: io_source.cpp:196
void decodeIrCode(void)
Definition: io_source.cpp:167
void storeIrCode(uint32_t)
Definition: io_source.cpp:159
Definition: singleton_template.hpp:55
bool isIRCodeReceived()
Definition: io_source.cpp:213