RDK Documentation (Open Sourced RDK Components)
Components_DisplayDevice.h
Go to the documentation of this file.
1 /*
2  * If not stated otherwise in this file or this component's Licenses.txt file the
3  * following copyright and licenses apply:
4  *
5  * Copyright 2016 RDK Management
6  *
7  * Licensed under the Apache License, Version 2.0 (the "License");
8  * you may not use this file except in compliance with the License.
9  * You may obtain a copy of the License at
10  *
11  * http://www.apache.org/licenses/LICENSE-2.0
12  *
13  * Unless required by applicable law or agreed to in writing, software
14  * distributed under the License is distributed on an "AS IS" BASIS,
15  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
16  * See the License for the specific language governing permissions and
17  * limitations under the License.
18 */
19 
20 /**
21  * @file Components_DisplayDevice.h
22  * @brief The header file provides components display device information APIs.
23  */
24 
25 /**
26  * @defgroup TR69_HOSTIF_STBSERVICES_DISPLAYDEVICE TR-069 Object (Device.STBServices.Components.DisplayDevice)
27  * @par Front End objects model network side interfaces.
28  * A Front End acts as an interface between the network and the inner functional blocks of the STB.
29  * The network can be the home network or an external network e.g. DTT, IPTV. Depending on
30  * the network type, connections modelled by Front End objects can be unidirectional e.g. DTT, or
31  * bidirectional IP. An IP Front End can be bi-directional because the STB can be both a content
32  * destination and a content source.
33  *
34  * @note Note that the IP Front End models the STB’s LAN connection and is a logical rather than physical
35  * concept, which means that an STB never has more than one IP Front End, even if it has more
36  * than one LAN IP or physical interfaces. The IP Front End is typically capable of handling multiple
37  * input and output streams at the same time.
38 
39  * @ingroup TR69_HOSTIF_STBSERVICES
40  *
41  * @defgroup TR69_HOSTIF_STBSERVICES_DISPLAYDEVICE_API TR-069 Object (Device.STBServices.Components.DisplayDevice) Public APIs
42  * Describe the details about TR-069 components display device APIs specifications.
43  * @ingroup TR69_HOSTIF_STBSERVICES_DISPLAYDEVICE
44  *
45  * @defgroup TR69_HOSTIF_STBSERVICES_DISPLAYDEVICE_CLASSES TR-069 Object (Device.STBServices.Components.DisplayDevice) Public Classes
46  * Describe the details about classes used in TR069 components display device.
47  * @ingroup TR69_HOSTIF_STBSERVICES_DISPLAYDEVICE
48  */
49 
50 /**
51 * @defgroup tr69hostif
52 * @{
53 * @defgroup hostif
54 * @{
55 **/
56 
57 
58 #ifndef DEVSET_COMP_DISPLAYDEVICE_HPP_
59 #define DEVSET_COMP_DISPLAYDEVICE_HPP_
60 
61 #include "host.hpp"
62 #include "dsTypes.h"
63 #include "videoOutputPortType.hpp"
64 #include "videoDevice.hpp"
65 #include "videoDFC.hpp"
66 #include "manager.hpp"
67 #include "dsUtl.h"
68 #include "dsError.h"
69 #include "list.hpp"
70 #include <exception>
71 #include <string.h>
72 #include "stdlib.h"
73 #include "hostIf_tr69ReqHandler.h"
74 #include "hostIf_updateHandler.h"
75 #include "hostIf_utils.h"
76 #include "videoOutputPort.hpp"
77 
78 #ifndef PARAM_LEN
79 #define PARAM_LEN TR69HOSTIFMGR_MAX_PARAM_LEN
80 #endif
81 
82 #define MAX_RESOLUTION_LENGTH 30
83 #define DISPLAYDEVICE_OBJECT_NAME "DisplayDevice."
84 
85 /**
86  * @brief This class provides the TR-069 components display device information.
87  * @ingroup TR69_HOSTIF_STBSERVICES_DISPLAYDEVICE_CLASSES
88  */
90 {
91 
92  int dev_id;
94 
95  char backupDisplayDeviceStatus[_BUF_LEN_16];
96  char backupEDID[_BUF_LEN_256];
97  char backupEDIDBytes[_BUF_LEN_256];
98  char backupSupportedResolution[_BUF_LEN_16];
99  char backupPreferredResolution[_BUF_LEN_16];
100 
101  bool bCalledDisplayDeviceStatus;
102  bool bCalledEDID;
103  bool bCalledEDIDBytes;
104  bool bCalledSupportedResolution;
105  bool bCalledPreferredResolution;
106 
107  int getStatus(HOSTIF_MsgData_t *stMsgData,bool *pChanged = NULL);
108  int getEDID_BYTES(HOSTIF_MsgData_t *stMsgData,bool *pChanged = NULL);
109  int getX_COMCAST_COM_EDID(HOSTIF_MsgData_t *stMsgData,bool *pChanged = NULL);
110  int getSupportedResolutions(HOSTIF_MsgData_t *stMsgData,bool *pChanged = NULL);
111  int getPreferredResolution(HOSTIF_MsgData_t *stMsgData,bool *pChanged = NULL);
112 
113 public:
115  void doUpdates(const char *baseName, updateCallback mUpdateCallback);
116  int handleSetMsg(const char *paramName, HOSTIF_MsgData_t *stMsgData);
117  int handleGetMsg(const char *paramName, HOSTIF_MsgData_t *stMsgData);
119 
120 };
121 
122 #endif /* DEVSET_COMP_DISPLAYDEVICE_HPP_ */
123 
124 
125 /** @} */
126 /** @} */
hostIf_STBServiceDisplayDevice::doUpdates
void doUpdates(const char *baseName, updateCallback mUpdateCallback)
This function updates the hostIf display device interface attribute value such as Status,...
Definition: Components_DisplayDevice.cpp:200
device::VideoOutputPort
Class extending enumerable to implement the videoooutputport interface.
Definition: videoOutputPort.hpp:59
dsTypes.h
Device Settings HAL types.
manager.hpp
It contains class referenced by manager.cpp file.
hostIf_STBServiceDisplayDevice
This class provides the TR-069 components display device information.
Definition: Components_DisplayDevice.h:89
_HostIf_MsgData_t
Definition: hostIf_tr69ReqHandler.h:170
dsError.h
Device Settings HAL error codes.
dsUtl.h
Device Settings HAL utilities.
videoOutputPortType.hpp
It contains structures and class referenced by the videoOutputportTypes.cpp file.
hostIf_STBServiceDisplayDevice::hostIf_STBServiceDisplayDevice
hostIf_STBServiceDisplayDevice(int devId, device::VideoOutputPort &port)
Class Constructor of the class hostIf_STBServiceDisplayDevice.
Definition: Components_DisplayDevice.cpp:61
videoDevice.hpp
It contains class referenced by videoDevice.cpp file.
videoOutputPort.hpp
It contains class and structure refrenced by the videooutputport.cpp file.
hostIf_STBServiceDisplayDevice::handleGetMsg
int handleGetMsg(const char *paramName, HOSTIF_MsgData_t *stMsgData)
This function get the display device interface attribute value such as Status, EDID,...
Definition: Components_DisplayDevice.cpp:132
hostIf_STBServiceDisplayDevice::handleSetMsg
int handleSetMsg(const char *paramName, HOSTIF_MsgData_t *stMsgData)
This function set the display device interface attribute value such as Status, EDID,...
Definition: Components_DisplayDevice.cpp:111
videoDFC.hpp
This file defines VideoDFC class for managing video decoder format conversion types.