RDK Documentation (Open Sourced RDK Components)
Device_MoCA_Interface.cpp
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 2018 RDK Management
6  * Copyright 2018 Broadcom Inc.
7  *
8  * Licensed under the Apache License, Version 2.0 (the "License");
9  * you may not use this file except in compliance with the License.
10  * You may obtain a copy of the License at
11  *
12  * http://www.apache.org/licenses/LICENSE-2.0
13  *
14  * Unless required by applicable law or agreed to in writing, software
15  * distributed under the License is distributed on an "AS IS" BASIS,
16  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
17  * See the License for the specific language governing permissions and
18  * limitations under the License.
19 */
20 
21 /**
22  * @file Device_MoCA_Interface.c
23  *
24  * @brief MoCA_Interface API Implementation.
25  *
26  * This is the implementation of the MoCA_Interface API.
27  *
28  * @par Document
29  * TBD Relevant design or API documentation.
30  *
31  */
32 
33 /** @addtogroup MoCA_Interface Implementation
34  * This is the implementation of the Device Public API.
35  * @{
36  */
37 
38 /*****************************************************************************
39  * STANDARD INCLUDE FILES
40  *****************************************************************************/
41 
42 #include <string.h>
43 #include <math.h>
44 
45 #include "Device_MoCA_Interface.h"
46 #include "rdk_moca_hal.h"
47 
48 #define MOCA_INTERFACE_NUMBER_OF_ENTRIES 1
49 #define MAX_WAIT_FOR_RMH_SECONDS 10
50 #define HIGHEST_MOCA_VERSION 0X20
51 
52 MoCADevice* MoCADevice::Instance = NULL;
53 std::mutex MoCADevice::m_mutex;
54 
55 
56 MoCADevice* MoCADevice::getInstance()
57 {
58  if(!Instance) {
59  Instance = new MoCADevice();
60  }
61  return Instance;
62 }
63 
64 void* MoCADevice::getRmhContext()
65 {
66  std::lock_guard<std::mutex> lock(m_mutex);
67  /* Initialized the RMH Context */
68  static RMH_Handle rmhContext = NULL;
69  uint32_t waitedSeconds = 0;
70  bool alwayRecreate = true; /* XITHREE-7905 */
71 
72  if (alwayRecreate && rmhContext) {
73  RMH_Destroy(rmhContext);
74  rmhContext=NULL;
75  }
76 
77  /* If we have an RMH handle, ensure it's still valid */
78  if (rmhContext) {
79  RMH_Result ret = RMH_ValidateHandle(rmhContext);
80  if (ret == RMH_UNIMPLEMENTED || ret == RMH_NOT_SUPPORTED) {
81  RDK_LOG(RDK_LOG_WARN,LOG_TR69HOSTIF,"RMH_ValidateHandle returned %s. We will not be able to monitor to make sure the handle remains valid\n", RMH_ResultToString(ret));
82  }
83  else if (ret != RMH_SUCCESS) {
84  RDK_LOG(RDK_LOG_INFO,LOG_TR69HOSTIF,"The RMH handle %p seems to no longer be valid. Closing\n", rmhContext);
85  RMH_Destroy(rmhContext);
86  rmhContext=NULL;
87  }
88  }
89 
90  /* If we don't have an RMH handle, create one*/
91  while (rmhContext == NULL) {
92  rmhContext = RMH_Initialize(NULL, NULL);
93  if(NULL != rmhContext) {
94  RDK_LOG(RDK_LOG_INFO,LOG_TR69HOSTIF,"Created RMH handle %p\n", rmhContext);
95  break;
96  }
97 
98  if (waitedSeconds >= MAX_WAIT_FOR_RMH_SECONDS) {
99  RDK_LOG(RDK_LOG_ERROR,LOG_TR69HOSTIF,"(%s) Maximum wait for MoCA reached. Skipping RMH Initialization.!\n", __FUNCTION__);
100  //throw 1; Leading to program termination. Better to return failure rather than terminating process to allow access to other profiles.
101  break;
102  }
103 
104  RDK_LOG(RDK_LOG_WARN,LOG_TR69HOSTIF,"(%s)Failed in RMH_Initialize. Assuming MoCA isn't ready. Waiting...\n", __FUNCTION__);
105  usleep(1*1000000);
106  waitedSeconds++;
107  }
108 
109  return rmhContext;
110 }
111 
112 void* MoCADevice::closeRmhContext() {
113  RMH_Handle rmhContext = (RMH_Handle)getRmhContext();
114  if(rmhContext) {
115  RMH_Destroy(rmhContext);
116  }
117 }
118 
119 
120 
121 void MoCADevice::closeInstance()
122 {
123  closeRmhContext();
124 }
125 
126 int MoCAInterface::get_Associated_Device_NumberOfEntries(int &numDevices)
127 {
128  int nodeCount = 0;
129  int retval = NOK;
130 
131  RMH_Handle rmh=(RMH_Handle)MoCADevice::getRmhContext();
132 
133  if (rmh) {
134  RMH_NodeList_Uint32_t response;
135  RMH_Result ret = RMH_Network_GetAssociatedIds(rmh, &response);
136  if (ret != RMH_SUCCESS) {
137  RDK_LOG(RDK_LOG_ERROR,LOG_TR69HOSTIF,"[%s:%u] RMH_Network_GetAssociatedIds failed with result %s.\n", __FUNCTION__, __LINE__, RMH_ResultToString(ret));
138  return retval;
139  }
140  else {
141  for (int nodeId = 0; nodeId < RMH_MAX_MOCA_NODES; nodeId++) {
142  if (true ==response.nodePresent[nodeId]) {
143  nodeCount++;
144  }
145  }
146  }
147  }
148  if(nodeCount) {
149  numDevices = nodeCount;
150  m_ui32AssociatedDeviceNumberOfEntries = nodeCount;
151  retval = OK;
152  }
153  return retval;
154 }
155 
156 
157 int MoCAInterface::get_MoCA_Mesh_NumberOfEntries(int &numOfEntries)
158 {
159  int nodeCount = 0;
160  int retval = NOK;
161 
162  RMH_Handle rmh=(RMH_Handle)MoCADevice::getRmhContext();
163 
164  if (rmh) {
165  RMH_NodeList_Uint32_t response;
166  RMH_Result ret = RMH_Network_GetNodeIds(rmh, &response);
167  if (ret != RMH_SUCCESS) {
168  RDK_LOG(RDK_LOG_ERROR,LOG_TR69HOSTIF,"[%s:%u] RMH_Network_GetNodeIds failed with result %s.\n", __FUNCTION__, __LINE__, RMH_ResultToString(ret));
169  return retval;
170  }
171  else {
172  for (int nodeId = 0; nodeId < RMH_MAX_MOCA_NODES; nodeId++) {
173  if (true ==response.nodePresent[nodeId]) {
174  nodeCount++;
175  }
176  }
177  }
178  }
179 
180  if(nodeCount) {
181  m_ui32X_RDKCENTRAL_COM_MeshTableNumberOfEntries = (int)((int)pow(nodeCount, 2) - (nodeCount));
182  numOfEntries = m_ui32X_RDKCENTRAL_COM_MeshTableNumberOfEntries;
183  retval = OK;
184  }
185 
186  RDK_LOG(RDK_LOG_DEBUG,LOG_TR69HOSTIF,"[%s:%s] MoCA Mesh number of entries : [%u]\n", __FILE__, __FUNCTION__, numOfEntries);
187  RDK_LOG(RDK_LOG_TRACE1,LOG_TR69HOSTIF,"[%s:%s] Exit \n", __FILE__, __FUNCTION__);
188  return retval;
189 }
190 
191 GHashTable* MoCAInterface::m_notifyHash = NULL;
192 GMutex* MoCAInterface::m_mutex = NULL;
193 MoCAInterface* MoCAInterface::Instance = NULL;
194 
195 MoCAInterface::MoCAInterface(int dev_id):
196  m_i32Dev_id(dev_id),
197  m_i32CurNumOfDevices(0),
198  m_bEnable(false),
199  m_ui32LastChange(0),
200  m_bUpStream(false),
201  m_ui32MaxBitRate(0),
202  m_ui32MaxIngressBW(0),
203  m_ui32MaxEgressBW(0),
204  m_HighestVersion(0),
205  m_ui32NetworkCoordinator(0),
206  m_ui32NodeId(0),
207  m_bMaxNodes(false),
208  m_bPreferredNC(false),
209  m_ui32BackupNC(0),
210  m_bPrivacyEnabledSetting(false),
211  m_bPrivacyEnabled(false),
212  m_ui32CurrentOperFreq(0),
213  m_ui32LastOperFreq(0),
214  m_ui32TxPowerLimit(0),
215  m_ui32PowerCntlPhyTarget(0),
216  m_ui32BeaconPowerLimit(0),
217  m_ui32TxBcastRate(0),
218  m_ui32TxBcastPowerReduction(0),
219  m_bQAM256Capable(false),
220  m_ui32PacketAggregationCapability(0),
221  m_ui32AssociatedDeviceNumberOfEntries(0),
222  m_ui32X_RDKCENTRAL_COM_MeshTableNumberOfEntries(0)
223 {
224  memset(m_i8Alias, 0,N_LENGTH);
225  memset(m_i8Name, 0, N_LENGTH);
226  memset(m_i8LowerLayers, 0,LL_LENGTH);
227  memset(m_i8FreqCapabilityMask, 0, FREQ_LENGTH);
228  memset(m_i8NetworkTabooMask, 0, FREQ_LENGTH);
229  memset(m_i8NodeTabooMask, 0, FREQ_LENGTH);
230 }
231 
232 MoCAInterface* MoCAInterface::getInstance(int _dev_Id)
233 {
234  if(NULL == Instance) {
235  Instance = new MoCAInterface(0);
236  }
237  return Instance;
238 }
239 
240 void MoCAInterface::closeInstance()
241 {
242  if(Instance) {
243  delete Instance;
244  }
245 }
246 
247 void MoCAInterface::getLock()
248 {
249  if(!m_mutex)
250  {
251  m_mutex = g_mutex_new();
252  }
253  g_mutex_lock(m_mutex);
254 }
255 
256 void MoCAInterface::releaseLock()
257 {
258  g_mutex_unlock(m_mutex);
259 }
260 
261 GHashTable* MoCAInterface::getNotifyHash()
262 {
263  if(m_notifyHash)
264  {
265  return m_notifyHash;
266  }
267  else
268  {
269  return m_notifyHash = g_hash_table_new(g_str_hash, g_str_equal);
270  }
271 }
272 
273 
274 /****************************************************************************************************************************************************/
275 // Device.MoCA.Interface Table Profile. Getters:
276 /****************************************************************************************************************************************************/
277 
279 {
280  RDK_LOG(RDK_LOG_TRACE1,LOG_TR69HOSTIF,"[%s:%s] Entering..\n", __FUNCTION__, __FILE__);
281  put_int(stMsgData->paramValue,MOCA_INTERFACE_NUMBER_OF_ENTRIES);
282  stMsgData->paramtype=hostIf_IntegerType;
283  RDK_LOG(RDK_LOG_DEBUG,LOG_TR69HOSTIF,"[%s:%s] MOCA_INTERFACE_NUMBER_OF_ENTRIES :%d\n", __FUNCTION__, __FILE__, MOCA_INTERFACE_NUMBER_OF_ENTRIES);
284  stMsgData->paramLen=sizeof(unsigned int);
285  //RDK_LOG(RDK_LOG_TRACE1,LOG_TR69HOSTIF,"[%s:%s] Exiting..\n", __FUNCTION__, __FILE__);
286  return OK;
287 }
288 
289 int MoCAInterface::get_Enable(HOSTIF_MsgData_t *stMsgData, bool *pChanged)
290 {
291  RDK_LOG(RDK_LOG_TRACE1,LOG_TR69HOSTIF,"[%s:%s] Entering..\n", __FUNCTION__, __FILE__);
292 
293  stMsgData->paramtype = hostIf_BooleanType;
294  stMsgData->paramLen=sizeof(bool);
295 
296  const RMH_Handle rmh = (RMH_Handle)MoCADevice::getRmhContext();
297  if(rmh) {
298  bool enable = false;
299  RMH_Result ret = RMH_Self_GetEnabled(rmh, &enable);
300  if (ret == RMH_SUCCESS) {
301  put_boolean(stMsgData->paramValue, enable);
302  m_bEnable = enable;
303  RDK_LOG(RDK_LOG_DEBUG,LOG_TR69HOSTIF,"[%s:%u] RMH_Self_GetLinkStatus success with result %s value %d. \n", __FUNCTION__, __LINE__, RMH_ResultToString(ret), enable );
304  }
305  }
306  RDK_LOG(RDK_LOG_TRACE1,LOG_TR69HOSTIF,"[%s:%s] Exiting..\n", __FUNCTION__, __FILE__);
307  return OK;
308 }
309 
310 int MoCAInterface::get_Status(HOSTIF_MsgData_t *stMsgData, bool *pChanged)
311 {
312  stMsgData->paramtype = hostIf_StringType;
313  const RMH_Handle rmh = (RMH_Handle)MoCADevice::getRmhContext();
314  if(rmh) {
315  RMH_LinkStatus status;
316  RMH_Result ret = RMH_Self_GetLinkStatus(rmh, &status);
317  if (ret == RMH_SUCCESS) {
318 
319  switch (status) {
320  case RMH_LINK_STATUS_DISABLED:
321  snprintf(stMsgData->paramValue, TR69HOSTIFMGR_MAX_PARAM_LEN-1, "%s", "Disable");
322  break;
323  case RMH_LINK_STATUS_NO_LINK:
324  snprintf(stMsgData->paramValue, TR69HOSTIFMGR_MAX_PARAM_LEN-1, "%s", "LowerLayerDown");
325  break;
326  case RMH_LINK_STATUS_INTERFACE_DOWN:
327  snprintf(stMsgData->paramValue, TR69HOSTIFMGR_MAX_PARAM_LEN-1, "%s", "Down");
328  break;
329  case RMH_LINK_STATUS_UP:
330  snprintf(stMsgData->paramValue, TR69HOSTIFMGR_MAX_PARAM_LEN-1, "%s", "Up");
331  break;
332  default:
333  snprintf(stMsgData->paramValue, TR69HOSTIFMGR_MAX_PARAM_LEN-1, "%s","Dormant");
334  break;
335  }
336 
337  RDK_LOG(RDK_LOG_DEBUG,LOG_TR69HOSTIF,"[%s:%u] RMH_Self_GetLinkStatus success with result %s value %s. \n", __FUNCTION__, __LINE__, RMH_ResultToString(ret), RMH_LinkStatusToString(status));
338  stMsgData->paramLen = strlen(stMsgData->paramValue);
339  }
340  else {
341  RDK_LOG(RDK_LOG_ERROR,LOG_TR69HOSTIF,"[%s:%u] RMH_Self_GetLinkStatus failed with result %s.\n", __FUNCTION__, __LINE__, RMH_ResultToString(ret));
342  return NOK;
343  }
344  }
345  return OK;
346 }
347 
348 int MoCAInterface::get_Alias(HOSTIF_MsgData_t *stMsgData, bool *pChanged)
349 {
350  snprintf(stMsgData->paramValue, N_LENGTH-1, "cpe-%s", m_i8Alias);
351  stMsgData->paramLen = strlen(stMsgData->paramValue);
352  return OK;
353 }
354 
355 int MoCAInterface::get_Name(HOSTIF_MsgData_t *stMsgData, bool *pChanged)
356 {
357  const RMH_Handle rmh = (RMH_Handle)MoCADevice::getRmhContext();
358  if(rmh) {
359  int resBufSize = 20;
360  char responseBuf[resBufSize];
361 
362  RMH_Result ret = RMH_Interface_GetName(rmh,responseBuf, resBufSize);
363  if (ret == RMH_SUCCESS) {
364  snprintf(stMsgData->paramValue, TR69HOSTIFMGR_MAX_PARAM_LEN-1, "%s", responseBuf );
365  stMsgData->paramLen = strlen(stMsgData->paramValue);
366  RDK_LOG(RDK_LOG_DEBUG,LOG_TR69HOSTIF,"[%s:%u] RMH_Interface_GetName success with result %s value %s. \n", __FUNCTION__, __LINE__, RMH_ResultToString(ret), responseBuf);
367  }
368  else {
369  RDK_LOG(RDK_LOG_ERROR,LOG_TR69HOSTIF,"[%s:%u] RMH_Interface_GetName failed with result %s.\n", __FUNCTION__, __LINE__, RMH_ResultToString(ret));
370  return NOK;
371  }
372  }
373  stMsgData->paramtype = hostIf_StringType;
374  return OK;
375 }
376 
377 int MoCAInterface::get_LastChange(HOSTIF_MsgData_t *stMsgData, bool *pChanged)
378 {
379  int retval = NOK;
380  stMsgData->paramtype = hostIf_UnsignedIntType;
381  stMsgData->paramLen=sizeof(unsigned int);
382  const RMH_Handle rmh = (RMH_Handle)MoCADevice::getRmhContext();
383  if(rmh) {
384  uint32_t ui32Response = 0;
385  RMH_Result ret = RMH_Network_GetLinkUptime(rmh,&ui32Response);
386  if (ret == RMH_SUCCESS) {
387  RDK_LOG(RDK_LOG_DEBUG,LOG_TR69HOSTIF,"[%s:%u] RMH_Network_GetLinkUptime success with result %s and value as %d. \n", __FUNCTION__, __LINE__, RMH_ResultToString(ret), ui32Response);
388  put_int(stMsgData->paramValue,ui32Response);
389  retval = OK;
390  }
391  else {
392  RDK_LOG(RDK_LOG_ERROR,LOG_TR69HOSTIF,"[%s:%u] RMH_Network_GetLinkUptime failed with result %s.\n", __FUNCTION__, __LINE__, RMH_ResultToString(ret));
393  }
394  }
395  return retval;
396 }
397 
398 int MoCAInterface::get_LowerLayers(HOSTIF_MsgData_t *stMsgData, bool *pChanged)
399 {
400  /*Retrieving value */
401  // Implementation for SOC vendor
402  // value->out_cval =
403  return OK;
404 }
405 int MoCAInterface::get_Upstream(HOSTIF_MsgData_t *stMsgData, bool *pChanged)
406 {
407  /* As per Broadband refer: http://www.broadband-forum.org/cwmp/tr-181-2-2-0.html#D.Device.MoCA.Interface.{i}.Upstream
408  * Indicates whether the interface points towards the Internet (true) or towards End Devices (false).
409  * For example:
410  * For an Internet Gateway Device, Upstream will be true for all WAN interfaces and false for all LAN interfaces.
411  * For a standalone WiFi Access Point that is connected via Ethernet to an Internet Gateway Device, Upstream will
412  * be true for the Ethernet interface and false for the WiFi Radio interface.
413  * For an End Device, Upstream will be true for all interfaces.
414  */
415  bool bUpsteam = false;
416  bUpsteam = (m_bEnable)?true:false;
417  put_boolean(stMsgData->paramValue, bUpsteam);
418  stMsgData->paramtype = hostIf_BooleanType;
419  stMsgData->paramLen=1;
420  //RDK_LOG(RDK_LOG_TRACE1,LOG_TR69HOSTIF,"[%s:%s] Exiting..", __FUNCTION__, __FILE__);
421  return OK;
422 }
423 int MoCAInterface::get_MACAddress(HOSTIF_MsgData_t *stMsgData, bool *pChanged)
424 {
425  int retval = NOK;
426 
427  const RMH_Handle rmh = (RMH_Handle)MoCADevice::getRmhContext();
428 
429  if(rmh) {
430  RMH_MacAddress_t response;
431  RMH_Result ret = RMH_Interface_GetMac(rmh, &response);
432 
433  if (ret == RMH_SUCCESS) {
434  char macBuff[18] = {'\0'};
435  RMH_MacToString(response, macBuff, sizeof(macBuff));
436  RDK_LOG(RDK_LOG_DEBUG, LOG_TR69HOSTIF,"[%s:%u] RMH_Interface_GetMac success with result %s value %s. \n", __FUNCTION__, __LINE__, RMH_ResultToString(ret), macBuff);
437  snprintf(stMsgData->paramValue, TR69HOSTIFMGR_MAX_PARAM_LEN-1, "%s", macBuff);
438  stMsgData->paramLen = strlen(macBuff);
439  retval = OK;
440  }
441  else {
442  RDK_LOG(RDK_LOG_ERROR,LOG_TR69HOSTIF,"[%s:%u] RMH_Interface_GetMac failed with result %s.\n", __FUNCTION__, __LINE__, RMH_ResultToString(ret));
443  }
444  }
445  stMsgData->paramtype = hostIf_StringType;
446  return retval;
447 }
449 {
450  int retval = NOK;
451  const RMH_Handle rmh = (RMH_Handle)MoCADevice::getRmhContext();
452 
453  if(rmh) {
454  int resBufSize = 20;
455  char responseBuf[resBufSize];
456 
457  RMH_Result ret = RMH_Self_GetSoftwareVersion(rmh,responseBuf, resBufSize);
458  if (ret == RMH_SUCCESS) {
459  snprintf(stMsgData->paramValue, TR69HOSTIFMGR_MAX_PARAM_LEN-1, "%s", responseBuf );
460  stMsgData->paramLen = strlen(stMsgData->paramValue);
461  RDK_LOG(RDK_LOG_ERROR,LOG_TR69HOSTIF,"[%s:%u] RMH_Self_GetSoftwareVersion success with result %s value %s. \n", __FUNCTION__, __LINE__, RMH_ResultToString(ret), responseBuf );
462  retval = OK;
463  }
464  else {
465  RDK_LOG(RDK_LOG_ERROR,LOG_TR69HOSTIF,"[%s:%u] RMH_Self_GetSoftwareVersion failed with result %s.\n", __FUNCTION__, __LINE__, RMH_ResultToString(ret));
466  }
467  }
468  stMsgData->paramtype = hostIf_StringType;
469  return retval;
470 }
471 int MoCAInterface::get_MaxBitRate(HOSTIF_MsgData_t *stMsgData, bool *pChanged)
472 {
473  int retval = NOK;
474  stMsgData->paramtype = hostIf_UnsignedIntType;
475  stMsgData->paramLen=sizeof(unsigned int);
476  const RMH_Handle rmh = (RMH_Handle)MoCADevice::getRmhContext();
477  if(rmh) {
478  uint32_t ui32Response = 0;
479  RMH_Result ret = RMH_Self_GetMaxBitrate(rmh,&ui32Response);
480  if (ret == RMH_SUCCESS) {
481  RDK_LOG(RDK_LOG_DEBUG,LOG_TR69HOSTIF,"[%s:%u] RMH_Self_GetMaxBitrate success with result %s and value as %d. \n", __FUNCTION__, __LINE__, RMH_ResultToString(ret), ui32Response);
482  put_int(stMsgData->paramValue,ui32Response);
483  retval = OK;
484  }
485  else {
486  RDK_LOG(RDK_LOG_ERROR,LOG_TR69HOSTIF,"[%s:%u] RMH_Self_GetMaxBitrate failed with result %s.\n", __FUNCTION__, __LINE__, RMH_ResultToString(ret));
487  }
488  }
489  return retval;
490 }
491 int MoCAInterface::get_MaxIngressBW(HOSTIF_MsgData_t *stMsgData, bool *pChanged)
492 {
493  int retval = NOK;
494  stMsgData->paramtype = hostIf_UnsignedIntType;
495  stMsgData->paramLen=sizeof(unsigned int);
496  const RMH_Handle rmh = (RMH_Handle)MoCADevice::getRmhContext();
497  if(rmh) {
498  uint32_t ui32Response = 0;
499  RMH_Result ret = RMH_PQOS_GetMaxIngressFlows(rmh,&ui32Response);
500 
501  if (ret == RMH_SUCCESS) {
502  RDK_LOG(RDK_LOG_DEBUG,LOG_TR69HOSTIF,"[%s:%u] RMH_PQOS_GetMaxIngressFlows success with result %s and value as %d. \n", __FUNCTION__, __LINE__, RMH_ResultToString(ret), ui32Response);
503  put_int(stMsgData->paramValue,ui32Response);
504  retval = OK;
505  }
506  else {
507  RDK_LOG(RDK_LOG_ERROR,LOG_TR69HOSTIF,"[%s:%u] RMH_PQOS_GetMaxIngressFlows failed with result %s.\n", __FUNCTION__, __LINE__, RMH_ResultToString(ret));
508  }
509  }
510  return retval;
511 }
512 
513 int MoCAInterface::get_MaxEgressBW(HOSTIF_MsgData_t *stMsgData, bool *pChanged)
514 {
515  int retval = NOK;
516  stMsgData->paramtype = hostIf_UnsignedIntType;
517  stMsgData->paramLen=sizeof(unsigned int);
518  const RMH_Handle rmh = (RMH_Handle)MoCADevice::getRmhContext();
519  if(rmh) {
520  uint32_t ui32Response;
521  RMH_Result ret = RMH_PQoS_GetMaxEgressBandwidth(rmh, &ui32Response);
522 
523  if (ret == RMH_SUCCESS) {
524  RDK_LOG(RDK_LOG_DEBUG,LOG_TR69HOSTIF,"[%s:%u] RMH_PQoS_GetMaxEgressBandwidth success with result %s and value as %d. \n", __FUNCTION__, __LINE__, RMH_ResultToString(ret), ui32Response);
525  put_int(stMsgData->paramValue,ui32Response);
526  retval = OK;
527  }
528  else {
529  RDK_LOG(RDK_LOG_ERROR,LOG_TR69HOSTIF,"[%s:%u] RMH_PQoS_GetMaxEgressBandwidth failed with result %s.\n", __FUNCTION__, __LINE__, RMH_ResultToString(ret));
530  }
531  }
532  return retval;
533 }
535 {
536  int retval = NOK;
537  stMsgData->paramtype = hostIf_StringType;
538  const RMH_Handle rmh = (RMH_Handle)MoCADevice::getRmhContext();
539  if(rmh) {
540  RMH_MoCAVersion hVer;
541  RMH_Result ret = RMH_Self_GetHighestSupportedMoCAVersion(rmh, &hVer);
542 
543  if (ret == RMH_SUCCESS) {
544  RDK_LOG(RDK_LOG_DEBUG,LOG_TR69HOSTIF,"[%s:%u] RMH_Self_GetHighestSupportedMoCAVersion success with result %s and value as %d. \n", __FUNCTION__, __LINE__, RMH_ResultToString(ret), hVer);
545  m_HighestVersion = hVer;
546  snprintf(stMsgData->paramValue, (TR69HOSTIFMGR_MAX_PARAM_LEN-1), "%s", RMH_MoCAVersionToString(hVer));
547  stMsgData->paramLen = strlen(stMsgData->paramValue);
548  retval = OK;
549  }
550  else {
551  RDK_LOG(RDK_LOG_ERROR,LOG_TR69HOSTIF,"[%s:%u] RMH_Self_GetHighestSupportedMoCAVersion failed with result %s.\n", __FUNCTION__, __LINE__, RMH_ResultToString(ret));
552  }
553  }
554  return retval;
555 }
556 
558 {
559  int retval = NOK;
560  stMsgData->paramtype = hostIf_StringType;
561  const RMH_Handle rmh = (RMH_Handle)MoCADevice::getRmhContext();
562  if(rmh) {
563  RMH_MoCAVersion response;
564  RMH_Result ret = RMH_Network_GetMoCAVersion(rmh, &response);
565 
566  if (ret == RMH_SUCCESS) {
567  RDK_LOG(RDK_LOG_DEBUG,LOG_TR69HOSTIF,"[%s:%u] RMH_Network_GetMoCAVersion success with result %s and value as %d. \n", __FUNCTION__, __LINE__, RMH_ResultToString(ret), response);
568  snprintf(stMsgData->paramValue, (TR69HOSTIFMGR_MAX_PARAM_LEN-1), "%s", RMH_MoCAVersionToString(response));
569  stMsgData->paramLen = strlen(stMsgData->paramValue);
570  retval = OK;
571  }
572  else {
573  RDK_LOG(RDK_LOG_ERROR,LOG_TR69HOSTIF,"[%s:%u] RMH_Network_GetMoCAVersion failed with result %s.\n", __FUNCTION__, __LINE__, RMH_ResultToString(ret));
574  }
575  }
576  return retval;
577 }
579 {
580  int retval = NOK;
581  stMsgData->paramtype = hostIf_UnsignedIntType;
582  stMsgData->paramLen=sizeof(unsigned int);
583 
584  const RMH_Handle rmh = (RMH_Handle)MoCADevice::getRmhContext();
585  if(rmh) {
586  uint32_t ui32Response;
587  RMH_Result ret = RMH_Network_GetNCNodeId(rmh, &ui32Response);
588 
589  if (ret == RMH_SUCCESS) {
590  RDK_LOG(RDK_LOG_DEBUG,LOG_TR69HOSTIF,"[%s:%u] RMH_Network_GetNCNodeId success with result %s and value as %d. \n", __FUNCTION__, __LINE__, RMH_ResultToString(ret), ui32Response);
591  put_int(stMsgData->paramValue,ui32Response);
592  retval = OK;
593  }
594  else {
595  RDK_LOG(RDK_LOG_ERROR,LOG_TR69HOSTIF,"[%s:%u] RMH_Network_GetNCNodeId failed with result %s.\n", __FUNCTION__, __LINE__, RMH_ResultToString(ret));
596  }
597  }
598  return retval;
599 }
600 int MoCAInterface::get_NodeID(HOSTIF_MsgData_t *stMsgData, bool *pChanged)
601 {
602  int retval = NOK;
603  stMsgData->paramtype = hostIf_UnsignedIntType;
604  stMsgData->paramLen=sizeof(unsigned int);
605 
606  const RMH_Handle rmh = (RMH_Handle)MoCADevice::getRmhContext();
607  if(rmh) {
608  uint32_t ui32Response;
609  RMH_Result ret = RMH_Network_GetNodeId(rmh, &ui32Response);
610 
611  if (ret == RMH_SUCCESS) {
612  RDK_LOG(RDK_LOG_DEBUG,LOG_TR69HOSTIF,"[%s:%u] RMH_Network_GetNodeId success with result %s and value as %d. \n", __FUNCTION__, __LINE__, RMH_ResultToString(ret), ui32Response);
613  put_int(stMsgData->paramValue,ui32Response);
614  retval = OK;
615  }
616  else {
617  RDK_LOG(RDK_LOG_ERROR,LOG_TR69HOSTIF,"[%s:%u] RMH_Network_GetNodeId failed with result %s.\n", __FUNCTION__, __LINE__, RMH_ResultToString(ret));
618  }
619  }
620  return retval;
621 }
622 int MoCAInterface::get_MaxNodes(HOSTIF_MsgData_t *stMsgData, bool *pChanged)
623 {
624  bool maxNodes = (m_HighestVersion == HIGHEST_MOCA_VERSION)? true : false;
625  put_boolean(stMsgData->paramValue, maxNodes);
626  stMsgData->paramtype = hostIf_BooleanType;
627  stMsgData->paramLen=sizeof(bool);
628  return OK;
629 }
630 int MoCAInterface::get_PreferredNC(HOSTIF_MsgData_t *stMsgData, bool *pChanged)
631 {
632  stMsgData->paramtype = hostIf_BooleanType;
633  stMsgData->paramLen = sizeof(bool);
634 
635  const RMH_Handle rmh = (RMH_Handle)MoCADevice::getRmhContext();
636  if(rmh) {
637  bool enable;
638  RMH_Result ret = RMH_Self_GetPreferredNCEnabled(rmh, &enable);
639 
640  if (ret == RMH_SUCCESS) {
641  RDK_LOG(RDK_LOG_DEBUG,LOG_TR69HOSTIF,"[%s:%u] RMH_Network_GetNodeId success with result %s and value as %d. \n", __FUNCTION__, __LINE__, RMH_ResultToString(ret), enable);
642  put_boolean(stMsgData->paramValue,enable);
643  }
644  else {
645  RDK_LOG(RDK_LOG_ERROR,LOG_TR69HOSTIF,"[%s:%u] RMH_Network_GetNodeId failed with result %s.\n", __FUNCTION__, __LINE__, RMH_ResultToString(ret));
646  return NOK;
647  }
648  }
649  return OK;
650 }
651 
652 int MoCAInterface::get_BackupNC(HOSTIF_MsgData_t *stMsgData, bool *pChanged)
653 {
654  stMsgData->paramtype = hostIf_UnsignedIntType;
655  stMsgData->paramLen=sizeof(unsigned int);
656 
657  const RMH_Handle rmh = (RMH_Handle)MoCADevice::getRmhContext();
658  if(rmh) {
659  uint32_t backupNC;
660  RMH_Result ret = RMH_Network_GetBackupNCNodeId(rmh, &backupNC);
661 
662  if (ret == RMH_SUCCESS) {
663  RDK_LOG(RDK_LOG_DEBUG,LOG_TR69HOSTIF,"[%s:%u] RMH_Network_GetNodeId success with result %s and value as %d. \n", __FUNCTION__, __LINE__, RMH_ResultToString(ret), backupNC);
664  put_int(stMsgData->paramValue,backupNC);
665  }
666  else {
667  RDK_LOG(RDK_LOG_ERROR,LOG_TR69HOSTIF,"[%s:%u] RMH_Network_GetNodeId failed with result %s.\n", __FUNCTION__, __LINE__, RMH_ResultToString(ret));
668  return NOK;
669  }
670  }
671  return OK;
672 }
674 {
675  bool bEnable = false;
676  stMsgData->paramtype = hostIf_BooleanType;
677  stMsgData->paramLen=sizeof(bool);
678 
679  const RMH_Handle rmh = (RMH_Handle)MoCADevice::getRmhContext();
680  if(rmh) {
681  RMH_Result ret = RMH_Self_GetPrivacyEnabled(rmh, &bEnable);
682 
683  if (ret == RMH_SUCCESS) {
684  put_boolean(stMsgData->paramValue,bEnable);
685  }
686  else {
687  RDK_LOG(RDK_LOG_ERROR,LOG_TR69HOSTIF,"[%s:%u] RMH_Self_GetPrivacyEnabled failed with result %s.\n", __FUNCTION__, __LINE__, RMH_ResultToString(ret));
688  return NOK;
689  }
690  }
691  return OK;
692 }
694 {
695  bool bEnable = false;
696  stMsgData->paramtype = hostIf_BooleanType;
697  stMsgData->paramLen=sizeof(bool);
698 
699  const RMH_Handle rmh = (RMH_Handle)MoCADevice::getRmhContext();
700  if(rmh) {
701  RMH_Result ret = RMH_Self_GetPrivacyEnabled(rmh, &bEnable);
702 
703  if (ret == RMH_SUCCESS) {
704  RDK_LOG(RDK_LOG_DEBUG,LOG_TR69HOSTIF,"[%s:%u] RMH_Self_GetPrivacyEnabled success with result %s and value as %d. \n", __FUNCTION__, __LINE__, RMH_ResultToString(ret), bEnable);
705  put_boolean(stMsgData->paramValue,bEnable);
706  }
707  else {
708  RDK_LOG(RDK_LOG_ERROR,LOG_TR69HOSTIF,"[%s:%u] RMH_Self_GetPrivacyEnabled failed with result %s.\n", __FUNCTION__, __LINE__, RMH_ResultToString(ret));
709  return NOK;
710  }
711  }
712  return OK;
713 }
715 {
716  stMsgData->paramtype = hostIf_StringType;
717  const RMH_Handle rmh = (RMH_Handle)MoCADevice::getRmhContext();
718  if(rmh) {
719  size_t responseBufUsed;
720  const size_t bufLen = 256;
721  uint32_t responseBuf[bufLen] = {'\0'};
722 
723  RMH_Result ret = RMH_Self_GetSupportedFrequencies (rmh, responseBuf, bufLen, &responseBufUsed);
724 
725  if (ret == RMH_SUCCESS) {
726  int length = 0;
727  length += snprintf(stMsgData->paramValue + length, TR69HOSTIFMGR_MAX_PARAM_LEN-1, "0x" );
728  //RDK_LOG(RDK_LOG_INFO,LOG_TR69HOSTIF,"[%s:%u] responseBufUsed : %d. \n", __FUNCTION__, __LINE__, responseBufUsed);
729  for (int i=0; i < responseBufUsed; i++) {
730  length += snprintf(stMsgData->paramValue + length, TR69HOSTIFMGR_MAX_PARAM_LEN-1, "%02X", responseBuf[i] );
731  }
732  RDK_LOG(RDK_LOG_DEBUG,LOG_TR69HOSTIF,"[%s:%u] RMH_Self_GetSupportedFrequencies success with result %s and value as %s. \n", __FUNCTION__, __LINE__, RMH_ResultToString(ret),stMsgData->paramValue);
733  stMsgData->paramLen = strlen(stMsgData->paramValue);
734  }
735  else {
736  RDK_LOG(RDK_LOG_ERROR,LOG_TR69HOSTIF,"[%s:%u]RMH_Self_GetSupportedFrequencies failed with result %s.\n", __FUNCTION__, __LINE__, RMH_ResultToString(ret));
737  return NOK;
738  }
739  }
740  return OK;
741 }
742 
744 {
745  int retval = NOK;
746  stMsgData->paramtype = hostIf_StringType;
747 
748  RMH_Handle rmh=(RMH_Handle)MoCADevice::getRmhContext();
749  memset(stMsgData->paramValue, '\0', TR69HOSTIFMGR_MAX_PARAM_LEN);
750 
751  if (rmh) {
752  uint32_t response;
753  RMH_Result ret = RMH_Self_GetFrequencyMask(rmh, &response);
754 
755  if (ret == RMH_SUCCESS) {
756  snprintf(stMsgData->paramValue, (TR69HOSTIFMGR_MAX_PARAM_LEN-1), "0x%08x", response);
757  RDK_LOG(RDK_LOG_DEBUG,LOG_TR69HOSTIF,"[%s:%u] RMH_Self_GetFrequencyMask success with result %s value %s. \n", __FUNCTION__, __LINE__, RMH_ResultToString(ret), stMsgData->paramValue);
758  retval = OK;
759  } else {
760  RDK_LOG(RDK_LOG_ERROR,LOG_TR69HOSTIF,"[%s:%u] RMH_Self_GetFrequencyMask failed with result %s.\n", __FUNCTION__, __LINE__, RMH_ResultToString(ret));
761  }
762  }
763  stMsgData->paramLen = strlen(stMsgData->paramValue);
764  return retval;
765 }
766 
768 {
769  int retval = NOK;
770  stMsgData->paramtype = hostIf_StringType;
771 
772  RMH_Handle rmh=(RMH_Handle)MoCADevice::getRmhContext();
773  memset(stMsgData->paramValue, '\0', TR69HOSTIFMGR_MAX_PARAM_LEN);
774 
775  if (rmh) {
776  uint32_t response;
777  RMH_Result ret = RMH_Self_GetFrequencyMask(rmh, &response);
778 
779  if (ret == RMH_SUCCESS) {
780  snprintf(stMsgData->paramValue, (TR69HOSTIFMGR_MAX_PARAM_LEN-1), "0x%08x", response);
781  RDK_LOG(RDK_LOG_DEBUG,LOG_TR69HOSTIF,"[%s:%u] RMH_Self_GetFrequencyMask success with result %s value %s. \n", __FUNCTION__, __LINE__, RMH_ResultToString(ret), stMsgData->paramValue);
782  retval = OK;
783  } else {
784  RDK_LOG(RDK_LOG_ERROR,LOG_TR69HOSTIF,"[%s:%u] RMH_Self_GetFrequencyMask failed with result %s.\n", __FUNCTION__, __LINE__, RMH_ResultToString(ret));
785  }
786  }
787  stMsgData->paramLen = strlen(stMsgData->paramValue);
788  return retval;
789 }
790 
792 {
793  int retval = NOK;
794  stMsgData->paramtype = hostIf_IntegerType;
795  stMsgData->paramLen=sizeof(int);
796 
797  RMH_Handle rmh=(RMH_Handle)MoCADevice::getRmhContext();
798  if (rmh) {
799  uint32_t response;
800  RMH_Result ret = RMH_Network_GetRFChannelFreq(rmh, &response);
801 
802  if (ret == RMH_SUCCESS) {
803  RDK_LOG(RDK_LOG_DEBUG,LOG_TR69HOSTIF,"[%s:%u] RMH_Network_GetRFChannelFreq success with result %s value %d. \n", __FUNCTION__, __LINE__, RMH_ResultToString(ret), response);
804  put_int(stMsgData->paramValue, response);
805  retval = OK;
806  } else {
807  RDK_LOG(RDK_LOG_ERROR,LOG_TR69HOSTIF,"[%s:%u] RMH_Network_GetRFChannelFreq failed with result %s.\n", __FUNCTION__, __LINE__, RMH_ResultToString(ret));
808  }
809  }
810  return retval;
811 }
812 
813 int MoCAInterface::get_LastOperFreq(HOSTIF_MsgData_t *stMsgData, bool *pChanged)
814 {
815  int retval = NOK;
816  stMsgData->paramtype = hostIf_IntegerType;
817  stMsgData->paramLen=sizeof(int);
818 
819  RMH_Handle rmh=(RMH_Handle)MoCADevice::getRmhContext();
820  if (rmh) {
821  uint32_t response;
822  RMH_Result ret = RMH_Self_GetLOF(rmh, &response);
823 
824  if (ret == RMH_SUCCESS) {
825  RDK_LOG(RDK_LOG_DEBUG,LOG_TR69HOSTIF,"[%s:%u] RMH_Self_GetLOF success with result %s value %d. \n", __FUNCTION__, __LINE__, RMH_ResultToString(ret), response);
826  put_int(stMsgData->paramValue, response);
827  retval = OK;
828  } else {
829  RDK_LOG(RDK_LOG_ERROR,LOG_TR69HOSTIF,"[%s:%u] RMH_Self_GetLOF failed with result %s.\n", __FUNCTION__, __LINE__, RMH_ResultToString(ret));
830  }
831  }
832  return retval;
833 }
834 
835 int MoCAInterface::get_KeyPassphrase(HOSTIF_MsgData_t *stMsgData, bool *pChanged)
836 {
837  stMsgData->paramtype = hostIf_StringType;
838  stMsgData->paramLen=0;
839  /* As per specs, "When read, this parameter returns an empty string, regardless of the actual value." */
840  memset(stMsgData->paramValue, 0, TR69HOSTIFMGR_MAX_PARAM_LEN);
841  return OK;
842 }
843 
844 int MoCAInterface::get_TxPowerLimit(HOSTIF_MsgData_t *stMsgData, bool *pChanged)
845 {
846  int retval = NOK;
847  stMsgData->paramtype = hostIf_IntegerType;
848  stMsgData->paramLen=sizeof(int);
849  RMH_Handle rmh=(RMH_Handle)MoCADevice::getRmhContext();
850  memset(stMsgData->paramValue, '\0', TR69HOSTIFMGR_MAX_PARAM_LEN);
851 
852  if (rmh) {
853  int32_t response;
854  RMH_Result ret = RMH_Self_GetTxPowerLimit(rmh, &response);
855  if (ret == RMH_SUCCESS) {
856  put_int(stMsgData->paramValue, response);
857  RDK_LOG(RDK_LOG_DEBUG,LOG_TR69HOSTIF,"[%s:%u] RMH_Self_GetTxPowerLimit success with result %s value %d. \n", __FUNCTION__, __LINE__, RMH_ResultToString(ret), response);
858  retval = OK;
859  } else {
860  RDK_LOG(RDK_LOG_ERROR,LOG_TR69HOSTIF,"[%s:%u] RMH_Self_GetTxPowerLimit failed with result %s.\n", __FUNCTION__, __LINE__, RMH_ResultToString(ret));
861  }
862  }
863  else {
864  RDK_LOG(RDK_LOG_WARN,LOG_TR69HOSTIF,"[%s:%u] Failed in RMH_Initialize. Not updating cache.\n", __FUNCTION__, __LINE__);
865  }
866  return retval;
867 }
868 
870 {
871  int retval = NOK;
872  stMsgData->paramtype = hostIf_UnsignedIntType;
873  stMsgData->paramLen=sizeof(unsigned int);
874 
875  RMH_Handle rmh=(RMH_Handle)MoCADevice::getRmhContext();
876  memset(stMsgData->paramValue, '\0', TR69HOSTIFMGR_MAX_PARAM_LEN);
877 
878  if (rmh) {
879  uint32_t response = 0;
880  RMH_Result ret = RMH_Self_GetPrimaryChannelTargetPhyRate(rmh, &response);
881  if (ret == RMH_SUCCESS) {
882  put_int(stMsgData->paramValue, response);
883  RDK_LOG(RDK_LOG_DEBUG,LOG_TR69HOSTIF,"[%s:%u]RMH_Self_GetPrimaryChannelTargetPhyRate success with result %s value %d. \n", __FUNCTION__, __LINE__, RMH_ResultToString(ret), response);
884  retval = OK;
885  } else {
886  RDK_LOG(RDK_LOG_ERROR,LOG_TR69HOSTIF,"[%s:%u]RMH_Self_GetPrimaryChannelTargetPhyRate failed with result %s.\n", __FUNCTION__, __LINE__, RMH_ResultToString(ret));
887  }
888  }
889  return retval;
890 }
891 
893 {
894  int retval = NOK;
895  RMH_Handle rmh=(RMH_Handle)MoCADevice::getRmhContext();
896  stMsgData->paramtype = hostIf_UnsignedIntType;
897  stMsgData->paramLen=sizeof(unsigned int);
898 
899  unsigned int response;
900  if (rmh) {
901  RMH_Result ret = RMH_Power_GetTxBeaconPowerReduction(rmh, &response);
902 
903  if (ret == RMH_SUCCESS) {
904  put_int(stMsgData->paramValue, response);
905  RDK_LOG(RDK_LOG_DEBUG,LOG_TR69HOSTIF,"[%s:%u] RMH_Power_GetTxBeaconPowerReduction success with result %s value %d. \n", __FUNCTION__, __LINE__, RMH_ResultToString(ret), response);
906  retval = OK;
907  } else {
908  RDK_LOG(RDK_LOG_ERROR,LOG_TR69HOSTIF,"[%s:%u] RMH_Power_GetTxBeaconPowerReduction failed with result %s.\n", __FUNCTION__, __LINE__, RMH_ResultToString(ret));
909  }
910  }
911  else {
912  RDK_LOG(RDK_LOG_WARN,LOG_TR69HOSTIF,"[%s:%u] Failed in RMH_Initialize. Not updating cache.\n", __FUNCTION__, __LINE__);
913  }
914 
915  return retval;
916 }
917 
919 {
920  stMsgData->paramtype = hostIf_StringType;
921  const RMH_Handle rmh = (RMH_Handle)MoCADevice::getRmhContext();
922  if(rmh) {
923  uint32_t start = 0;
924  uint32_t mask = 0;
925  RMH_Result ret = RMH_Network_GetTabooChannels(rmh, &start, &mask);
926 
927  if (ret == RMH_SUCCESS) {
928  RDK_LOG(RDK_LOG_DEBUG,LOG_TR69HOSTIF,"[%s:%u] RMH_Network_GetTabooChannels success with result %s and value as 0x%08x. \n", __FUNCTION__, __LINE__, RMH_ResultToString(ret), mask);
929  snprintf(stMsgData->paramValue,TR69HOSTIFMGR_MAX_PARAM_LEN-1, "0x%08x", mask );
930  stMsgData->paramLen = strlen(stMsgData->paramValue);
931  }
932  else {
933  RDK_LOG(RDK_LOG_ERROR,LOG_TR69HOSTIF,"[%s:%u]RMH_Network_GetTabooChannels failed with result %s.\n", __FUNCTION__, __LINE__, RMH_ResultToString(ret));
934  return NOK;
935  }
936  }
937  return OK;
938 }
939 
940 int MoCAInterface::get_NodeTabooMask(HOSTIF_MsgData_t *stMsgData, bool *pChanged)
941 {
942  stMsgData->paramtype = hostIf_StringType;
943  const RMH_Handle rmh = (RMH_Handle)MoCADevice::getRmhContext();
944  if(rmh) {
945  uint32_t start = 0;
946  uint32_t mask = 0;
947  RMH_Result ret = RMH_Self_GetTabooChannels(rmh, &start, &mask);
948 
949  if (ret == RMH_SUCCESS) {
950  RDK_LOG(RDK_LOG_DEBUG,LOG_TR69HOSTIF,"[%s:%u]RMH_Self_GetTabooChannels success with result %s and value as 0x%08x. \n", __FUNCTION__, __LINE__, RMH_ResultToString(ret), mask);
951  snprintf(stMsgData->paramValue,TR69HOSTIFMGR_MAX_PARAM_LEN-1, "0x%08x", mask );
952  stMsgData->paramLen = strlen(stMsgData->paramValue);
953  }
954  else {
955  RDK_LOG(RDK_LOG_ERROR,LOG_TR69HOSTIF,"[%s:%u]RMH_Self_GetTabooChannels failed with result %s.\n", __FUNCTION__, __LINE__, RMH_ResultToString(ret));
956  return NOK;
957  }
958  }
959  return OK;
960 }
961 
962 int MoCAInterface::get_TxBcastRate(HOSTIF_MsgData_t *stMsgData, bool *pChanged)
963 {
964  int retval = NOK;
965  stMsgData->paramtype = hostIf_UnsignedIntType;
966  stMsgData->paramLen=sizeof(unsigned int);
967  RMH_Handle rmh=(RMH_Handle)MoCADevice::getRmhContext();
968  if (rmh) {
969  uint32_t ui32Response;
970  RMH_Result ret = RMH_Network_GetTxBroadcastPhyRate(rmh, &ui32Response);
971  if (ret == RMH_SUCCESS) {
972  put_int(stMsgData->paramValue,ui32Response);
973  RDK_LOG(RDK_LOG_DEBUG,LOG_TR69HOSTIF,"[%s:%u] RMH_Network_GetTxBroadcastPhyRate success with result %s value %d. \n", __FUNCTION__, __LINE__, RMH_ResultToString(ret), ui32Response);
974  retval = OK;
975  } else {
976  RDK_LOG(RDK_LOG_ERROR,LOG_TR69HOSTIF,"[%s:%u] RMH_Network_GetTxBroadcastPhyRate failed with result %s.\n", __FUNCTION__, __LINE__, RMH_ResultToString(ret));
977  }
978  }
979  return retval;
980 }
982 {
983  int retval = NOK;
984  stMsgData->paramtype = hostIf_UnsignedIntType;
985  stMsgData->paramLen=sizeof(unsigned int);
986 
987  RMH_Handle rmh=(RMH_Handle)MoCADevice::getRmhContext();
988  if (rmh) {
989  uint32_t response;
990  RMH_Result ret = RMH_Power_GetTxBeaconPowerReduction(rmh, &response);
991  if (ret == RMH_SUCCESS) {
992  put_int(stMsgData->paramValue,response);
993  RDK_LOG(RDK_LOG_DEBUG,LOG_TR69HOSTIF,"[%s:%u] RMH_Power_GetTxBeaconPowerReduction success with result %s value %d. \n", __FUNCTION__, __LINE__, RMH_ResultToString(ret), response);
994  retval = OK;
995  } else {
996  RDK_LOG(RDK_LOG_ERROR,LOG_TR69HOSTIF,"[%s:%u] RMH_Power_GetTxBeaconPowerReduction failed with result %s.\n", __FUNCTION__, __LINE__, RMH_ResultToString(ret));
997  }
998  }
999  return retval;
1000 }
1001 
1003 {
1004  int retval = NOK;
1005  stMsgData->paramtype = hostIf_BooleanType;
1006  stMsgData->paramLen=sizeof(bool);
1007 
1008  RMH_Handle rmh=(RMH_Handle)MoCADevice::getRmhContext();
1009  if (rmh) {
1010  bool response = false;
1011  RMH_Result ret = RMH_Self_GetQAM256Enabled(rmh, &response);
1012  if (ret == RMH_SUCCESS) {
1013  put_boolean(stMsgData->paramValue,response);
1014  RDK_LOG(RDK_LOG_DEBUG,LOG_TR69HOSTIF,"[%s:%u] RMH_Self_GetQAM256Enabled success with result %s value %d. \n", __FUNCTION__, __LINE__, RMH_ResultToString(ret), response);
1015  retval = OK;
1016  } else {
1017  RDK_LOG(RDK_LOG_ERROR,LOG_TR69HOSTIF,"[%s:%u] RMH_Self_GetQAM256Enabled failed with result %s.\n", __FUNCTION__, __LINE__, RMH_ResultToString(ret));
1018  }
1019  }
1020  return retval;
1021 }
1022 
1024 {
1025  int retval = NOK;
1026  stMsgData->paramtype = hostIf_UnsignedIntType;
1027  stMsgData->paramLen=sizeof(unsigned int);
1028  RMH_Handle rmh=(RMH_Handle)MoCADevice::getRmhContext();
1029  if (rmh) {
1030  uint32_t response = 0;
1031  RMH_Result ret = RMH_Self_GetMaxPacketAggregation(rmh, &response);
1032  if (ret == RMH_SUCCESS) {
1033  put_int(stMsgData->paramValue,response);
1034  RDK_LOG(RDK_LOG_DEBUG,LOG_TR69HOSTIF,"[%s:%u] RMH_RemoteNode_GetMaxPacketAggregation success with result %s value %d. \n", __FUNCTION__, __LINE__, RMH_ResultToString(ret), response);
1035  retval = OK;
1036  } else {
1037  RDK_LOG(RDK_LOG_ERROR,LOG_TR69HOSTIF,"[%s:%u] RMH_RemoteNode_GetMaxPacketAggregation failed with result %s.\n", __FUNCTION__, __LINE__, RMH_ResultToString(ret));
1038  }
1039  }
1040  return retval;
1041 }
1042 
1044 {
1045  int num_entries;
1046  int ret = get_Associated_Device_NumberOfEntries(num_entries);
1047  put_int(stMsgData->paramValue,num_entries);
1048  stMsgData->paramtype = hostIf_UnsignedIntType;
1049  stMsgData->paramLen=sizeof(unsigned int);
1050  return ret;
1051 }
1052 
1054 {
1055  int num_entries;
1056  int ret = get_MoCA_Mesh_NumberOfEntries(num_entries);
1057  put_int(stMsgData->paramValue,num_entries);
1058  stMsgData->paramtype = hostIf_UnsignedIntType;
1059  stMsgData->paramLen=sizeof(unsigned int);
1060  return ret;
1061 }
1062 
1064 {
1065  int retval = NOK;
1066  stMsgData->paramtype = hostIf_UnsignedIntType;
1067  stMsgData->paramLen=sizeof(unsigned int);
1068 
1069  RMH_Handle rmh=(RMH_Handle)MoCADevice::getRmhContext();
1070  if (rmh) {
1071  uint32_t response = 0;
1072  RMH_Result ret = RMH_Network_GetPrimaryChannelFreq(rmh, &response);
1073  if (ret == RMH_SUCCESS) {
1074  put_int(stMsgData->paramValue,response);
1075  RDK_LOG(RDK_LOG_DEBUG,LOG_TR69HOSTIF,"[%s:%u] RMH_Network_GetPrimaryChannelFreq success with result %s value %d. \n", __FUNCTION__, __LINE__, RMH_ResultToString(ret), response);
1076  retval = OK;
1077  } else {
1078  RDK_LOG(RDK_LOG_ERROR,LOG_TR69HOSTIF,"[%s:%u] RMH_Network_GetPrimaryChannelFreq failed with result %s.\n", __FUNCTION__, __LINE__, RMH_ResultToString(ret));
1079  }
1080  }
1081  return retval;
1082 }
1083 
1085 {
1086  int retval = NOK;
1087  stMsgData->paramtype = hostIf_UnsignedIntType;
1088  stMsgData->paramLen=sizeof(unsigned int);
1089 
1090  RMH_Handle rmh=(RMH_Handle)MoCADevice::getRmhContext();
1091  if (rmh) {
1092  uint32_t response = 0;
1093  RMH_Result ret = RMH_Network_GetSecondaryChannelFreq(rmh, &response);
1094  if (ret == RMH_SUCCESS) {
1095  put_int(stMsgData->paramValue,response);
1096  RDK_LOG(RDK_LOG_DEBUG,LOG_TR69HOSTIF,"[%s:%u] RMH_Network_GetSecondaryChannelFreq success with result %s value %d. \n", __FUNCTION__, __LINE__, RMH_ResultToString(ret), response);
1097  retval = OK;
1098  } else {
1099  RDK_LOG(RDK_LOG_ERROR,LOG_TR69HOSTIF,"[%s:%u] RMH_Network_GetSecondaryChannelFreq failed with result %s.\n", __FUNCTION__, __LINE__, RMH_ResultToString(ret));
1100  }
1101  }
1102  return retval;
1103 }
1104 
1106 {
1107  int retval = NOK;
1108  stMsgData->paramtype = hostIf_UnsignedIntType;
1109  stMsgData->paramLen=sizeof(unsigned int);
1110  RMH_Handle rmh=(RMH_Handle)MoCADevice::getRmhContext();
1111  if (rmh) {
1112  RMH_PowerMode response;
1113  RMH_Result ret = RMH_Power_GetMode(rmh, &response);
1114  if (ret == RMH_SUCCESS) {
1115  put_int(stMsgData->paramValue,response);
1116  RDK_LOG(RDK_LOG_DEBUG,LOG_TR69HOSTIF,"[%s:%u]RMH_Power_GetMode success with result %s value %d. \n", __FUNCTION__, __LINE__, RMH_ResultToString(ret), response);
1117  retval = OK;
1118  } else {
1119  RDK_LOG(RDK_LOG_ERROR,LOG_TR69HOSTIF,"[%s:%u]RMH_Power_GetMode failed with result %s.\n", __FUNCTION__, __LINE__, RMH_ResultToString(ret));
1120  }
1121  }
1122  return retval;
1123 }
1124 
1126 {
1127  int retval = NOK;
1128  stMsgData->paramtype = hostIf_BooleanType;
1129  stMsgData->paramLen=sizeof(unsigned int);
1130 
1131  RMH_Handle rmh=(RMH_Handle)MoCADevice::getRmhContext();
1132  if (rmh) {
1133  bool response = 0;
1134  RMH_Result ret = RMH_Self_GetTurboEnabled(rmh, &response);
1135  if (ret == RMH_SUCCESS) {
1136  put_boolean(stMsgData->paramValue,response);
1137  RDK_LOG(RDK_LOG_DEBUG,LOG_TR69HOSTIF,"[%s:%u] RMH_Network_GetSecondaryChannelFreq success with result %s value %d. \n", __FUNCTION__, __LINE__, RMH_ResultToString(ret), response);
1138  retval = OK;
1139  } else {
1140  RDK_LOG(RDK_LOG_ERROR,LOG_TR69HOSTIF,"[%s:%u] RMH_Network_GetSecondaryChannelFreq failed with result %s.\n", __FUNCTION__, __LINE__, RMH_ResultToString(ret));
1141  }
1142  }
1143  return retval;
1144 }
1145 
1147 {
1148  const RMH_Handle rmh = (RMH_Handle)MoCADevice::getRmhContext();
1149  if(rmh) {
1150  RMH_LinkStatus status;
1151  RMH_Result ret = RMH_Self_GetLinkStatus(rmh, &status);
1152 
1153  if (ret == RMH_SUCCESS) {
1154  RDK_LOG(RDK_LOG_DEBUG,LOG_TR69HOSTIF,"[%s:%u] RMH_Self_GetLinkStatus success with result %s value %s. \n", __FUNCTION__, __LINE__, RMH_ResultToString(ret), RMH_LinkStatusToString(status));
1155  // Check MoCA link status
1156  if (status != RMH_LINK_STATUS_UP)
1157  {
1158  RDK_LOG(RDK_LOG_ERROR,LOG_TR69HOSTIF,"[%s:%s] Coax connection failed, MoCA disabled.\n", __FILE__, __FUNCTION__);
1159  return NOK;
1160  }
1161  else {
1162  sprintf(statusBuf, "%s", "Coax connection confirmed, MoCA enabled");
1163  RDK_LOG(RDK_LOG_TRACE1,LOG_TR69HOSTIF,"[%s:%s] Status: %s\n", __FILE__, __FUNCTION__, statusBuf);
1164  }
1165 
1166  uint32_t ncId;
1167  if(RMH_SUCCESS != RMH_Network_GetNCNodeId(rmh, &ncId)) {
1168  RDK_LOG(RDK_LOG_ERROR,LOG_TR69HOSTIF,"[%s:%s] Failed to discovering MoCA Network Coordinator.\n", __FILE__, __FUNCTION__);
1169  return NOK;
1170  }
1171 
1172  RMH_MacAddress_t ncMac;
1173  if (RMH_SUCCESS != RMH_Network_GetNCMac(rmh, &ncMac)) {
1174  RDK_LOG(RDK_LOG_ERROR,LOG_TR69HOSTIF,"[%s:%s] Failed to discovering MoCA Network Coordinator.\n", __FILE__, __FUNCTION__);
1175  return NOK;
1176  }
1177  else {
1178  char macBuff[20] = {'\0'};
1179  RMH_MacToString(ncMac, macBuff, sizeof(macBuff));
1180  RDK_LOG(RDK_LOG_DEBUG, LOG_TR69HOSTIF,"[%s:%u] RMH_Interface_GetMac success with Mac Address : %s. \n", __FUNCTION__, __LINE__, macBuff);
1181  sprintf(statusBuf, "%s %d %s %s", "Discovering MoCA Network Coordinator:", ncId, " MoCA MAC: ", macBuff);
1182  }
1183 
1184  int numOfNodes;
1185  if(OK == get_MoCA_Mesh_NumberOfEntries(numOfNodes))
1186  {
1187  if(numOfNodes > 1)
1188  {
1189  sprintf(statusBuf, "%s", "Joined MoCA Network");
1190  RDK_LOG(RDK_LOG_DEBUG,LOG_TR69HOSTIF,"[%s:%s] Status: %s\n", __FILE__, __FUNCTION__, statusBuf);
1191  }
1192  else
1193  {
1194  RDK_LOG(RDK_LOG_ERROR,LOG_TR69HOSTIF,"[%s:%s]", "Failed to Join MoCA Network.\n", __FILE__, __FUNCTION__);
1195  return NOK;
1196  }
1197  }
1198  }
1199  }
1200  return OK;
1201 }
1202 
1203 /****************************************************************************************************************************************************/
1204 // Device.MoCA.Interface Table Profile. Setters:
1205 /****************************************************************************************************************************************************/
1206 
1208 {
1209  RDK_LOG(RDK_LOG_TRACE1,LOG_TR69HOSTIF,"[%s:%s] Entering..\n", __FUNCTION__, __FILE__);
1210 
1211  if(stMsgData->paramtype == hostIf_BooleanType) {
1212  stMsgData->faultCode = fcInvalidParameterType;
1213  RDK_LOG(RDK_LOG_ERROR,LOG_TR69HOSTIF,"[%s:%s] Failed due to wrong data type. This should be boolean.\n", __FUNCTION__, __FILE__);
1214  return NOK;
1215  }
1216 
1217  const RMH_Handle rmh = (RMH_Handle)MoCADevice::getRmhContext();
1218  if(rmh) {
1219  const bool value = get_boolean(stMsgData->paramValue);
1220  RMH_Result ret = RMH_Self_SetEnabled(rmh, value);
1221  if (ret == RMH_SUCCESS) {
1222  m_bEnable = value;
1223  RDK_LOG(RDK_LOG_DEBUG,LOG_TR69HOSTIF,"[%s:%u] RMH_Self_SetEnabled successfully set. \n", __FUNCTION__, __LINE__);
1224  }
1225  else {
1226  stMsgData->faultCode = fcRequestDenied;
1227  RDK_LOG(RDK_LOG_ERROR,LOG_TR69HOSTIF,"[%s:%u] RMH_Self_SetEnabled failed with result %s. \n", __FUNCTION__, __LINE__, RMH_ResultToString(ret));
1228  return NOK;
1229  }
1230  }
1231  RDK_LOG(RDK_LOG_TRACE1,LOG_TR69HOSTIF,"[%s:%s] Exiting..\n", __FUNCTION__, __FILE__);
1232  stMsgData->faultCode = fcNoFault;
1233  return OK;
1234 }
1235 
1236 
1238 {
1239  stMsgData->paramtype = hostIf_StringType;
1240  const char* alias = stMsgData->paramName;
1241  if(alias) {
1242  snprintf(m_i8Alias, N_LENGTH-1, "cpe-%s", alias);
1243  }
1244  return OK;
1245 }
1246 
1248 {
1249  /*Retrieving value */
1250  // Implementation for SOC vendor
1251  // value->out_cval =
1252 
1253  return OK;
1254 }
1256 {
1257  if(stMsgData->paramtype == hostIf_BooleanType) {
1258  stMsgData->faultCode = fcInvalidParameterType;
1259  RDK_LOG(RDK_LOG_ERROR,LOG_TR69HOSTIF,"[%s:%s] Failed due to wrong data type. This should be boolean.\n", __FUNCTION__, __FILE__);
1260  return NOK;
1261  }
1262 
1263  const RMH_Handle rmh = (RMH_Handle)MoCADevice::getRmhContext();
1264  if(rmh) {
1265  const bool value = get_boolean(stMsgData->paramValue);
1266  RMH_Result ret = RMH_Self_SetPreferredNCEnabled(rmh, value);
1267  if (ret == RMH_SUCCESS) {
1268  RDK_LOG(RDK_LOG_INFO,LOG_TR69HOSTIF,"[%s:%u] RMH_Self_SetPreferredNCEnabled successfully set with value %d. \n", __FUNCTION__, __LINE__, value);
1269  }
1270  else {
1271  stMsgData->faultCode = fcRequestDenied;
1272  RDK_LOG(RDK_LOG_ERROR,LOG_TR69HOSTIF,"[%s:%u] RMH_Self_SetPreferredNCEnabled failed with result %s. \n", __FUNCTION__, __LINE__, RMH_ResultToString(ret));
1273  return NOK;
1274  }
1275  }
1276  stMsgData->faultCode = fcNoFault;
1277  RDK_LOG(RDK_LOG_TRACE1,LOG_TR69HOSTIF,"[%s:%s] Exiting..\n", __FUNCTION__, __FILE__);
1278  return OK;
1279 }
1280 
1282 {
1283  const RMH_Handle rmh = (RMH_Handle)MoCADevice::getRmhContext();
1284 
1285  if(rmh) {
1286  const bool value = get_boolean(stMsgData->paramValue);
1287  RMH_Result ret = RMH_Self_SetPrivacyEnabled(rmh, value);
1288  if (ret == RMH_SUCCESS) {
1289  RDK_LOG(RDK_LOG_INFO,LOG_TR69HOSTIF,"[%s:%u] RMH_Self_SetPrivacyEnabled successfully set with value %d. \n", __FUNCTION__, __LINE__, value);
1290  }
1291  else {
1292  stMsgData->faultCode = fcRequestDenied;
1293  RDK_LOG(RDK_LOG_ERROR,LOG_TR69HOSTIF,"[%s:%u] RMH_Self_SetPrivacyEnabled failed with result %s. \n", __FUNCTION__, __LINE__, RMH_ResultToString(ret));
1294  return NOK;
1295  }
1296  }
1297  stMsgData->faultCode = fcNoFault;
1298  RDK_LOG(RDK_LOG_TRACE1,LOG_TR69HOSTIF,"[%s:%s] Exiting..\n", __FUNCTION__, __FILE__);
1299  return OK;
1300 }
1301 
1303 {
1304  const RMH_Handle rmh = (RMH_Handle)MoCADevice::getRmhContext();
1305 
1306  if(rmh) {
1307  const uint32_t value = atoi(stMsgData->paramValue);
1308  RMH_Result ret = RMH_Self_SetFrequencyMask(rmh, value);
1309  if (ret == RMH_SUCCESS) {
1310  RDK_LOG(RDK_LOG_INFO,LOG_TR69HOSTIF,"[%s:%u] RMH_Self_SetFrequencyMask successfully set with value %d. \n", __FUNCTION__, __LINE__, value);
1311  }
1312  else {
1313  stMsgData->faultCode = fcRequestDenied;
1314  RDK_LOG(RDK_LOG_ERROR,LOG_TR69HOSTIF,"[%s:%u] RMH_Self_SetFrequencyMask failed with result %s. \n", __FUNCTION__, __LINE__, RMH_ResultToString(ret));
1315  return NOK;
1316  }
1317  }
1318  stMsgData->faultCode = fcNoFault;
1319  RDK_LOG(RDK_LOG_TRACE1,LOG_TR69HOSTIF,"[%s:%s] Exiting..\n", __FUNCTION__, __FILE__);
1320  return OK;
1321 }
1322 
1324 {
1325  const RMH_Handle rmh = (RMH_Handle)MoCADevice::getRmhContext();
1326 
1327  if(rmh) {
1328  const char* value = stMsgData->paramValue;
1329  RMH_Result ret = RMH_Self_SetPrivacyPassword(rmh, value);
1330  if (ret == RMH_SUCCESS) {
1331  RDK_LOG(RDK_LOG_INFO,LOG_TR69HOSTIF,"[%s:%u] RMH_Self_SetPrivacyPassword successfully set with value %d. \n", __FUNCTION__, __LINE__, value);
1332  RDK_LOG(RDK_LOG_DEBUG,LOG_TR69HOSTIF,"[%s,%d] KeyPassphrase set Complete \n",__FUNCTION__,__LINE__);
1333  }
1334  else {
1335  stMsgData->faultCode = fcRequestDenied;
1336  RDK_LOG(RDK_LOG_ERROR,LOG_TR69HOSTIF,"[%s:%u] RMH_Self_SetPrivacyPassword failed with result %s. \n", __FUNCTION__, __LINE__, RMH_ResultToString(ret));
1337  return NOK;
1338  }
1339  }
1340  stMsgData->faultCode = fcNoFault;
1341  RDK_LOG(RDK_LOG_TRACE1,LOG_TR69HOSTIF,"[%s:%s] Exiting..\n", __FUNCTION__, __FILE__);
1342  return OK;
1343 }
1344 
1346 {
1347  const RMH_Handle rmh = (RMH_Handle)MoCADevice::getRmhContext();
1348  if(rmh) {
1349  const int32_t value = get_int(stMsgData->paramValue);
1350  RMH_Result ret = RMH_Self_SetTxPowerLimit(rmh, value);
1351  if (ret == RMH_SUCCESS) {
1352  RDK_LOG(RDK_LOG_INFO,LOG_TR69HOSTIF,"[%s:%u] RMH_Self_SetTxPowerLimit successfully set with value %d. \n", __FUNCTION__, __LINE__, value);
1353  }
1354  else {
1355  stMsgData->faultCode = fcRequestDenied;
1356  RDK_LOG(RDK_LOG_ERROR,LOG_TR69HOSTIF,"[%s:%u] RMH_Self_SetTxPowerLimit failed with result %s. \n", __FUNCTION__, __LINE__, RMH_ResultToString(ret));
1357  return NOK;
1358  }
1359  }
1360  stMsgData->faultCode = fcNoFault;
1361  RDK_LOG(RDK_LOG_TRACE1,LOG_TR69HOSTIF,"[%s:%s] Exiting..\n", __FUNCTION__, __FILE__);
1362  return OK;
1363 }
1364 
1366 {
1367  const RMH_Handle rmh = (RMH_Handle)MoCADevice::getRmhContext();
1368  if(rmh) {
1369  const int32_t value = get_int(stMsgData->paramValue);
1370  RMH_Result ret = RMH_Self_SetPrimaryChannelTargetPhyRate(rmh, value);
1371  if (ret == RMH_SUCCESS) {
1372  RDK_LOG(RDK_LOG_INFO,LOG_TR69HOSTIF,"[%s:%u]RMH_Self_SetPrimaryChannelTargetPhyRate successfully set with value %d. \n", __FUNCTION__, __LINE__, value);
1373  }
1374  else {
1375  stMsgData->faultCode = fcRequestDenied;
1376  RDK_LOG(RDK_LOG_ERROR,LOG_TR69HOSTIF,"[%s:%u] RMH_Self_SetPrimaryChannelTargetPhyRate failed with result %s. \n", __FUNCTION__, __LINE__, RMH_ResultToString(ret));
1377  return NOK;
1378  }
1379  }
1380  stMsgData->faultCode = fcNoFault;
1381  RDK_LOG(RDK_LOG_TRACE1,LOG_TR69HOSTIF,"[%s:%s] Exiting..\n", __FUNCTION__, __FILE__);
1382  return OK;
1383 }
1384 
1386 {
1387  const RMH_Handle rmh = (RMH_Handle)MoCADevice::getRmhContext();
1388  if(rmh) {
1389  const uint32_t value = get_int(stMsgData->paramValue);
1390  RMH_Result ret = RMH_Power_SetTxBeaconPowerReduction(rmh, value);
1391  if (ret == RMH_SUCCESS) {
1392  RDK_LOG(RDK_LOG_INFO,LOG_TR69HOSTIF,"[%s:%u] RMH_Power_SetTxBeaconPowerReduction successfully set with value %d. \n", __FUNCTION__, __LINE__, value);
1393  }
1394  else {
1395  stMsgData->faultCode = fcRequestDenied;
1396  RDK_LOG(RDK_LOG_ERROR,LOG_TR69HOSTIF,"[%s:%u] RMH_Power_SetTxBeaconPowerReduction failed with result %s. \n", __FUNCTION__, __LINE__, RMH_ResultToString(ret));
1397  return NOK;
1398  }
1399  }
1400  stMsgData->faultCode = fcNoFault;
1401  RDK_LOG(RDK_LOG_TRACE1,LOG_TR69HOSTIF,"[%s:%s] Exiting..\n", __FUNCTION__, __FILE__);
1402  return OK;
1403 }
1404 
1405 
1406 /* End of doxygen group */
1407 /**
1408  * @}
1409  */
1410 
1411 /* End of file xxx_api.c. */
MoCADevice
Definition: Device_MoCA_Interface.h:100
MoCAInterface::set_PowerCntlPhyTarget
int set_PowerCntlPhyTarget(HOSTIF_MsgData_t *)
Set the target PHY rate in Mbps for the power control algorithm.
Definition: Device_MoCA_Interface.cpp:1365
RMH_Network_GetNCMac
RMH_Result RMH_Network_GetNCMac(const RMH_Handle handle, RMH_MacAddress_t *response)
Return the MAC address of the network coordinator.
MoCAInterface::set_LowerLayers
int set_LowerLayers(HOSTIF_MsgData_t *)
Set the MoCA Interface LowerLayers list.
Definition: Device_MoCA_Interface.cpp:1247
RMH_Power_GetMode
RMH_Result RMH_Power_GetMode(const RMH_Handle handle, RMH_PowerMode *response)
Return the current MoCA power state of this device.
RMH_Self_GetPreferredNCEnabled
RMH_Result RMH_Self_GetPreferredNCEnabled(const RMH_Handle handle, bool *response)
Return if this device is a preferred NC.
MoCAInterface::get_Name
int get_Name(HOSTIF_MsgData_t *, bool *pChanged=NULL)
Get the textual name of the interface as assigned by the CPE.
Definition: Device_MoCA_Interface.cpp:355
MoCAInterface
Definition: Device_MoCA_Interface.h:114
RMH_Self_GetMaxBitrate
RMH_Result RMH_Self_GetMaxBitrate(const RMH_Handle handle, uint32_t *response)
The maximum PHY rate supported in non-turbo mode.
MoCAInterface::set_PreferredNC
int set_PreferredNC(HOSTIF_MsgData_t *)
Set the interface is a preferred Network Coordinator (NC).
Definition: Device_MoCA_Interface.cpp:1255
MoCAInterface::get_NodeID
int get_NodeID(HOSTIF_MsgData_t *, bool *pChanged=NULL)
Get the Node ID of the MoCA interface.
Definition: Device_MoCA_Interface.cpp:600
MoCAInterface::get_BeaconPowerLimit
int get_BeaconPowerLimit(HOSTIF_MsgData_t *, bool *pChanged=NULL)
Get the Beacon Transmit Power attenuation in dB relative to the maximum transmit power.
Definition: Device_MoCA_Interface.cpp:892
RMH_Self_GetLinkStatus
RMH_Result RMH_Self_GetLinkStatus(const RMH_Handle handle, RMH_LinkStatus *status)
Current operational status of the MoCA interface [mocaIfStatus].
MoCAInterface::get_NodeTabooMask
int get_NodeTabooMask(HOSTIF_MsgData_t *, bool *pChanged=NULL)
Get the hexadecimal encoded 64-bit mask of supported frequencies. This is the bit map of the spectrum...
Definition: Device_MoCA_Interface.cpp:940
RMH_Network_GetLinkUptime
RMH_Result RMH_Network_GetLinkUptime(const RMH_Handle handle, uint32_t *response)
Returns the amount of time this node has been part of the MoCA network [mocaIfLinkUpTime].
MoCAInterface::get_TxPowerLimit
int get_TxPowerLimit(HOSTIF_MsgData_t *, bool *pChanged=NULL)
Get the transmit Power attenuation in dB relative to the maximum transmit power.
Definition: Device_MoCA_Interface.cpp:844
RMH_Network_GetSecondaryChannelFreq
RMH_Result RMH_Network_GetSecondaryChannelFreq(const RMH_Handle handle, uint32_t *response)
Return the secondary MoCA 2.0 channel.
MoCAInterface::get_Upstream
int get_Upstream(HOSTIF_MsgData_t *, bool *pChanged=NULL)
Check whether the interface points towards the Internet (true) or towards End Devices (false).
Definition: Device_MoCA_Interface.cpp:405
RMH_Network_GetBackupNCNodeId
RMH_Result RMH_Network_GetBackupNCNodeId(const RMH_Handle handle, uint32_t *response)
Return the node ID of the backup network coordinator [mocaIfBackupNC].
RMH_Network_GetNodeIds
RMH_Result RMH_Network_GetNodeIds(const RMH_Handle handle, RMH_NodeList_Uint32_t *response)
Return a list of every node ID on the network.
MoCAInterface::set_Enable
int set_Enable(HOSTIF_MsgData_t *)
Enables or disables the interface.
Definition: Device_MoCA_Interface.cpp:1207
MoCAInterface::set_Alias
int set_Alias(HOSTIF_MsgData_t *)
Set the Alias-based addressing for MoCA interface.
Definition: Device_MoCA_Interface.cpp:1237
RMH_PQOS_GetMaxIngressFlows
RMH_Result RMH_PQOS_GetMaxIngressFlows(const RMH_Handle handle, uint32_t *response)
Return the maximum number of supported Ingress PQoS Flows by the Node [mocaIfSupportedIngressPqosFlow...
MoCAInterface::get_TxBcastRate
int get_TxBcastRate(HOSTIF_MsgData_t *, bool *pChanged=NULL)
Get the broadcast PHY transmit rate in Mbps for this interface.
Definition: Device_MoCA_Interface.cpp:962
RMH_NodeList_Uint32_t
Definition: rmh_type.h:195
RMH_MoCAVersionToString
const char *const RMH_MoCAVersionToString(const RMH_MoCAVersion value)
Convert RMH_MoCAVersion to a string.
Definition: librmh_api_no_wrap.c:122
RMH_Network_GetNodeId
RMH_Result RMH_Network_GetNodeId(const RMH_Handle handle, uint32_t *response)
Return the node ID of this device.
MoCAInterface::get_X_RDKCENTRAL_COM_SecondaryChannelFreq
int get_X_RDKCENTRAL_COM_SecondaryChannelFreq(HOSTIF_MsgData_t *)
Get the MoCA status for BootStatus.
Definition: Device_MoCA_Interface.cpp:1084
_HostIf_MsgData_t
Definition: hostIf_tr69ReqHandler.h:170
MoCAInterface::get_MACAddress
int get_MACAddress(HOSTIF_MsgData_t *, bool *pChanged=NULL)
Get the MAC Address of the interface.
Definition: Device_MoCA_Interface.cpp:423
MoCAInterface::get_TxBcastPowerReduction
int get_TxBcastPowerReduction(HOSTIF_MsgData_t *, bool *pChanged=NULL)
Get the transmit Power attenuation in dB relative to the maximum transmit power for broadcast transmi...
Definition: Device_MoCA_Interface.cpp:981
RMH_Self_SetFrequencyMask
RMH_Result RMH_Self_SetFrequencyMask(const RMH_Handle handle, const uint32_t value)
Set the bit mask for specifying which frequencies should be scanned during the listening phase of net...
RMH_Self_GetHighestSupportedMoCAVersion
RMH_Result RMH_Self_GetHighestSupportedMoCAVersion(const RMH_Handle handle, RMH_MoCAVersion *response)
Return the highest version of MoCA supported by the MoCA driver on this device. [mocaIfMocaVersion].
MoCAInterface::get_NetworkTabooMask
int get_NetworkTabooMask(HOSTIF_MsgData_t *, bool *pChanged=NULL)
Get the hexadecimal encoded 64-bit mask of MoCA taboo channels identified for the home network....
Definition: Device_MoCA_Interface.cpp:918
RMH_Self_SetPreferredNCEnabled
RMH_Result RMH_Self_SetPreferredNCEnabled(const RMH_Handle handle, const bool value)
Enable or disable preferred NC on this device.
RMH_Self_GetTurboEnabled
RMH_Result RMH_Self_GetTurboEnabled(const RMH_Handle handle, bool *response)
Return if turbo mode is enabled on this device.
MoCAInterface::get_FreqCapabilityMask
int get_FreqCapabilityMask(HOSTIF_MsgData_t *, bool *pChanged=NULL)
Get the hexadecimal encoded 64-bit mask of supported frequencies. This is the bit map of the spectrum...
Definition: Device_MoCA_Interface.cpp:714
MoCAInterface::get_KeyPassphrase
int get_KeyPassphrase(HOSTIF_MsgData_t *, bool *pChanged=NULL)
Get the MoCA Password. The value consists of numeric characters (0-9).
Definition: Device_MoCA_Interface.cpp:835
put_boolean
void put_boolean(char *ptr, bool val)
This function converts the input data to Boolean type.
Definition: hostIf_utils.cpp:191
MoCAInterface::get_PowerCntlPhyTarget
int get_PowerCntlPhyTarget(HOSTIF_MsgData_t *, bool *pChanged=NULL)
Get the target PHY rate in Mbps for the power control algorithm.
Definition: Device_MoCA_Interface.cpp:869
RMH_Network_GetRFChannelFreq
RMH_Result RMH_Network_GetRFChannelFreq(const RMH_Handle handle, uint32_t *response)
Return the frequency which the MoCA network is operating on. [mocaIfRFChannel].
MoCAInterface::get_InterfaceNumberOfEntries
static int get_InterfaceNumberOfEntries(HOSTIF_MsgData_t *, bool *pChanged=NULL)
Get the number of entries in the MoCA Interface table.
Definition: Device_MoCA_Interface.cpp:278
RMH_LinkStatusToString
const char *const RMH_LinkStatusToString(const RMH_LinkStatus value)
Convert RMH_LinkStatus to a string.
Definition: librmh_api_no_wrap.c:88
MoCAInterface::get_PacketAggregationCapability
int get_PacketAggregationCapability(HOSTIF_MsgData_t *, bool *pChanged=NULL)
Get the packet aggregation capability supported by the interface. Standard values are 0 (no support),...
Definition: Device_MoCA_Interface.cpp:1023
MoCAInterface::get_PrivacyEnabled
int get_PrivacyEnabled(HOSTIF_MsgData_t *, bool *pChanged=NULL)
Check whether link-layer security is enabled or disabled.
Definition: Device_MoCA_Interface.cpp:693
MoCAInterface::get_X_RDKCENTRAL_COM_MeshTableNumberOfEntries
int get_X_RDKCENTRAL_COM_MeshTableNumberOfEntries(HOSTIF_MsgData_t *, bool *pChanged=NULL)
Get the number of entries in the X_RDKCENTRAL_COM_MeshTable table of a MoCA Interface.
Definition: Device_MoCA_Interface.cpp:1053
RMH_Self_GetSupportedFrequencies
RMH_Result RMH_Self_GetSupportedFrequencies(const RMH_Handle handle, uint32_t *responseArray, const size_t responseArraySize, size_t *responseArrayUsed)
Return a list of frequencies in the band used by this node.
RMH_Power_GetTxBeaconPowerReduction
RMH_Result RMH_Power_GetTxBeaconPowerReduction(const RMH_Handle handle, uint32_t *response)
Return the power control back-off used by this node for transmitting beacons.
RMH
Definition: librmh.h:57
MoCAInterface::get_LowerLayers
int get_LowerLayers(HOSTIF_MsgData_t *, bool *pChanged=NULL)
Get the path name of the MoCA interface object.
Definition: Device_MoCA_Interface.cpp:398
RMH_Power_SetTxBeaconPowerReduction
RMH_Result RMH_Power_SetTxBeaconPowerReduction(const RMH_Handle handle, const uint32_t value)
Set the power control back-off used by this node for transmitting beacons.
MoCAInterface::get_HighestVersion
int get_HighestVersion(HOSTIF_MsgData_t *, bool *pChanged=NULL)
Get the identifies the highest MoCA version that this interface supports.
Definition: Device_MoCA_Interface.cpp:534
_HostIf_MsgData_t::paramtype
HostIf_ParamType_t paramtype
Definition: hostIf_tr69ReqHandler.h:177
MoCAInterface::get_BackupNC
int get_BackupNC(HOSTIF_MsgData_t *, bool *pChanged=NULL)
Get the Node ID of the backup Network Coordinator node.
Definition: Device_MoCA_Interface.cpp:652
MoCAInterface::get_NetworkCoordinator
int get_NetworkCoordinator(HOSTIF_MsgData_t *, bool *pChanged=NULL)
Get the Node ID of the current Network Coordinator (NC) for the MoCA network.
Definition: Device_MoCA_Interface.cpp:578
MoCAInterface::get_AssociatedDeviceNumberOfEntries
int get_AssociatedDeviceNumberOfEntries(HOSTIF_MsgData_t *, bool *pChanged=NULL)
The number of entries in the AssociatedDevice table.
Definition: Device_MoCA_Interface.cpp:1043
RDK_LOG
#define RDK_LOG
Definition: rdk_debug.h:258
_HostIf_MsgData_t::faultCode
faultCode_t faultCode
Definition: hostIf_tr69ReqHandler.h:179
RMH_Network_GetTabooChannels
RMH_Result RMH_Network_GetTabooChannels(const RMH_Handle handle, uint32_t *channelMaskStart, uint32_t *channelMask)
Return which beacon channels will be taboo on this device.
RMH_Self_GetSoftwareVersion
RMH_Result RMH_Self_GetSoftwareVersion(const RMH_Handle handle, char *responseBuf, const size_t responseBufSize)
Return the version of software being used by the MoCA driver on this device. [mocaIfSoftwareVersion].
RMH_Self_SetPrivacyPassword
RMH_Result RMH_Self_SetPrivacyPassword(const RMH_Handle handle, const char *value)
Set the network password used to generate privacy keys.
RMH_Network_GetAssociatedIds
RMH_Result RMH_Network_GetAssociatedIds(const RMH_Handle handle, RMH_NodeList_Uint32_t *response)
Return a list of the associated ID for every node on the network.
_HostIf_MsgData_t::paramName
char paramName[(4 *1024)]
Definition: hostIf_tr69ReqHandler.h:171
RMH_MacToString
const char *const RMH_MacToString(const RMH_MacAddress_t value, char *responseBuf, const size_t responseBufSize)
Returns the provided MAC address in value as a string.
Definition: librmh_api_no_wrap.c:174
Device_MoCA_Interface.h
MoCAInterface::get_MaxBitRate
int get_MaxBitRate(HOSTIF_MsgData_t *, bool *pChanged=NULL)
Get the maximum MoCA PHY bit rate (expressed in Mbps).
Definition: Device_MoCA_Interface.cpp:471
RMH_Self_SetEnabled
RMH_Result RMH_Self_SetEnabled(const RMH_Handle handle, const bool value)
Enable or disable the MoCA driver to connect to a MoCA network. Once enabled the driver will use what...
MoCAInterface::get_FirmwareVersion
int get_FirmwareVersion(HOSTIF_MsgData_t *, bool *pChanged=NULL)
Get the MoCA interface's firmware version.
Definition: Device_MoCA_Interface.cpp:448
RMH_Initialize
RMH_Handle RMH_Initialize(const RMH_EventCallback eventCB, void *userContext)
Initialize the RMH library and return a handle to the instance.
Definition: librmh_api_no_wrap.c:23
RMH_Interface_GetMac
RMH_Result RMH_Interface_GetMac(const RMH_Handle handle, RMH_MacAddress_t *response)
Return the MAC address associated with this MoCA device. [mocaIfMacAddress].
RMH_Network_GetNCNodeId
RMH_Result RMH_Network_GetNCNodeId(const RMH_Handle handle, uint32_t *response)
Return the node ID of the network coordinator. [mocaIfNC].
MoCAInterface::get_QAM256Capable
int get_QAM256Capable(HOSTIF_MsgData_t *, bool *pChanged=NULL)
Check whether this interface supports the 256 QAM feature.
Definition: Device_MoCA_Interface.cpp:1002
RMH_ResultToString
const char *const RMH_ResultToString(const RMH_Result value)
Convert RMH_Result to a string.
Definition: librmh_api_no_wrap.c:84
RMH_Self_SetTxPowerLimit
RMH_Result RMH_Self_SetTxPowerLimit(const RMH_Handle handle, const int32_t value)
Set the maximum transmitter power level for this device.
RMH_Self_GetPrivacyEnabled
RMH_Result RMH_Self_GetPrivacyEnabled(const RMH_Handle handle, bool *response)
Return if MoCA privacy is enabled on this device.
_HostIf_MsgData_t::paramValue
char paramValue[(4 *1024)]
Definition: hostIf_tr69ReqHandler.h:172
MoCAInterface::get_X_RDKCENTRAL_COM_TurboMode
int get_X_RDKCENTRAL_COM_TurboMode(HOSTIF_MsgData_t *)
Get the MoCA status for BootStatus.
Definition: Device_MoCA_Interface.cpp:1125
RMH_Self_GetMaxPacketAggregation
RMH_Result RMH_Self_GetMaxPacketAggregation(const RMH_Handle handle, uint32_t *response)
Get the maximum number of packets this device will aggregate.
MoCAInterface::get_CurrentOperFreq
int get_CurrentOperFreq(HOSTIF_MsgData_t *, bool *pChanged=NULL)
Get the current Operational Frequency. The RF frequency in Hz to which the MoCA interface is currentl...
Definition: Device_MoCA_Interface.cpp:791
RMH_Destroy
RMH_Result RMH_Destroy(RMH_Handle handle)
Destroy the instance of RMH library which was created by RMH_Initialize.
RMH_Self_GetTabooChannels
RMH_Result RMH_Self_GetTabooChannels(const RMH_Handle handle, uint32_t *channelMaskStart, uint32_t *channelMask)
Return which channels will be taboo on this device.
RMH_Self_SetPrivacyEnabled
RMH_Result RMH_Self_SetPrivacyEnabled(const RMH_Handle handle, const bool value)
Enable or disable MoCA privacy on this device.
MoCAInterface::get_PrivacyEnabledSetting
int get_PrivacyEnabledSetting(HOSTIF_MsgData_t *, bool *pChanged=NULL)
Get the configured privacy mode. This indicates whether link-layer security is enabled (true) or disa...
Definition: Device_MoCA_Interface.cpp:673
MoCAInterface::set_FreqCurrentMaskSetting
int set_FreqCurrentMaskSetting(HOSTIF_MsgData_t *)
Set the configured hexadecimal encoded 64-bit mask of enabled frequencies for network admission.
Definition: Device_MoCA_Interface.cpp:1302
MoCAInterface::get_MaxEgressBW
int get_MaxEgressBW(HOSTIF_MsgData_t *, bool *pChanged=NULL)
Get the maximum bandwidth of this interface for flows from the MoCA network in Mbps.
Definition: Device_MoCA_Interface.cpp:513
MoCAInterface::get_MaxIngressBW
int get_MaxIngressBW(HOSTIF_MsgData_t *, bool *pChanged=NULL)
Get the maximum bandwidth of this interface for flows onto the MoCA network in Mbps.
Definition: Device_MoCA_Interface.cpp:491
RMH_PQoS_GetMaxEgressBandwidth
RMH_Result RMH_PQoS_GetMaxEgressBandwidth(const RMH_Handle handle, uint32_t *response)
Return the node Id with the maximum available bandwidth.
RMH_Self_GetFrequencyMask
RMH_Result RMH_Self_GetFrequencyMask(const RMH_Handle handle, uint32_t *response)
Gets the bit mask of frequencies the device used during the listening phase of network search.
MoCAInterface::get_Status
int get_Status(HOSTIF_MsgData_t *, bool *pChanged=NULL)
Get the current operational state of the interface (see [Section 4.2.2/TR-181i2])....
Definition: Device_MoCA_Interface.cpp:310
MoCAInterface::check_MoCABootStatus
int check_MoCABootStatus(char *)
Get the MoCA status for BootStatus.
Definition: Device_MoCA_Interface.cpp:1146
RMH_Self_GetEnabled
RMH_Result RMH_Self_GetEnabled(const RMH_Handle handle, bool *response)
Return if the MoCA driver is actively connected to or attempting to connect to a MoCA network.
MoCAInterface::get_MaxNodes
int get_MaxNodes(HOSTIF_MsgData_t *, bool *pChanged=NULL)
Get the maximum network node capability supported by the interface. If MaxNodes is true then the inte...
Definition: Device_MoCA_Interface.cpp:622
MoCAInterface::get_Enable
int get_Enable(HOSTIF_MsgData_t *, bool *pChanged=NULL)
Get the status (enabled/disabled) of the MoCA Interface.
Definition: Device_MoCA_Interface.cpp:289
MoCAInterface::get_Alias
int get_Alias(HOSTIF_MsgData_t *, bool *pChanged=NULL)
Get the Alias-based addressing used for MoCA interface.
Definition: Device_MoCA_Interface.cpp:348
RMH_Network_GetPrimaryChannelFreq
RMH_Result RMH_Network_GetPrimaryChannelFreq(const RMH_Handle handle, uint32_t *response)
Return the primary MoCA 2.0 channel.
MoCAInterface::set_PrivacyEnabledSetting
int set_PrivacyEnabledSetting(HOSTIF_MsgData_t *)
Set the configured privacy mode. This indicates whether link-layer security is enabled (true) or disa...
Definition: Device_MoCA_Interface.cpp:1281
MoCAInterface::get_LastOperFreq
int get_LastOperFreq(HOSTIF_MsgData_t *, bool *pChanged=NULL)
Get the last Operational Frequency. The RF frequency in Hz to which the MoCA interface was tuned when...
Definition: Device_MoCA_Interface.cpp:813
MoCAInterface::set_BeaconPowerLimit
int set_BeaconPowerLimit(HOSTIF_MsgData_t *)
Set the Beacon Transmit Power attenuation in dB relative to the maximum transmit power.
Definition: Device_MoCA_Interface.cpp:1385
MoCAInterface::get_X_RDKCENTRAL_COM_NodePowerState
int get_X_RDKCENTRAL_COM_NodePowerState(HOSTIF_MsgData_t *)
Get the MoCA status for BootStatus.
Definition: Device_MoCA_Interface.cpp:1105
RMH_Interface_GetName
RMH_Result RMH_Interface_GetName(const RMH_Handle handle, char *responseBuf, const size_t responseBufSize)
Return the Linux interface name associated with the MoCA device. [mocaIfName].
RMH_Self_GetLOF
RMH_Result RMH_Self_GetLOF(const RMH_Handle handle, uint32_t *response)
The last frequency on which this device operated.
MoCAInterface::get_FreqCurrentMaskSetting
int get_FreqCurrentMaskSetting(HOSTIF_MsgData_t *, bool *pChanged=NULL)
Get the configured hexadecimal encoded 64-bit mask of enabled frequencies for network admission.
Definition: Device_MoCA_Interface.cpp:743
MoCAInterface::get_PreferredNC
int get_PreferredNC(HOSTIF_MsgData_t *, bool *pChanged=NULL)
Check Whether this interface is a preferred Network Coordinator (NC).
Definition: Device_MoCA_Interface.cpp:630
put_int
void put_int(char *ptr, int val)
This function converts the input data to integer type.
Definition: hostIf_utils.cpp:152
MoCAInterface::get_CurrentVersion
int get_CurrentVersion(HOSTIF_MsgData_t *, bool *pChanged=NULL)
Get the MoCA version that the MoCA network is currently running.
Definition: Device_MoCA_Interface.cpp:557
RMH_Network_GetMoCAVersion
RMH_Result RMH_Network_GetMoCAVersion(const RMH_Handle handle, RMH_MoCAVersion *response)
Return the version of MoCA under which the network is operating. [mocaIfNetworkVersion].
RMH_Network_GetTxBroadcastPhyRate
RMH_Result RMH_Network_GetTxBroadcastPhyRate(const RMH_Handle handle, uint32_t *response)
Return the PHY rate at which broadcast packets are transmitted from this node.
MoCAInterface::get_X_RDKCENTRAL_COM_PrimaryChannelFreq
int get_X_RDKCENTRAL_COM_PrimaryChannelFreq(HOSTIF_MsgData_t *)
Get the X_RDKCENTRAL_COM_PrimaryChannelFreq of a MoCA Interface.
Definition: Device_MoCA_Interface.cpp:1063
_HostIf_MsgData_t::paramLen
short paramLen
Definition: hostIf_tr69ReqHandler.h:175
MoCAInterface::set_KeyPassphrase
int set_KeyPassphrase(HOSTIF_MsgData_t *)
Set the MoCA Password. The value consists of numeric characters (0-9). Possible patterns:
Definition: Device_MoCA_Interface.cpp:1323
RMH_Self_GetTxPowerLimit
RMH_Result RMH_Self_GetTxPowerLimit(const RMH_Handle handle, int32_t *response)
Returns the maximum transmitter power level for this device.
MoCAInterface::set_TxPowerLimit
int set_TxPowerLimit(HOSTIF_MsgData_t *)
Set the transmit Power attenuation in dB relative to the maximum transmit power.
Definition: Device_MoCA_Interface.cpp:1345
MoCAInterface::get_LastChange
int get_LastChange(HOSTIF_MsgData_t *, bool *pChanged=NULL)
Get the accumulated time in seconds since the interface entered its current operational state.
Definition: Device_MoCA_Interface.cpp:377
RMH_Self_GetQAM256Enabled
RMH_Result RMH_Self_GetQAM256Enabled(const RMH_Handle handle, bool *response)
Return if this device is set as QAM256 capable in admission negotiations.
MoCAInterface::get_FreqCurrentMask
int get_FreqCurrentMask(HOSTIF_MsgData_t *, bool *pChanged=NULL)
Get the hexadecimal encoded 64-bit mask of used frequencies. This is the bit map of the spectrum that...
Definition: Device_MoCA_Interface.cpp:767