|
RDK Documentation (Open Sourced RDK Components)
|
43 #include "ccec/LibCCEC.hpp"
44 #include "ccec/Exception.hpp"
46 #include "ccec/Driver.hpp"
54 extern char _CEC_LOG_PREFIX[64];
72 : initialized(false), connected(false)
92 strncpy(_CEC_LOG_PREFIX, name,
sizeof(_CEC_LOG_PREFIX) - 2);
93 _CEC_LOG_PREFIX[
sizeof(_CEC_LOG_PREFIX) - 1] =
'\0';
96 _CEC_LOG_PREFIX[0] =
'\0';
100 Driver::getInstance().open();
119 Driver::getInstance().close();
138 Driver::getInstance().addLogicalAddress(source);
155 int logicalAddress = 0;
160 logicalAddress = Driver::getInstance().getLogicalAddress(devType);
162 if(0 == logicalAddress)
168 return logicalAddress;
171 void LibCCEC::getPhysicalAddress(
unsigned int *physicalAddress)
178 Driver::getInstance().getPhysicalAddress(physicalAddress);
void stop(void)
This function stops the reader & writer threads and removes the instance for Bus.
static LibCCEC & getInstance(void)
This function is used to create the instance for CEC.
void init(const char *name=0)
This function is used to initialize CEC by starting the driver and doing host-specific initialization...
static Bus & getInstance(void)
This function is used to create the instance of Bus class.
This file defines interface of Thread class.
LibCCEC(void)
This is Constructor for LibCEC class. It initializes variables with default values.
int addLogicalAddress(const LogicalAddress &source)
This function is used to add logical address to the driver, so that it can ACK if there a direct mess...
void start(void)
This function starts the threads and gets the instance for Bus.
int getLogicalAddress(int devType)
This function is used to get CEC device logical address starting the connection.
This file defines interface of Mutex class.
void term(void)
This function is used to stop CEC by terminating the connection and stoping the driver.