vdr 2.7.3
cLircUsrRemote Class Reference

Public Member Functions

 cLircUsrRemote (const char *DeviceName)
 
- Public Member Functions inherited from cLircRemote
virtual ~cLircRemote ()
 
virtual bool Ready (void)
 
- Public Member Functions inherited from cRemote
virtual ~cRemote ()
 
virtual bool Initialize (void)
 
const char * Name (void)
 
- Public Member Functions inherited from cListObject
 cListObject (void)
 
virtual ~cListObject ()
 
virtual int Compare (const cListObject &ListObject) const
 
void Append (cListObject *Object)
 
void Insert (cListObject *Object)
 
void Unlink (void)
 
int Index (void) const
 
cListObjectPrev (void) const
 
cListObjectNext (void) const
 

Private Types

enum  { LIRC_KEY_BUF = 30 , LIRC_BUFFER_SIZE = 128 }
 

Private Member Functions

bool Connect (void)
 
virtual void Action (void)
 

Private Attributes

struct sockaddr_un addr
 

Additional Inherited Members

- Static Public Member Functions inherited from cLircRemote
static void NewLircRemote (const char *Name)
 
- Static Public Member Functions inherited from cRemote
static void SetLearning (cRemote *Learning)
 
static bool IsLearning ()
 
static bool Enabled (void)
 
static void SetEnabled (bool Enabled)
 
static void Clear (void)
 
static bool Put (eKeys Key, bool AtFront=false)
 
static bool PutMacro (eKeys Key)
 
static bool CallPlugin (const char *Plugin)
 
static const char * GetPlugin (void)
 
static bool HasKeys (void)
 
static eKeys Get (int WaitMs=1000, char **UnknownCode=NULL)
 
static time_t LastActivity (void)
 
static void TriggerLastActivity (void)
 
- Protected Member Functions inherited from cLircRemote
 cLircRemote (const char *Name)
 
- Protected Member Functions inherited from cRemote
 cRemote (const char *Name)
 
const char * GetSetup (void)
 
void PutSetup (const char *Setup)
 
bool Put (uint64_t Code, bool Repeat=false, bool Release=false)
 
bool Put (const char *Code, bool Repeat=false, bool Release=false)
 
- Protected Member Functions inherited from cThread
void SetPriority (int Priority)
 
void SetIOPriority (int Priority)
 
void Lock (void)
 
void Unlock (void)
 
bool Running (void)
 
void Cancel (int WaitSeconds=0)
 
 cThread (const char *Description=NULL, bool LowPriority=false)
 
virtual ~cThread ()
 
void SetDescription (const char *Description,...) __attribute__((format(printf
 
void bool Start (void)
 
bool Active (void)
 
- Static Protected Member Functions inherited from cThread
static tThreadId ThreadId (void)
 
static tThreadId IsMainThread (void)
 
static void SetMainThreadId (void)
 
- Protected Attributes inherited from cLircRemote
int f
 

Detailed Description

Definition at line 27 of file lirc.c.

Member Enumeration Documentation

◆ anonymous enum

anonymous enum
private
Enumerator
LIRC_KEY_BUF 
LIRC_BUFFER_SIZE 

Definition at line 29 of file lirc.c.

Constructor & Destructor Documentation

◆ cLircUsrRemote()

cLircUsrRemote::cLircUsrRemote ( const char * DeviceName)

Definition at line 76 of file lirc.c.

References addr, cLircRemote::cLircRemote(), Connect(), cThread::Start(), and strn0cpy().

Member Function Documentation

◆ Action()

void cLircUsrRemote::Action ( void )
privatevirtual

A derived cThread class must implement the code it wants to execute as a separate thread in this function.

If this is a loop, it must check Running() repeatedly to see whether it's time to stop.

Implements cThread.

Definition at line 104 of file lirc.c.

References Connect(), cTimeMs::Elapsed(), esyslog, cLircRemote::f, cFile::FileReady(), isyslog, LIRC_BUFFER_SIZE, LIRC_KEY_BUF, cRemote::Put(), RECONNECTDELAY, cThread::Running(), safe_read(), cTimeMs::Set(), Setup, cCondWait::SleepMs(), and strn0cpy().

◆ Connect()

bool cLircUsrRemote::Connect ( void )
private

Definition at line 85 of file lirc.c.

References addr, cLircRemote::f, and LOG_ERROR_STR.

Referenced by Action(), and cLircUsrRemote().

Member Data Documentation

◆ addr

struct sockaddr_un cLircUsrRemote::addr
private

Definition at line 30 of file lirc.c.

Referenced by cLircUsrRemote(), and Connect().


The documentation for this class was generated from the following file: