zcl_samplesw.c 18 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605
  1. /**************************************************************************************************
  2. Filename: zcl_samplesw.c
  3. Revised: $Date: 2009-03-18 15:56:27 -0700 (Wed, 18 Mar 2009) $
  4. Revision: $Revision: 19453 $
  5. Description: Zigbee Cluster Library - sample device application.
  6. Copyright 2006-2009 Texas Instruments Incorporated. All rights reserved.
  7. IMPORTANT: Your use of this Software is limited to those specific rights
  8. granted under the terms of a software license agreement between the user
  9. who downloaded the software, his/her employer (which must be your employer)
  10. and Texas Instruments Incorporated (the "License"). You may not use this
  11. Software unless you agree to abide by the terms of the License. The License
  12. limits your use, and you acknowledge, that the Software may not be modified,
  13. copied or distributed unless embedded on a Texas Instruments microcontroller
  14. or used solely and exclusively in conjunction with a Texas Instruments radio
  15. frequency transceiver, which is integrated into your product. Other than for
  16. the foregoing purpose, you may not use, reproduce, copy, prepare derivative
  17. works of, modify, distribute, perform, display or sell this Software and/or
  18. its documentation for any purpose.
  19. YOU FURTHER ACKNOWLEDGE AND AGREE THAT THE SOFTWARE AND DOCUMENTATION ARE
  20. PROVIDED “AS IS” WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESS OR IMPLIED,
  21. INCLUDING WITHOUT LIMITATION, ANY WARRANTY OF MERCHANTABILITY, TITLE,
  22. NON-INFRINGEMENT AND FITNESS FOR A PARTICULAR PURPOSE. IN NO EVENT SHALL
  23. TEXAS INSTRUMENTS OR ITS LICENSORS BE LIABLE OR OBLIGATED UNDER CONTRACT,
  24. NEGLIGENCE, STRICT LIABILITY, CONTRIBUTION, BREACH OF WARRANTY, OR OTHER
  25. LEGAL EQUITABLE THEORY ANY DIRECT OR INDIRECT DAMAGES OR EXPENSES
  26. INCLUDING BUT NOT LIMITED TO ANY INCIDENTAL, SPECIAL, INDIRECT, PUNITIVE
  27. OR CONSEQUENTIAL DAMAGES, LOST PROFITS OR LOST DATA, COST OF PROCUREMENT
  28. OF SUBSTITUTE GOODS, TECHNOLOGY, SERVICES, OR ANY CLAIMS BY THIRD PARTIES
  29. (INCLUDING BUT NOT LIMITED TO ANY DEFENSE THEREOF), OR OTHER SIMILAR COSTS.
  30. Should you have any questions regarding your right to use this Software,
  31. contact Texas Instruments Incorporated at www.TI.com.
  32. **************************************************************************************************/
  33. /*********************************************************************
  34. This device will be like an On/Off Switch device. This application
  35. is not intended to be a On/Off Switch device, but will use the device
  36. description to implement this sample code.
  37. *********************************************************************/
  38. /*********************************************************************
  39. * INCLUDES
  40. */
  41. #include "ZComDef.h"
  42. #include "OSAL.h"
  43. #include "AF.h"
  44. #include "ZDApp.h"
  45. #include "ZDObject.h"
  46. #include "ZDProfile.h"
  47. #include "zcl.h"
  48. #include "zcl_general.h"
  49. #include "zcl_ha.h"
  50. #include "zcl_samplesw.h"
  51. #include "onboard.h"
  52. /* HAL */
  53. #include "hal_lcd.h"
  54. #include "hal_led.h"
  55. #include "hal_key.h"
  56. /*********************************************************************
  57. * MACROS
  58. */
  59. /*********************************************************************
  60. * CONSTANTS
  61. */
  62. /*********************************************************************
  63. * TYPEDEFS
  64. */
  65. /*********************************************************************
  66. * GLOBAL VARIABLES
  67. */
  68. byte zclSampleSw_TaskID;
  69. /*********************************************************************
  70. * GLOBAL FUNCTIONS
  71. */
  72. /*********************************************************************
  73. * LOCAL VARIABLES
  74. */
  75. static afAddrType_t zclSampleSw_DstAddr;
  76. #define ZCLSAMPLESW_BINDINGLIST 1
  77. static cId_t bindingOutClusters[ZCLSAMPLESW_BINDINGLIST] =
  78. {
  79. ZCL_CLUSTER_ID_GEN_ON_OFF
  80. };
  81. // Test Endpoint to allow SYS_APP_MSGs
  82. static endPointDesc_t sampleSw_TestEp =
  83. {
  84. 20, // Test endpoint
  85. &zclSampleSw_TaskID,
  86. (SimpleDescriptionFormat_t *)NULL, // No Simple description for this test endpoint
  87. (afNetworkLatencyReq_t)0 // No Network Latency req
  88. };
  89. /*********************************************************************
  90. * LOCAL FUNCTIONS
  91. */
  92. static void zclSampleSw_ProcessZDOMsgs( zdoIncomingMsg_t *inMsg );
  93. static void zclSampleSw_HandleKeys( byte shift, byte keys );
  94. static void zclSampleSw_BasicResetCB( void );
  95. static void zclSampleSw_IdentifyCB( zclIdentify_t *pCmd );
  96. static void zclSampleSw_IdentifyQueryRspCB( zclIdentifyQueryRsp_t *pRsp );
  97. static void zclSampleSw_ProcessIdentifyTimeChange( void );
  98. // Functions to process ZCL Foundation incoming Command/Response messages
  99. static void zclSampleSw_ProcessIncomingMsg( zclIncomingMsg_t *msg );
  100. #ifdef ZCL_READ
  101. static uint8 zclSampleSw_ProcessInReadRspCmd( zclIncomingMsg_t *pInMsg );
  102. #endif
  103. #ifdef ZCL_WRITE
  104. static uint8 zclSampleSw_ProcessInWriteRspCmd( zclIncomingMsg_t *pInMsg );
  105. #endif
  106. static uint8 zclSampleSw_ProcessInDefaultRspCmd( zclIncomingMsg_t *pInMsg );
  107. #ifdef ZCL_DISCOVER
  108. static uint8 zclSampleSw_ProcessInDiscRspCmd( zclIncomingMsg_t *pInMsg );
  109. #endif
  110. /*********************************************************************
  111. * ZCL General Profile Callback table
  112. */
  113. static zclGeneral_AppCallbacks_t zclSampleSw_CmdCallbacks =
  114. {
  115. zclSampleSw_BasicResetCB, // Basic Cluster Reset command
  116. zclSampleSw_IdentifyCB, // Identify command
  117. zclSampleSw_IdentifyQueryRspCB, // Identify Query Response command
  118. NULL, // On / Off cluster command - not needed.
  119. NULL, // Level Control Move to Level command
  120. NULL, // Level Control Move command
  121. NULL, // Level Control Step command
  122. NULL, // Group Response commands
  123. NULL, // Scene Store Request command
  124. NULL, // Scene Recall Request command
  125. NULL, // Scene Response commands
  126. NULL, // Alarm (Response) commands
  127. NULL, // RSSI Location commands
  128. NULL, // RSSI Location Response commands
  129. };
  130. /*********************************************************************
  131. * @fn zclSampleSw_Init
  132. *
  133. * @brief Initialization function for the zclGeneral layer.
  134. *
  135. * @param none
  136. *
  137. * @return none
  138. */
  139. void zclSampleSw_Init( byte task_id )
  140. {
  141. zclSampleSw_TaskID = task_id;
  142. // Set destination address to indirect
  143. zclSampleSw_DstAddr.addrMode = (afAddrMode_t)AddrNotPresent;
  144. zclSampleSw_DstAddr.endPoint = 0;
  145. zclSampleSw_DstAddr.addr.shortAddr = 0;
  146. // This app is part of the Home Automation Profile
  147. zclHA_Init( &zclSampleSw_SimpleDesc );
  148. // Register the ZCL General Cluster Library callback functions
  149. zclGeneral_RegisterCmdCallbacks( SAMPLESW_ENDPOINT, &zclSampleSw_CmdCallbacks );
  150. // Register the application's attribute list
  151. zcl_registerAttrList( SAMPLESW_ENDPOINT, SAMPLESW_MAX_ATTRIBUTES, zclSampleSw_Attrs );
  152. // Register the Application to receive the unprocessed Foundation command/response messages
  153. zcl_registerForMsg( zclSampleSw_TaskID );
  154. // Register for all key events - This app will handle all key events
  155. RegisterForKeys( zclSampleSw_TaskID );
  156. // Register for a test endpoint
  157. afRegister( &sampleSw_TestEp );
  158. ZDO_RegisterForZDOMsg( zclSampleSw_TaskID, End_Device_Bind_rsp );
  159. ZDO_RegisterForZDOMsg( zclSampleSw_TaskID, Match_Desc_rsp );
  160. }
  161. /*********************************************************************
  162. * @fn zclSample_event_loop
  163. *
  164. * @brief Event Loop Processor for zclGeneral.
  165. *
  166. * @param none
  167. *
  168. * @return none
  169. */
  170. uint16 zclSampleSw_event_loop( uint8 task_id, uint16 events )
  171. {
  172. afIncomingMSGPacket_t *MSGpkt;
  173. (void)task_id; // Intentionally unreferenced parameter
  174. if ( events & SYS_EVENT_MSG )
  175. {
  176. while ( (MSGpkt = (afIncomingMSGPacket_t *)osal_msg_receive( zclSampleSw_TaskID )) )
  177. {
  178. switch ( MSGpkt->hdr.event )
  179. {
  180. case ZCL_INCOMING_MSG:
  181. // Incoming ZCL Foundation command/response messages
  182. zclSampleSw_ProcessIncomingMsg( (zclIncomingMsg_t *)MSGpkt );
  183. break;
  184. case ZDO_CB_MSG:
  185. zclSampleSw_ProcessZDOMsgs( (zdoIncomingMsg_t *)MSGpkt );
  186. break;
  187. case KEY_CHANGE:
  188. zclSampleSw_HandleKeys( ((keyChange_t *)MSGpkt)->state, ((keyChange_t *)MSGpkt)->keys );
  189. break;
  190. default:
  191. break;
  192. }
  193. // Release the memory
  194. osal_msg_deallocate( (uint8 *)MSGpkt );
  195. }
  196. // return unprocessed events
  197. return (events ^ SYS_EVENT_MSG);
  198. }
  199. if ( events & SAMPLESW_IDENTIFY_TIMEOUT_EVT )
  200. {
  201. zclSampleSw_IdentifyTime = 10;
  202. zclSampleSw_ProcessIdentifyTimeChange();
  203. return ( events ^ SAMPLESW_IDENTIFY_TIMEOUT_EVT );
  204. }
  205. // Discard unknown events
  206. return 0;
  207. }
  208. /*********************************************************************
  209. * @fn zclSampleSw_ProcessZDOMsgs()
  210. *
  211. * @brief Process response messages
  212. *
  213. * @param none
  214. *
  215. * @return none
  216. */
  217. void zclSampleSw_ProcessZDOMsgs( zdoIncomingMsg_t *inMsg )
  218. {
  219. switch ( inMsg->clusterID )
  220. {
  221. case End_Device_Bind_rsp:
  222. if ( ZDO_ParseBindRsp( inMsg ) == ZSuccess )
  223. {
  224. // Light LED
  225. HalLedSet( HAL_LED_4, HAL_LED_MODE_ON );
  226. }
  227. #if defined(BLINK_LEDS)
  228. else
  229. {
  230. // Flash LED to show failure
  231. HalLedSet ( HAL_LED_4, HAL_LED_MODE_FLASH );
  232. }
  233. #endif
  234. break;
  235. case Match_Desc_rsp:
  236. {
  237. ZDO_ActiveEndpointRsp_t *pRsp = ZDO_ParseEPListRsp( inMsg );
  238. if ( pRsp )
  239. {
  240. if ( pRsp->status == ZSuccess && pRsp->cnt )
  241. {
  242. zclSampleSw_DstAddr.addrMode = (afAddrMode_t)Addr16Bit;
  243. zclSampleSw_DstAddr.addr.shortAddr = pRsp->nwkAddr;
  244. // Take the first endpoint, Can be changed to search through endpoints
  245. zclSampleSw_DstAddr.endPoint = pRsp->epList[0];
  246. // Light LED
  247. HalLedSet( HAL_LED_4, HAL_LED_MODE_ON );
  248. }
  249. osal_mem_free( pRsp );
  250. }
  251. }
  252. break;
  253. }
  254. }
  255. /*********************************************************************
  256. * @fn zclSampleSw_HandleKeys
  257. *
  258. * @brief Handles all key events for this device.
  259. *
  260. * @param shift - true if in shift/alt.
  261. * @param keys - bit field for key events. Valid entries:
  262. * HAL_KEY_SW_4
  263. * HAL_KEY_SW_3
  264. * HAL_KEY_SW_2
  265. * HAL_KEY_SW_1
  266. *
  267. * @return none
  268. */
  269. static void zclSampleSw_HandleKeys( byte shift, byte keys )
  270. {
  271. zAddrType_t dstAddr;
  272. (void)shift; // Intentionally unreferenced parameter
  273. if ( keys & HAL_KEY_SW_1 )
  274. {
  275. // Using this as the "Light Switch"
  276. #ifdef ZCL_ON_OFF
  277. zclGeneral_SendOnOff_CmdToggle( SAMPLESW_ENDPOINT, &zclSampleSw_DstAddr, false, 0 );
  278. #endif
  279. }
  280. if ( keys & HAL_KEY_SW_2 )
  281. {
  282. HalLedSet ( HAL_LED_4, HAL_LED_MODE_OFF );
  283. // Initiate an End Device Bind Request, this bind request will
  284. // only use a cluster list that is important to binding.
  285. dstAddr.addrMode = afAddr16Bit;
  286. dstAddr.addr.shortAddr = 0; // Coordinator makes the match
  287. ZDP_EndDeviceBindReq( &dstAddr, NLME_GetShortAddr(),
  288. SAMPLESW_ENDPOINT,
  289. ZCL_HA_PROFILE_ID,
  290. 0, NULL, // No incoming clusters to bind
  291. ZCLSAMPLESW_BINDINGLIST, bindingOutClusters,
  292. TRUE );
  293. }
  294. if ( keys & HAL_KEY_SW_3 )
  295. {
  296. }
  297. if ( keys & HAL_KEY_SW_4 )
  298. {
  299. HalLedSet ( HAL_LED_4, HAL_LED_MODE_OFF );
  300. // Initiate a Match Description Request (Service Discovery)
  301. dstAddr.addrMode = AddrBroadcast;
  302. dstAddr.addr.shortAddr = NWK_BROADCAST_SHORTADDR;
  303. ZDP_MatchDescReq( &dstAddr, NWK_BROADCAST_SHORTADDR,
  304. ZCL_HA_PROFILE_ID,
  305. ZCLSAMPLESW_BINDINGLIST, bindingOutClusters,
  306. 0, NULL, // No incoming clusters to bind
  307. FALSE );
  308. }
  309. }
  310. /*********************************************************************
  311. * @fn zclSampleSw_ProcessIdentifyTimeChange
  312. *
  313. * @brief Called to process any change to the IdentifyTime attribute.
  314. *
  315. * @param none
  316. *
  317. * @return none
  318. */
  319. static void zclSampleSw_ProcessIdentifyTimeChange( void )
  320. {
  321. if ( zclSampleSw_IdentifyTime > 0 )
  322. {
  323. osal_start_timerEx( zclSampleSw_TaskID, SAMPLESW_IDENTIFY_TIMEOUT_EVT, 1000 );
  324. HalLedBlink ( HAL_LED_4, 0xFF, HAL_LED_DEFAULT_DUTY_CYCLE, HAL_LED_DEFAULT_FLASH_TIME );
  325. }
  326. else
  327. {
  328. if ( zclSampleSw_OnOff )
  329. HalLedSet ( HAL_LED_4, HAL_LED_MODE_ON );
  330. else
  331. HalLedSet ( HAL_LED_4, HAL_LED_MODE_OFF );
  332. osal_stop_timerEx( zclSampleSw_TaskID, SAMPLESW_IDENTIFY_TIMEOUT_EVT );
  333. }
  334. }
  335. /*********************************************************************
  336. * @fn zclSampleSw_BasicResetCB
  337. *
  338. * @brief Callback from the ZCL General Cluster Library
  339. * to set all the Basic Cluster attributes to default values.
  340. *
  341. * @param none
  342. *
  343. * @return none
  344. */
  345. static void zclSampleSw_BasicResetCB( void )
  346. {
  347. }
  348. /*********************************************************************
  349. * @fn zclSampleSw_IdentifyCB
  350. *
  351. * @brief Callback from the ZCL General Cluster Library when
  352. * it received an Identity Command for this application.
  353. *
  354. * @param srcAddr - source address and endpoint of the response message
  355. * @param identifyTime - the number of seconds to identify yourself
  356. *
  357. * @return none
  358. */
  359. static void zclSampleSw_IdentifyCB( zclIdentify_t *pCmd )
  360. {
  361. zclSampleSw_IdentifyTime = pCmd->identifyTime;
  362. zclSampleSw_ProcessIdentifyTimeChange();
  363. }
  364. /*********************************************************************
  365. * @fn zclSampleSw_IdentifyQueryRspCB
  366. *
  367. * @brief Callback from the ZCL General Cluster Library when
  368. * it received an Identity Query Response Command for this application.
  369. *
  370. * @param srcAddr - source address
  371. * @param timeout - number of seconds to identify yourself (valid for query response)
  372. *
  373. * @return none
  374. */
  375. static void zclSampleSw_IdentifyQueryRspCB( zclIdentifyQueryRsp_t *pRsp )
  376. {
  377. // Query Response (with timeout value)
  378. (void)pRsp;
  379. }
  380. /******************************************************************************
  381. *
  382. * Functions for processing ZCL Foundation incoming Command/Response messages
  383. *
  384. *****************************************************************************/
  385. /*********************************************************************
  386. * @fn zclSampleSw_ProcessIncomingMsg
  387. *
  388. * @brief Process ZCL Foundation incoming message
  389. *
  390. * @param pInMsg - pointer to the received message
  391. *
  392. * @return none
  393. */
  394. static void zclSampleSw_ProcessIncomingMsg( zclIncomingMsg_t *pInMsg )
  395. {
  396. switch ( pInMsg->zclHdr.commandID )
  397. {
  398. #ifdef ZCL_READ
  399. case ZCL_CMD_READ_RSP:
  400. zclSampleSw_ProcessInReadRspCmd( pInMsg );
  401. break;
  402. #endif
  403. #ifdef ZCL_WRITE
  404. case ZCL_CMD_WRITE_RSP:
  405. zclSampleSw_ProcessInWriteRspCmd( pInMsg );
  406. break;
  407. #endif
  408. #ifdef ZCL_REPORT
  409. // See ZCL Test Applicaiton (zcl_testapp.c) for sample code on Attribute Reporting
  410. case ZCL_CMD_CONFIG_REPORT:
  411. //zclSampleSw_ProcessInConfigReportCmd( pInMsg );
  412. break;
  413. case ZCL_CMD_CONFIG_REPORT_RSP:
  414. //zclSampleSw_ProcessInConfigReportRspCmd( pInMsg );
  415. break;
  416. case ZCL_CMD_READ_REPORT_CFG:
  417. //zclSampleSw_ProcessInReadReportCfgCmd( pInMsg );
  418. break;
  419. case ZCL_CMD_READ_REPORT_CFG_RSP:
  420. //zclSampleSw_ProcessInReadReportCfgRspCmd( pInMsg );
  421. break;
  422. case ZCL_CMD_REPORT:
  423. //zclSampleSw_ProcessInReportCmd( pInMsg );
  424. break;
  425. #endif
  426. case ZCL_CMD_DEFAULT_RSP:
  427. zclSampleSw_ProcessInDefaultRspCmd( pInMsg );
  428. break;
  429. #ifdef ZCL_DISCOVER
  430. case ZCL_CMD_DISCOVER_RSP:
  431. zclSampleSw_ProcessInDiscRspCmd( pInMsg );
  432. break;
  433. #endif
  434. default:
  435. break;
  436. }
  437. if ( pInMsg->attrCmd )
  438. osal_mem_free( pInMsg->attrCmd );
  439. }
  440. #ifdef ZCL_READ
  441. /*********************************************************************
  442. * @fn zclSampleSw_ProcessInReadRspCmd
  443. *
  444. * @brief Process the "Profile" Read Response Command
  445. *
  446. * @param pInMsg - incoming message to process
  447. *
  448. * @return none
  449. */
  450. static uint8 zclSampleSw_ProcessInReadRspCmd( zclIncomingMsg_t *pInMsg )
  451. {
  452. zclReadRspCmd_t *readRspCmd;
  453. uint8 i;
  454. readRspCmd = (zclReadRspCmd_t *)pInMsg->attrCmd;
  455. for (i = 0; i < readRspCmd->numAttr; i++)
  456. {
  457. // Notify the originator of the results of the original read attributes
  458. // attempt and, for each successfull request, the value of the requested
  459. // attribute
  460. }
  461. return TRUE;
  462. }
  463. #endif // ZCL_READ
  464. #ifdef ZCL_WRITE
  465. /*********************************************************************
  466. * @fn zclSampleSw_ProcessInWriteRspCmd
  467. *
  468. * @brief Process the "Profile" Write Response Command
  469. *
  470. * @param pInMsg - incoming message to process
  471. *
  472. * @return none
  473. */
  474. static uint8 zclSampleSw_ProcessInWriteRspCmd( zclIncomingMsg_t *pInMsg )
  475. {
  476. zclWriteRspCmd_t *writeRspCmd;
  477. uint8 i;
  478. writeRspCmd = (zclWriteRspCmd_t *)pInMsg->attrCmd;
  479. for (i = 0; i < writeRspCmd->numAttr; i++)
  480. {
  481. // Notify the device of the results of the its original write attributes
  482. // command.
  483. }
  484. return TRUE;
  485. }
  486. #endif // ZCL_WRITE
  487. /*********************************************************************
  488. * @fn zclSampleSw_ProcessInDefaultRspCmd
  489. *
  490. * @brief Process the "Profile" Default Response Command
  491. *
  492. * @param pInMsg - incoming message to process
  493. *
  494. * @return none
  495. */
  496. static uint8 zclSampleSw_ProcessInDefaultRspCmd( zclIncomingMsg_t *pInMsg )
  497. {
  498. // zclDefaultRspCmd_t *defaultRspCmd = (zclDefaultRspCmd_t *)pInMsg->attrCmd;
  499. // Device is notified of the Default Response command.
  500. (void)pInMsg;
  501. return TRUE;
  502. }
  503. #ifdef ZCL_DISCOVER
  504. /*********************************************************************
  505. * @fn zclSampleSw_ProcessInDiscRspCmd
  506. *
  507. * @brief Process the "Profile" Discover Response Command
  508. *
  509. * @param pInMsg - incoming message to process
  510. *
  511. * @return none
  512. */
  513. static uint8 zclSampleSw_ProcessInDiscRspCmd( zclIncomingMsg_t *pInMsg )
  514. {
  515. zclDiscoverRspCmd_t *discoverRspCmd;
  516. uint8 i;
  517. discoverRspCmd = (zclDiscoverRspCmd_t *)pInMsg->attrCmd;
  518. for ( i = 0; i < discoverRspCmd->numAttr; i++ )
  519. {
  520. // Device is notified of the result of its attribute discovery command.
  521. }
  522. return TRUE;
  523. }
  524. #endif // ZCL_DISCOVER
  525. /****************************************************************************
  526. ****************************************************************************/