Skip to content

Commit 11b35c0

Browse files
committed
RDKEMW-1015 : HDMICEC SINK COMRPC
1 parent 47cc33e commit 11b35c0

File tree

2 files changed

+3
-85
lines changed

2 files changed

+3
-85
lines changed

HdmiCecSink/HdmiCecSink.cpp

Lines changed: 2 additions & 84 deletions
Original file line numberDiff line numberDiff line change
@@ -19,98 +19,14 @@
1919

2020
#include "HdmiCecSink.h"
2121

22-
#include "ccec/Connection.hpp"
23-
#include "ccec/CECFrame.hpp"
24-
#include "ccec/MessageEncoder.hpp"
25-
#include "host.hpp"
26-
#include "UtilsgetRFCConfig.h"
27-
28-
#include "dsMgr.h"
29-
#include "dsRpc.h"
30-
#include "dsDisplay.h"
31-
#include "videoOutputPort.hpp"
32-
#include "manager.hpp"
33-
#include "websocket/URL.h"
34-
3522
#include "UtilsIarm.h"
3623
#include "UtilsJsonRpc.h"
3724
#include "UtilssyncPersistFile.h"
3825
#include "UtilsSearchRDKProfile.h"
3926

40-
#define HDMICECSINK_METHOD_SET_ENABLED "setEnabled"
41-
#define HDMICECSINK_METHOD_GET_ENABLED "getEnabled"
42-
#define HDMICECSINK_METHOD_OTP_SET_ENABLED "setOTPEnabled"
43-
#define HDMICECSINK_METHOD_OTP_GET_ENABLED "getOTPEnabled"
44-
#define HDMICECSINK_METHOD_SET_OSD_NAME "setOSDName"
45-
#define HDMICECSINK_METHOD_GET_OSD_NAME "getOSDName"
46-
#define HDMICECSINK_METHOD_SET_VENDOR_ID "setVendorId"
47-
#define HDMICECSINK_METHOD_GET_VENDOR_ID "getVendorId"
48-
#define HDMICECSINK_METHOD_PRINT_DEVICE_LIST "printDeviceList"
49-
#define HDMICECSINK_METHOD_SET_ACTIVE_PATH "setActivePath"
50-
#define HDMICECSINK_METHOD_SET_ROUTING_CHANGE "setRoutingChange"
51-
#define HDMICECSINK_METHOD_GET_DEVICE_LIST "getDeviceList"
52-
#define HDMICECSINK_METHOD_GET_ACTIVE_SOURCE "getActiveSource"
53-
#define HDMICECSINK_METHOD_SET_ACTIVE_SOURCE "setActiveSource"
54-
#define HDMICECSINK_METHOD_GET_ACTIVE_ROUTE "getActiveRoute"
55-
#define HDMICECSINK_METHOD_SET_MENU_LANGUAGE "setMenuLanguage"
56-
#define HDMICECSINK_METHOD_REQUEST_ACTIVE_SOURCE "requestActiveSource"
57-
#define HDMICECSINK_METHOD_SETUP_ARC "setupARCRouting"
58-
#define HDMICECSINK_METHOD_REQUEST_SHORT_AUDIO_DESCRIPTOR "requestShortAudioDescriptor"
59-
#define HDMICECSINK_METHOD_SEND_STANDBY_MESSAGE "sendStandbyMessage"
60-
#define HDMICECSINK_METHOD_SEND_AUDIO_DEVICE_POWER_ON "sendAudioDevicePowerOnMessage"
61-
#define HDMICECSINK_METHOD_SEND_KEY_PRESS "sendKeyPressEvent"
62-
#define HDMICECSINK_METHOD_SEND_USER_CONTROL_PRESSED "sendUserControlPressed"
63-
#define HDMICECSINK_METHOD_SEND_USER_CONTROL_RELEASED "sendUserControlReleased"
64-
#define HDMICECSINK_METHOD_SEND_GIVE_AUDIO_STATUS "sendGetAudioStatusMessage"
65-
#define HDMICECSINK_METHOD_GET_AUDIO_DEVICE_CONNECTED_STATUS "getAudioDeviceConnectedStatus"
66-
#define HDMICECSINK_METHOD_REQUEST_AUDIO_DEVICE_POWER_STATUS "requestAudioDevicePowerStatus"
67-
#define HDMICECSINK_METHOD_SET_LATENCY_INFO "setLatencyInfo"
68-
69-
#define TEST_ADD 0
70-
#define HDMICECSINK_REQUEST_MAX_RETRY 3
71-
#define HDMICECSINK_REQUEST_MAX_WAIT_TIME_MS 2000
72-
#define HDMICECSINK_PING_INTERVAL_MS 10000
73-
#define HDMICECSINK_WAIT_FOR_HDMI_IN_MS 1000
74-
#define HDMICECSINK_REQUEST_INTERVAL_TIME_MS 500
75-
#define HDMICECSINK_NUMBER_TV_ADDR 2
76-
#define HDMICECSINK_UPDATE_POWER_STATUS_INTERVA_MS (60 * 1000)
77-
#define HDMISINK_ARC_START_STOP_MAX_WAIT_MS 4000
78-
#define HDMICECSINK_UPDATE_AUDIO_STATUS_INTERVAL_MS 500
79-
80-
81-
#define SAD_FMT_CODE_AC3 2
82-
#define SAD_FMT_CODE_ENHANCED_AC3 10
83-
84-
#define SYSTEM_AUDIO_MODE_ON 0x01
85-
#define SYSTEM_AUDIO_MODE_OFF 0x00
86-
#define AUDIO_DEVICE_POWERSTATE_OFF 1
87-
88-
#define DEFAULT_VIDEO_LATENCY 100
89-
#define DEFAULT_LATENCY_FLAGS 3
90-
#define DEFAULT_AUDIO_OUTPUT_DELAY 100
91-
92-
//Device Type is TV - Bit 7 is set to 1
93-
#define ALL_DEVICE_TYPES 128
94-
95-
//RC Profile of TV is 3 - Typical TV Remote
96-
#define RC_PROFILE_TV 10
97-
98-
//Device Features supported by TV - ARC Tx
99-
#define DEVICE_FEATURES_TV 4
10027

