RDK Documentation (Open Sourced RDK Components)

Description

Data Structures

class  CecIARMMgrFrameListener
 

Macros

#define HEADER_OFFSET   0
 
#define OPCODE_OFFSET   1
 

Functions

int main (int argc, char *argv[])
 
static IARM_Result_t _Send (void *arg)
 This function is used to send the CECFrame if the connection is ready. More...
 
static IARM_Result_t _GetLogicalAddress (void *arg)
 This function is used to get the logical address of CEC devices. More...
 
static IARM_Result_t _AddLogicalAddress (void *arg)
 This function is used to add the logical address of own devices, so driver can ACK while receving direct messages. More...
 
static IARM_Result_t _GetPhysicalAddress (void *arg)
 
static IARM_Result_t _Enable (void *arg)
 This function is used to start or stop the CEC connections. More...
 
static IARM_Result_t _IsAvailable (void *arg)
 
static void _iarmMgrHdmiEventHandler (const char *owner, IARM_EventId_t eventId, void *data, size_t len)
 This funtion is used as hdmi event handler to check the status of HDMI whether it is inserted or ejected during hotplugging. More...
 
static void cecSendEventHandler (const char *owner, IARM_EventId_t eventId, void *data, size_t len)
 This function is used to append the received cec event data to CECFrame structure and sends it out. More...
 
static void cecMgrEventHandler (const char *owner, IARM_EventId_t eventId, void *data, size_t len)
 This function is used to starts the CECIARMMgr instance by calling _Enable function after receiving IARM_BUS_CECMGR_EVENT_ENABLE event. More...
 
static CECIARMMgrCECIARMMgr::getInstance (void)
 This function is used to create instance for CECIARMMgr class. More...
 
IARM_Result_t CECIARMMgr::init (void)
 This function is used to initialize the CEC IARM manager by registering event handlers and function calls through IARM api. More...
 
IARM_Result_t CECIARMMgr::term (void)
 This function is used to terminate the CEC IARM connection. More...
 
IARM_Result_t CECIARMMgr::start (void)
 This function is used to start the connection for cec manager by creating and adding the frame listener and establishing the connection. More...
 
IARM_Result_t CECIARMMgr::loop (void)
 This function is used to check time the HeartBeat occurs. A HeartBeat protocol is generally used to negotiate and monitor the availability of a resource. More...
 
IARM_Result_t CECIARMMgr::stop (void)
 This function is used to stop the cec IARM manager connection. It closes the connection, deletes framelistener, connection and processor instances. More...
 

Variables

static Mutex mutex
 
static bool enabled
 
static volatile Connectionm_connection = 0
 

Data Structure Documentation

◆ CecIARMMgrFrameListener

class CecIARMMgrFrameListener

Definition at line 194 of file CecIARMBusMgr.cpp.

Inheritance diagram for CecIARMMgrFrameListener:
Inheritance graph
Collaboration diagram for CecIARMMgrFrameListener:
Collaboration graph

Public Member Functions

 CecIARMMgrFrameListener (MessageProcessor *processor)
 
void notify (const CECFrame &in) const
 

Private Attributes

MessageProcessorprocessor
 

Function Documentation

◆ _Send()

static IARM_Result_t _Send ( void *  arg)
static

This function is used to send the CECFrame if the connection is ready.

Parameters
[in]argAddress of IARM_Bus_CECMgr_Send_Param_t structure.
Return values
IARM_RESULT_SUCCESSReturns on success condition.
IARM_RESULT_INVALID_STATEReturns on failed connection.

Definition at line 377 of file CecIARMBusMgr.cpp.

◆ _GetLogicalAddress()

static IARM_Result_t _GetLogicalAddress ( void *  arg)
static

This function is used to get the logical address of CEC devices.

Parameters
[in]argAddress of IARM_Bus_CECMgr_Send_Param_t structure, where info about CEC devices are present.
Returns
retCode Returns IARM_RESULT_SUCCESS on success condition and IARM_RESULT_INVALID_STATE on failure condition.

Definition at line 431 of file CecIARMBusMgr.cpp.

◆ _AddLogicalAddress()

static IARM_Result_t _AddLogicalAddress ( void *  arg)
static

This function is used to add the logical address of own devices, so driver can ACK while receving direct messages.

