DevSlashLirc
|
This abstract class contains the common functionality of the derived classes. More...
#include <LircDevice.h>
Public Member Functions | |
bool | close () |
virtual | ~LircDevice () |
bool | isValid () const |
milliseconds_t | getBeginTimeout () const |
void | setBeginTimeout (milliseconds_t timeout) |
virtual void | report (std::ostream &stream=std::cout) const |
Prints a listing of the properties implemented on the stream supplied. More... | |
virtual bool | isMode2 () const =0 |
virtual bool | isLircCode () const =0 |
bool | canSend () const |
bool | canSetTransmitterMask () const |
bool | canRec () const |
bool | canSetRecTimeout () const |
bool | canSendPulse () const |
bool | canSendLircCode () const |
bool | canRecMode2 () const |
bool | canRecLircCode () const |
unsigned | getNumberTransmitters () const |
Return the number of transmitters as reported from the device. More... | |
int | setTransmitterMask (uint32_t mask) |
Enable the set of transmitters specified in val, which contains a bit mask where each enabled transmitter is a 1. More... | |
int | setRecTimeout (int arg) |
Set the integer value for IR inactivity timeout (microseconds). More... | |
int | setRecTimeoutReports (bool enable) |
Enable or disable timeout packages. More... | |
Static Public Attributes | |
static const char * | version = "LircDevice " VERSION |
static const char * | defaultFilename = "/dev/lirc0" |
static const milliseconds_t | defaultBeginTimeout = 5000U |
static const uint32_t | INVALID = UINT32_MAX |
Protected Member Functions | |
void | report (const char *name, bool value, std::ostream &stream) const |
bool | reportValidity (std::ostream &stream=std::cout) const |
int | ioctl (uint32_t cmd, uint32_t arg) |
bool | canDo (uint32_t mask) const |
LircDevice (const char *path=defaultFilename, milliseconds_t beginTimeout=defaultBeginTimeout) | |
LircDevice (const LircDevice &orig) | |
virtual bool | open () |
Protected Attributes | |
bool | valid |
const char * | fileName |
int | fileDescriptor |
unsigned | numberTransmitters |
uint32_t | recordingMode |
uint32_t | features |
milliseconds_t | beginTimeout |
Static Protected Attributes | |
static const bool | longReport = false |
Flag indicating how to format reports. More... | |
This abstract class contains the common functionality of the derived classes.
It opens a file system device, per default /dev/lirc0, as described in lirc(4).
Definition at line 24 of file LircDevice.h.
|
protected |
Definition at line 18 of file LircDevice.cpp.
|
protected |
Definition at line 68 of file LircDevice.cpp.
|
virtual |
Definition at line 78 of file LircDevice.cpp.
|
inlineprotected |
Definition at line 42 of file LircDevice.h.
|
inline |
Definition at line 78 of file LircDevice.h.
|
inline |
Definition at line 85 of file LircDevice.h.
|
inline |
Definition at line 84 of file LircDevice.h.
|
inline |
Definition at line 76 of file LircDevice.h.
|
inline |
Definition at line 83 of file LircDevice.h.
|
inline |
Definition at line 82 of file LircDevice.h.
|
inline |
Definition at line 79 of file LircDevice.h.
|
inline |
Definition at line 77 of file LircDevice.h.
bool LircDevice::close | ( | ) |
Definition at line 82 of file LircDevice.cpp.
|
inline |
Definition at line 59 of file LircDevice.h.
|
inline |
Return the number of transmitters as reported from the device.
Definition at line 92 of file LircDevice.h.
|
protected |
Definition at line 98 of file LircDevice.cpp.
|
pure virtual |
Implemented in Mode2LircDevice, and LircCodeLircDevice.
|
pure virtual |
Implemented in Mode2LircDevice, and LircCodeLircDevice.
|
inline |
Definition at line 57 of file LircDevice.h.
|
protectedvirtual |
Reimplemented in Mode2LircDevice, and LircCodeLircDevice.
Definition at line 21 of file LircDevice.cpp.
|
protected |
Definition at line 102 of file LircDevice.cpp.
|
virtual |
Prints a listing of the properties implemented on the stream supplied.
stream |
Reimplemented in Mode2LircDevice, and LircCodeLircDevice.
Definition at line 110 of file LircDevice.cpp.
|
protected |
Definition at line 138 of file LircDevice.cpp.
|
inline |
Definition at line 63 of file LircDevice.h.
|
inline |
Set the integer value for IR inactivity timeout (microseconds).
To be accepted, the value must be within the limits defined by LIRC_GET_MIN_TIMEOUT and LIRC_GET_MAX_TIMEOUT. A value of 0 (if supported by the hardware) disables all hardware timeouts and data should be reported as soon as possible. If the exact value cannot be set, then the next possible value greater than the given value should be set.
Definition at line 116 of file LircDevice.h.
|
inline |
Enable or disable timeout packages.
By default, timeout reports should be turned off.
Definition at line 124 of file LircDevice.h.
|
inline |
Enable the set of transmitters specified in val, which contains a bit mask where each enabled transmitter is a 1.
The first transmitter is encoded by the least significant bit, and so on. When an invalid bit mask is given, for example a bit is set even though the device does not have so many transmitters, this operation returns the number of available transmitters and does nothing otherwise.
Definition at line 103 of file LircDevice.h.
|
protected |
Definition at line 35 of file LircDevice.h.
|
static |
Definition at line 52 of file LircDevice.h.
|
static |
Definition at line 51 of file LircDevice.h.
|
protected |
Definition at line 34 of file LircDevice.h.
|
protected |
Definition at line 31 of file LircDevice.h.
|
protected |
Definition at line 30 of file LircDevice.h.
|
static |
Definition at line 53 of file LircDevice.h.
|
staticprotected |
Flag indicating how to format reports.
Definition at line 27 of file LircDevice.h.
|
protected |
Definition at line 32 of file LircDevice.h.
|
protected |
Definition at line 33 of file LircDevice.h.
|
protected |
Definition at line 29 of file LircDevice.h.
|
static |
Definition at line 50 of file LircDevice.h.