10128
#define TR181_HDMICECSINK_CEC_VERSION "Device.DeviceInfo.X_RDKCENTRAL-COM_RFC.Feature.HdmiCecSink.CECVersion"
10229

103-
enum {
104-
DEVICE_POWER_STATE_ON = 0,
105-
DEVICE_POWER_STATE_OFF = 1
106-
};
107-
108-
109-
#define CEC_SETTING_ENABLED_FILE "/opt/persistent/ds/cecData_2.json"
110-
#define CEC_SETTING_OTP_ENABLED "cecOTPEnabled"
111-
#define CEC_SETTING_ENABLED "cecEnabled"
112-
#define CEC_SETTING_OSD_NAME "cecOSDName"
113-
#define CEC_SETTING_VENDOR_ID "cecVendorId"
11430

11531
#define API_VERSION_NUMBER_MAJOR 1
11632
#define API_VERSION_NUMBER_MINOR 3
@@ -193,6 +109,8 @@ namespace WPEFramework
193109
return ;
194110
}
195111

112+
bool success = false;
113+
196114
HdmiCecSink::_hdmiCecSink->SetEnabled(false,success);
197115

198116
if(nullptr != _hdmiCecSink)

HdmiCecSink/HdmiCecSink.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -197,7 +197,7 @@ namespace WPEFramework {
197197
void ShortAudiodescriptorEvent(Exchange::IHdmiCecSink::IHdmiCecSinkShortAudioDescriptorIterator* const& ShortAudioDescriptor) override
198198
{
199199
LOGINFO("ShortAudiodescriptorEvent");
200-
Exchange::JHdmiCecSink::Event::ShortAudiodescriptorEvent(_parent, ShortAudioDescriptor);
200+
Exchange::JHdmiCecSink::Event::ShortAudiodescriptorEvent(_parent, &ShortAudioDescriptor);
201201
}
202202

203203
void StandbyMessageReceived(const int logicalAddress) override

0 commit comments

Comments
 (0)