Skip to content

Commit 68a53d9

Browse files
authored
Merge pull request rdkcentral#59 from rdkcentral/sprint/24Q4
rebase with latest
2 parents 530a27e + 46fe14e commit 68a53d9

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

63 files changed

+11014
-474
lines changed

.github/workflows/L1-tests.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -211,6 +211,7 @@ jobs:
211211
pkg.h
212212
secure_wrapper.h
213213
wpa_ctrl.h
214+
btmgr.h
214215
&&
215216
cp -r /usr/include/gstreamer-1.0/gst /usr/include/glib-2.0/* /usr/lib/x86_64-linux-gnu/glib-2.0/include/* /usr/local/include/trower-base64/base64.h .
216217
@@ -294,6 +295,7 @@ jobs:
294295
-DPLUGIN_TEXTTOSPEECH=ON
295296
-DPLUGIN_SYSTEMAUDIOPLAYER=ON
296297
-DPLUGIN_MIRACAST=ON
298+
-DPLUGIN_BLUETOOTH=ON
297299
-DCMAKE_BUILD_TYPE=${{env.BUILD_TYPE}}
298300
&&
299301
cmake --build build/rdkservices -j8

.github/workflows/L2-tests-R4-4-1.yml

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -281,7 +281,11 @@ jobs:
281281
-DDS_FOUND=ON
282282
-DPLUGIN_ANALYTICS=ON
283283
-DPLUGIN_ANALYTICS_SIFT_BACKEND=ON
284-
-DCMAKE_BUILD_TYPE=${{env.BUILD_TYPE}}
284+
-DPLUGIN_ANALYTICS_SIFT_2_0_ENABLED="true"
285+
-DPLUGIN_ANALYTICS_SIFT_MAX_RANDOMISATION_WINDOW_TIME=15
286+
-DPLUGIN_ANALYTICS_SIFT_STORE_PATH="/tmp/AnalyticsSiftStore"
287+
-DPLUGIN_ANALYTICS_SIFT_URL="127.0.0.1:12345"
288+
-DPLUGIN_ANALYTICS_EVENTS_MAP="/tmp/AnalyticsEventsMap.json"
285289
&&
286290
cmake --build build/rdkservices -j8
287291
&&

AVOutput/AVOutputTV.cpp

Lines changed: 13 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -375,13 +375,6 @@ namespace Plugin {
375375
}
376376
else {
377377
LOGINFO("Platform Init successful...\n");
378-
ret = TvSyncCalibrationInfoODM();
379-
if(ret != tvERROR_NONE) {
380-
LOGERR(" SD3 <->cri_data sync failed, ret: %s \n", getErrorString(ret).c_str());
381-
}
382-
else {
383-
LOGERR(" SD3 <->cri_data sync success, ret: %s \n", getErrorString(ret).c_str());
384-
}
385378
}
386379

387380
tvVideoFormatCallbackData callbackData = {this,tvVideoFormatChangeHandler};
@@ -2280,28 +2273,32 @@ namespace Plugin {
22802273

22812274
uint32_t AVOutputTV::getSupportedDolbyVisionModes(const JsonObject& parameters, JsonObject& response)
22822275
{
2283-
22842276
LOGINFO("Entry\n");
2285-
pic_modes_t *dvModes;
2277+
tvDolbyMode_t dvModes[tvMode_Max];
2278+
tvDolbyMode_t *dvModesPtr = dvModes; // Pointer to statically allocated tvDolbyMode_t array
22862279
unsigned short totalAvailable = 0;
2287-
tvError_t ret = GetTVSupportedDolbyVisionModesODM(&dvModes,&totalAvailable);
2280+
2281+
// Set an initial value to indicate the mode type
2282+
dvModes[0] = tvDolbyMode_Dark;
2283+
2284+
tvError_t ret = GetTVSupportedDolbyVisionModes(&dvModesPtr, &totalAvailable);
22882285
if(ret != tvERROR_NONE) {
22892286
returnResponse(false);
22902287
}
22912288
else {
22922289
JsonArray SupportedDVModes;
22932290

22942291
for(int count = 0;count <totalAvailable;count++ ) {
2295-
SupportedDVModes.Add(dvModes[count].name);
2292+
SupportedDVModes.Add(getDolbyModeStringFromEnum(dvModes[count]));
22962293
}
22972294

22982295
response["supportedDVModes"] = SupportedDVModes;
22992296
LOGINFO("Exit\n");
23002297
returnResponse(true);
23012298
}
2302-
23032299
}
23042300

2301+
23052302
uint32_t AVOutputTV::getDolbyVisionMode(const JsonObject& parameters, JsonObject& response)
23062303
{
23072304
LOGINFO("Entry");
@@ -2376,7 +2373,7 @@ namespace Plugin {
23762373

23772374
if( isSetRequired("Current",source,"DV") ) {
23782375
LOGINFO("Proceed with setDolbyVisionMode\n\n");
2379-
ret = SetTVDolbyVisionModeODM(value.c_str());
2376+
ret = SetTVDolbyVisionMode(GetDolbyVisionEnumFromModeString(value.c_str()));
23802377
}
23812378

23822379
if(ret != tvERROR_NONE) {
@@ -2437,7 +2434,7 @@ namespace Plugin {
24372434
if( err == 0 ) {
24382435
std::string dolbyModeValue = getDolbyModeStringFromEnum((tvDolbyMode_t)dolbyMode);
24392436
LOGINFO("%s : getLocalparam success format :%d source : %d format : %d dolbyvalue : %s\n",__FUNCTION__,formatIndex, sourceIndex, pqIndex, dolbyModeValue.c_str());
2440-
ret = SetTVDolbyVisionModeODM(dolbyModeValue.c_str());
2437+
ret = SetTVDolbyVisionMode((tvDolbyMode_t)dolbyMode);
24412438
}
24422439
else {
24432440
LOGERR("%s : GetLocalParam Failed \n",__FUNCTION__);
@@ -2822,7 +2819,7 @@ namespace Plugin {
28222819
if ( tr181Success == err ) {
28232820
//get curren source and if matches save for that alone
28242821
tvVideoSrcType_t current_source = VIDEO_SOURCE_IP;
2825-
GetCurrentSource(&current_source);
2822+
GetCurrentVideoSource(&current_source);
28262823

28272824
tvVideoFormatType_t current_format = VIDEO_FORMAT_NONE;
28282825
GetCurrentVideoFormat(&current_format);
@@ -3077,7 +3074,7 @@ namespace Plugin {
30773074
LOGINFO("Entry\n");
30783075
tvVideoSrcType_t currentSource = VIDEO_SOURCE_IP;
30793076

3080-
tvError_t ret = GetCurrentSource(&currentSource);
3077+
tvError_t ret = GetCurrentVideoSource(&currentSource);
30813078
if(ret != tvERROR_NONE) {
30823079
response["currentVideoSource"] = "NONE";
30833080
returnResponse(false);

AVOutput/AVOutputTV.h

Lines changed: 49 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,8 @@
2222

2323
#include "string.h"
2424
#include <set>
25+
#include <boost/filesystem.hpp>
26+
#include <boost/property_tree/ini_parser.hpp>
2527

2628
#include "tvTypes.h"
2729
#include "tvSettings.h"
@@ -67,6 +69,49 @@
6769
#define STRING_DEFAULT "Default"
6870
#define STRING_SOURCE "Source."
6971
#define CREATE_DIRTY(__X__) (__X__+=STRING_DIRTY)
72+
#define CAPABLITY_FILE_NAME "pq_capabilities.ini"
73+
74+
75+
class CIniFile
76+
{
77+
std::string m_path;
78+
std::string opt_path;
79+
boost::property_tree::ptree m_data;
80+
81+
public:
82+
CIniFile(const std::string & filename, const std::string & filepath = "/etc/" )
83+
{
84+
opt_path = "/opt/panel/";
85+
m_path = filepath;
86+
m_path.append(filename);
87+
opt_path.append(filename);
88+
89+
if(!boost::filesystem::exists( opt_path)) {
90+
std::cout << "AVOutput : Using " << m_path <<std::endl;
91+
boost::property_tree::ini_parser::read_ini(m_path, m_data);
92+
}
93+
else {
94+
std::cout << "AVOutput : Using " << opt_path << std::endl;
95+
boost::property_tree::ini_parser::read_ini(opt_path, m_data);
96+
}
97+
}
98+
99+
~CIniFile()
100+
{
101+
}
102+
103+
template <typename T>
104+
T Get(const std::string & key)
105+
{
106+
return m_data.get<T>(key);
107+
}
108+
109+
template <typename T>
110+
void Set(const std::string & key, const T & value){
111+
//TODO DD: Not required currently
112+
//m_data.put(key, value);
113+
}
114+
};
70115

71116
namespace WPEFramework {
72117
namespace Plugin {
@@ -217,10 +262,14 @@ class AVOutputTV : public AVOutputBase {
217262
tvError_t getParamsCaps(std::vector<std::string> &range, std::vector<std::string> &pqmode, std::vector<std::string> &source,
218263
std::vector<std::string> &format,std::string param , std::string & isPlatformSupport,
219264
std::vector<std::string> & index);
265+
int GetPanelID(char *panelid);
266+
int ConvertHDRFormatToContentFormat(tvhdr_type_t hdrFormat);
267+
int ReadCapablitiesFromConf(std::string &rangeInfo,std::string &pqmodeInfo,std::string &formatInfo,std::string &sourceInfo,std::string param, std::string & isPlatformSupport, std::string & indexInfo);
220268
void getDimmingModeStringFromEnum(int value, std::string &toStore);
221269
void getColorTempStringFromEnum(int value, std::string &toStore);
222270
int getCurrentPictureMode(char *picMode);
223271
int getDolbyParamToSync(int sourceIndex, int formatIndex, int& value);
272+
tvDolbyMode_t GetDolbyVisionEnumFromModeString(const char* modeString);
224273
std::string getDolbyModeStringFromEnum( tvDolbyMode_t mode);
225274
JsonArray getSupportedVideoSource(void);
226275
int getAvailableCapabilityModesWrapper(std::string param, std::string & outparam);

0 commit comments

Comments
 (0)