Parameters
[in]argAddress of IARM_Bus_CECMgr_AddLogicalAddress_Param_t structure, the logical address to be added.
Returns
retCode Returns IARM_RESULT_SUCCESS on success condition and IARM_RESULT_INVALID_STATE on failure condition.

Definition at line 460 of file CecIARMBusMgr.cpp.

◆ _Enable()

static IARM_Result_t _Enable ( void *  arg)
static

This function is used to start or stop the CEC connections.

Parameters
[in]argAddress of IARM_Bus_CECMgr_Send_Param_t structure, where info about CEC devices are present.
Returns
Returns IARM_RESULT_SUCCESS on success condition.

Definition at line 510 of file CecIARMBusMgr.cpp.

◆ _iarmMgrHdmiEventHandler()

static void _iarmMgrHdmiEventHandler ( const char *  owner,
IARM_EventId_t  eventId,
void *  data,
size_t  len 
)
static

This funtion is used as hdmi event handler to check the status of HDMI whether it is inserted or ejected during hotplugging.

Parameters
[in]ownerOwner details of the handler.
[in]eventIdEvent type, e.g. Hotplug.
[in]dataDetail about HDMI event.
[in]lenLength of data.
Returns
None

Definition at line 95 of file CecIARMBusMgr.cpp.

◆ cecSendEventHandler()

static void cecSendEventHandler ( const char *  owner,
IARM_EventId_t  eventId,
void *  data,
size_t  len 
)
static

This function is used to append the received cec event data to CECFrame structure and sends it out.

Parameters
[in]ownerOwner details of the handler.
[in]eventIdEvent type, e.g. Hotplug.
[in]dataDetail about HDMI event.
[in]lenLength of data.
Returns
None

Definition at line 151 of file CecIARMBusMgr.cpp.

◆ cecMgrEventHandler()

static void cecMgrEventHandler ( const char *  owner,
IARM_EventId_t  eventId,
void *  data,
size_t  len 
)
static

This function is used to starts the CECIARMMgr instance by calling _Enable function after receiving IARM_BUS_CECMGR_EVENT_ENABLE event.

Parameters
[in]ownerOwner details of the handler.
[in]eventIdEvent type, e.g. Hotplug.
[in]dataDetail about HDMI event.
[in]lenLength of data.
Returns
None

Definition at line 174 of file CecIARMBusMgr.cpp.

◆ getInstance()

CECIARMMgr & CECIARMMgr::getInstance ( void  )
static

This function is used to create instance for CECIARMMgr class.

Returns
instance Instance of CECIARMMgr class.

Definition at line 236 of file CecIARMBusMgr.cpp.

◆ init()

IARM_Result_t CECIARMMgr::init ( void  )

This function is used to initialize the CEC IARM manager by registering event handlers and function calls through IARM api.

Returns
IARM_RESULT_SUCCESS Returns on success condition.

Definition at line 248 of file CecIARMBusMgr.cpp.

◆ term()

IARM_Result_t CECIARMMgr::term ( void  )

This function is used to terminate the CEC IARM connection.

Returns
IARM_RESULT_SUCCESS Returns on success condition.

Definition at line 281 of file CecIARMBusMgr.cpp.

◆ start()

IARM_Result_t CECIARMMgr::start ( void  )

This function is used to start the connection for cec manager by creating and adding the frame listener and establishing the connection.

Return values
IARM_RESULT_SUCCESSReturns on success condition.
IARM_RESULT_INVALID_STATEReturns on failure condition.

Definition at line 295 of file CecIARMBusMgr.cpp.

◆ loop()

IARM_Result_t CECIARMMgr::loop ( void  )

This function is used to check time the HeartBeat occurs. A HeartBeat protocol is generally used to negotiate and monitor the availability of a resource.

Returns
IARM_RESULT_SUCCESS Returns on success condition.

Definition at line 322 of file CecIARMBusMgr.cpp.

◆ stop()

IARM_Result_t CECIARMMgr::stop ( void  )

This function is used to stop the cec IARM manager connection. It closes the connection, deletes framelistener, connection and processor instances.

Returns
IARM_RESULT_SUCCESS Returns on success condition.

Definition at line 341 of file CecIARMBusMgr.cpp.