IARM_BUS_UIEventSimulator.c
void sendKeyEventToIARM(int keyType, int keyCode)
{
	
#ifdef TRACE
	printf("[FUNC] %s [LINE] %d\n", __FUNCTION__, __LINE__);
#endif

	printf("Sending Key (%x, %x) from %s\r\n", keyType, keyCode, executableName);
	IARM_Bus_IRMgr_EventData_t eventData;
        eventData.data.irkey.keyType = keyType;
        eventData.data.irkey.keyCode = keyCode;
        eventData.data.irkey.isFP = 0;
        IARM_Bus_BroadcastEvent(IARM_BUS_IRMGR_NAME, (IARM_EventId_t) IARM_BUS_IRMGR_EVENT_IRKEY, (void *)&eventData, sizeof(eventData));
#if defined _SKQ_KEY_MAP_1_
        uinput_dispatcher_t dispatcher = UINPUT_GetDispatcher();
        /*Time being replacing scan code with 0 to run the functionality*/
        uinput_dispatcherScancode_t dispatcherScancode = UINPUT_GetDispatcherScancode ();
        int uScanCode = KED_UNDEFINEDKEY;
        getScanCode (keyCode, &uScanCode);
        dispatcherScancode (uScanCode, keyCode, keyType, 0);
#endif /*End of _SKQ_KEY_MAP_1_*/

}
/**
 * @brief send the key type and key code to IARM
 *
 */
@brief send the key type and key code to IARM
@brief send the key type and key code to IARM
void sendKeyEventToIARM(int keyType, int keyCode)
{
#ifdef TRACE
	printf("[FUNC] %s [LINE] %d\n", __FUNCTION__, __LINE__);
#endif
	printf("Sending Key (%x, %x) from %s\r\n", keyType, keyCode, executableName);
	IARM_Bus_IRMgr_EventData_t eventData;
        eventData.data.irkey.keyType = keyType;
        eventData.data.irkey.keyCode = keyCode;
        eventData.data.irkey.isFP = 0;
        IARM_Bus_BroadcastEvent(IARM_BUS_IRMGR_NAME, (IARM_EventId_t) IARM_BUS_IRMGR_EVENT_IRKEY, (void *)&eventData, sizeof(eventData));
#if defined _SKQ_KEY_MAP_1_
        uinput_dispatcher_t dispatcher = UINPUT_GetDispatcher();
        uinput_dispatcherScancode_t dispatcherScancode = UINPUT_GetDispatcherScancode ();
        int uScanCode = KED_UNDEFINEDKEY;
        getScanCode (keyCode, &uScanCode);
        dispatcherScancode (uScanCode, keyCode, keyType, 0);
#endif 
}
void sendKeyEventToIARM ( int keyType , int keyCode ) { #ifdef TRACE printf ( " \n " , __FUNCTION__ , __LINE__ ) ; #endif printf ( " \r \n " , keyType , keyCode , executableName ) ; IARM_Bus_IRMgr_EventData_t eventData ; eventData . data . irkey . keyType = keyType ; eventData . data . irkey . keyCode = keyCode ; eventData . data . irkey . isFP = 0 ; IARM_Bus_BroadcastEvent ( IARM_BUS_IRMGR_NAME , ( IARM_EventId_t ) IARM_BUS_IRMGR_EVENT_IRKEY , ( void * ) & eventData , sizeof ( eventData ) ) ; #if defined _SKQ_KEY_MAP_1_ uinput_dispatcher_t dispatcher = UINPUT_GetDispatcher ( ) ; uinput_dispatcherScancode_t dispatcherScancode = UINPUT_GetDispatcherScancode ( ) ; int uScanCode = KED_UNDEFINEDKEY ; getScanCode ( keyCode , & uScanCode ) ; dispatcherScancode ( uScanCode , keyCode , keyType , 0 ) ; #endif }
@brief send the key type and key code to IARM
@brief send the key type and key code to IARM
/*Time being replacing scan code with 0 to run the functionality*/ /*End of _SKQ_KEY_MAP_1_*/