zcl_closures.h 23 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452
  1. /**************************************************************************************************
  2. Filename: zcl_closures.h
  3. Revised: $Date: 2011-05-02 10:30:51 -0700 (Mon, 02 May 2011) $
  4. Revision: $Revision: 25832 $
  5. Description: This file contains the ZCL Closures definitions.
  6. Copyright 2006-2011 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. #ifndef ZCL_CLOSURES_H
  34. #define ZCL_CLOSURES_H
  35. #ifdef __cplusplus
  36. extern "C"
  37. {
  38. #endif
  39. /*********************************************************************
  40. * INCLUDES
  41. */
  42. #include "zcl.h"
  43. /*********************************************************************
  44. * CONSTANTS
  45. */
  46. /**********************************************/
  47. /*** Shade Configuration Cluster Attributes ***/
  48. /**********************************************/
  49. // Shade information attributes set
  50. #define ATTRID_CLOSURES_PHYSICAL_CLOSED_LIMIT 0x0000
  51. #define ATTRID_CLOSURES_MOTOR_STEP_SIZE 0x0001
  52. #define ATTRID_CLOSURES_STATUS 0x0002
  53. /*** Status attribute bit values ***/
  54. #define CLOSURES_STATUS_SHADE_IS_OPERATIONAL 0x01
  55. #define CLOSURES_STATUS_SHADE_IS_ADJUSTING 0x02
  56. #define CLOSURES_STATUS_SHADE_DIRECTION 0x04
  57. #define CLOSURES_STATUS_SHADE_MOTOR_FORWARD_DIRECTION 0x08
  58. // Shade settings attributes set
  59. #define ATTRID_CLOSURES_CLOSED_LIMIT 0x0010
  60. #define ATTRID_CLOSURES_MODE 0x0012
  61. /*** Mode attribute values ***/
  62. #define CLOSURES_MODE_NORMAL_MODE 0x00
  63. #define CLOSURES_MODE_CONFIGURE_MODE 0x01
  64. // cluster has no specific commands
  65. /**********************************************/
  66. /*** Logical Cluster ID - for mapping only ***/
  67. /*** These are not to be used over-the-air ***/
  68. /**********************************************/
  69. #define ZCL_CLOSURES_LOGICAL_CLUSTER_ID_SHADE_CONFIG 0x0010
  70. /************************************/
  71. /*** Door Lock Cluster Attributes ***/
  72. /************************************/
  73. #define ATTRID_CLOSURES_LOCK_STATE 0x0000
  74. #define ATTRID_CLOSURES_LOCK_TYPE 0x0001
  75. #define ATTRID_CLOSURES_ACTUATOR_ENABLED 0x0002
  76. #define ATTRID_CLOSURES_DOOR_STATE 0x0003
  77. #define ATTRID_CLOSURES_NUM_OF_DOOR_OPEN_EVENTS 0x0004
  78. #define ATTRID_CLOSURES_NUM_OF_DOOR_CLOSED_EVENTS 0x0005
  79. #define ATTRID_CLOSURES_OPEN_PERIOD 0x0006
  80. /*** Lock State Attribute types ***/
  81. #define CLOSURES_LOCK_STATE_NOT_FULLY_LOCKED 0x00
  82. #define CLOSURES_LOCK_STATE_LOCKED 0x01
  83. #define CLOSURES_LOCK_STATE_UNLOCKED 0x02
  84. /*** Lock Type Attribute types ***/
  85. #define CLOSURES_LOCK_TYPE_DEADBOLT 0x00
  86. #define CLOSURES_LOCK_TYPE_MAGNETIC 0x01
  87. #define CLOSURES_LOCK_TYPE_OTHER 0x02
  88. /*** Door State Attribute types ***/
  89. #define CLOSURES_DOOR_STATE_OPEN 0x00
  90. #define CLOSURES_DOOR_STATE_CLOSED 0x01
  91. #define CLOSURES_DOOR_STATE_ERROR_JAMMED 0x02
  92. #define CLOSURES_DOOR_STATE_ERROR_FORCED_OPEN 0x03
  93. #define CLOSURES_DOOR_STATE_ERROR_UNSPECIFIED 0x04
  94. /**********************************/
  95. /*** Door Lock Cluster Commands ***/
  96. /**********************************/
  97. #define COMMAND_CLOSURES_LOCK_DOOR 0x00
  98. #define COMMAND_CLOSURES_UNLOCK_DOOR 0x01
  99. #define COMMAND_CLOSURES_LOCK_DOOR_RESPONSE 0x00
  100. #define COMMAND_CLOSURES_UNLOCK_DOOR_RESPONSE 0x01
  101. #define DOORLOCK_RES_PAYLOAD_LEN 0x01
  102. /**********************************************/
  103. /*** Window Covering Cluster Attribute Sets ***/
  104. /**********************************************/
  105. #define ATTRSET_WINDOW_COVERING_INFO 0x0000
  106. #define ATTRSET_WINDOW_COVERING_SETTINGS 0x0010
  107. /******************************************/
  108. /*** Window Covering Cluster Attributes ***/
  109. /******************************************/
  110. //Window Covering Information
  111. #define ATTRID_CLOSURES_WINDOW_COVERING_TYPE ( ATTRSET_WINDOW_COVERING_INFO + 0x0000 )
  112. #define ATTRID_CLOSURES_PHYSICAL_CLOSE_LIMIT_LIFT_CM ( ATTRSET_WINDOW_COVERING_INFO + 0x0001 )
  113. #define ATTRID_CLOSURES_PHYSICAL_CLOSE_LIMIT_TILT_DDEGREE ( ATTRSET_WINDOW_COVERING_INFO + 0x0002 )
  114. #define ATTRID_CLOSURES_CURRENT_POSITION_LIFT_CM ( ATTRSET_WINDOW_COVERING_INFO + 0x0003 )
  115. #define ATTRID_CLOSURES_CURRENT_POSITION_TILT_DDEGREE ( ATTRSET_WINDOW_COVERING_INFO + 0x0004 )
  116. #define ATTRID_CLOSURES_NUM_OF_ACTUATION_LIFT ( ATTRSET_WINDOW_COVERING_INFO + 0x0005 )
  117. #define ATTRID_CLOSURES_NUM_OF_ACTUATION_TILT ( ATTRSET_WINDOW_COVERING_INFO + 0x0006 )
  118. #define ATTRID_CLOSURES_CONFIG_STATUS ( ATTRSET_WINDOW_COVERING_INFO + 0x0007 )
  119. #define ATTRID_CLOSURES_CURRENT_POSITION_LIFT_PERCENTAGE ( ATTRSET_WINDOW_COVERING_INFO + 0x0008 )
  120. #define ATTRID_CLOSURES_CURRENT_POSITION_TILT_PERCENTAGE ( ATTRSET_WINDOW_COVERING_INFO + 0x0009 )
  121. //Window Covering Setting
  122. #define ATTRID_CLOSURES_INSTALLED_OPEN_LIMIT_LIFT_CM ( ATTRSET_WINDOW_COVERING_SETTINGS + 0x0000 )
  123. #define ATTRID_CLOSURES_INSTALLED_CLOSED_LIMIT_LIFT_CM ( ATTRSET_WINDOW_COVERING_SETTINGS + 0x0001 )
  124. #define ATTRID_CLOSURES_INSTALLED_OPEN_LIMIT_TILT_DDEGREE ( ATTRSET_WINDOW_COVERING_SETTINGS + 0x0002 )
  125. #define ATTRID_CLOSURES_INSTALLED_CLOSED_LIMIT_TILT_DDEGREE ( ATTRSET_WINDOW_COVERING_SETTINGS + 0x0003 )
  126. #define ATTRID_CLOSURES_VELOCITY_LIFT ( ATTRSET_WINDOW_COVERING_SETTINGS + 0x0004 )
  127. #define ATTRID_CLOSURES_ACCELERATION_TIME_LIFT ( ATTRSET_WINDOW_COVERING_SETTINGS + 0x0005 )
  128. #define ATTRID_CLOSURES_DECELERATION_TIME_LIFT ( ATTRSET_WINDOW_COVERING_SETTINGS + 0x0006 )
  129. #define ATTRID_CLOSURES_WINDOW_COVERING_MODE ( ATTRSET_WINDOW_COVERING_SETTINGS + 0x0007 )
  130. #define ATTRID_CLOSURES_INTERMEDIATE_SETPOINTS_LIFT ( ATTRSET_WINDOW_COVERING_SETTINGS + 0x0008 )
  131. #define ATTRID_CLOSURES_INTERMEDIATE_SETPOINTS_TILT ( ATTRSET_WINDOW_COVERING_SETTINGS + 0x0009 )
  132. /*** Window Covering Type Attribute types ***/
  133. #define CLOSURES_WINDOW_COVERING_TYPE_ROLLERSHADE 0x00
  134. #define CLOSURES_WINDOW_COVERING_TYPE_ROLLERSHADE_2_MOTOR 0x01
  135. #define CLOSURES_WINDOW_COVERING_TYPE_ROLLERSHADE_EXTERIOR 0x02
  136. #define CLOSURES_WINDOW_COVERING_TYPE_ROLLERSHADE_EXTERIOR_2_MOTOR 0x03
  137. #define CLOSURES_WINDOW_COVERING_TYPE_DRAPERY 0x04
  138. #define CLOSURES_WINDOW_COVERING_TYPE_AWNING 0x05
  139. #define CLOSURES_WINDOW_COVERING_TYPE_SHUTTER 0x06
  140. #define CLOSURES_WINDOW_COVERING_TYPE_TILT_BLIND_TILT_ONLY 0x07
  141. #define CLOSURES_WINDOW_COVERING_TYPE_TILT_BLIND_LIFT_AND_TILT 0x08
  142. #define CLOSURES_WINDOW_COVERING_TYPE_PROJECTOR_SCREEN 0x09
  143. /****************************************/
  144. /*** Window Covering Cluster Commands ***/
  145. /****************************************/
  146. #define COMMAND_CLOSURES_UP_OPEN ( 0x00 )
  147. #define COMMAND_CLOSURES_DOWN_CLOSE ( 0x01 )
  148. #define COMMAND_CLOSURES_STOP ( 0x02 )
  149. #define COMMAND_CLOSURES_GO_TO_LIFT_SETPOINT ( 0x03 )
  150. #define COMMAND_CLOSURES_GO_TO_LIFT_VALUE ( 0x04 )
  151. #define COMMAND_CLOSURES_GO_TO_LIFT_PERCENTAGE ( 0x05 )
  152. #define COMMAND_CLOSURES_GO_TO_TILT_SETPOINT ( 0x06 )
  153. #define COMMAND_CLOSURES_GO_TO_TILT_VALUE ( 0x07 )
  154. #define COMMAND_CLOSURES_GO_TO_TILT_PERCENTAGE ( 0x08 )
  155. #define COMMAND_CLOSURES_PROGRAM_SETPOINT ( 0x09 )
  156. #define ZCL_WC_GOTOSETPOINTREQ_PAYLOADLEN ( 1 )
  157. #define ZCL_WC_GOTOVALUEREQ_PAYLOADLEN ( 2 )
  158. #define ZCL_WC_GOTOPERCENTAGEREQ_PAYLOADLEN ( 1 )
  159. #define ZCL_WC_PROGRAMSETPOINTREQ_VER1_PAYLOADLEN ( 4 )
  160. #define ZCL_WC_PROGRAMSETPOINTREQ_VER2_PAYLOADLEN ( 1 )
  161. /*********************************************************************
  162. * TYPEDEFS
  163. */
  164. /*** Window Covering Cluster - Bits in Config/Status Attribute ***/
  165. typedef struct
  166. {
  167. uint8 Operational : 1; // Window Covering is operational or not
  168. uint8 Online : 1; // Window Covering is enabled for transmitting over the Zigbee network or not
  169. uint8 CommandsReversed : 1; // Identifies the direction of rotation for the Window Covering
  170. uint8 LiftControl : 1; // Identifies, lift control supports open loop or closed loop
  171. uint8 TiltControl : 1; // Identifies, tilt control supports open loop or closed loop
  172. uint8 LiftEncoderControlled : 1; // Identifies, lift control uses Timer or Encoder
  173. uint8 TiltEncoderControlled : 1; // Identifies, tilt control uses Timer or Encoder
  174. uint8 Reserved : 1;
  175. }zclClosuresWcInfoConfigStatus_t;
  176. /*** Window Covering Cluster - Bits in Mode Attribute ***/
  177. typedef struct
  178. {
  179. uint8 MotorReverseDirection : 1; // Defines the direction of the motor rotation
  180. uint8 RunInCalibrationMode : 1; // Defines Window Covering is in calibration mode or in normal mode
  181. uint8 RunInMaintenanceMode : 1; // Defines motor is running in maintenance mode or in normal mode
  182. uint8 LEDFeedback : 1; // Enables or Disables feedback LED
  183. uint8 Reserved : 4;
  184. }zclClosuresWcSetMode_t;
  185. /*** Window Covering Cluster - Setpoint type ***/
  186. typedef enum
  187. {
  188. lift = 0,
  189. tilt = 1,
  190. }setpointType_t;
  191. /*** Window Covering Cluster - Setpoint version ***/
  192. typedef enum
  193. {
  194. programSetpointVersion1 = 1,
  195. programSetpointVersion2,
  196. }setpointVersion_t;
  197. /*** Window Covering - Program Setpoint Command payload struct ***/
  198. typedef struct
  199. {
  200. setpointVersion_t version; // Version of the Program Setpoint command
  201. uint8 setpointIndex; // Index of the Setpoint
  202. uint16 setpointValue; // Value of the Setpoint
  203. setpointType_t setpointType; // Type of the Setpoint; it should be either lift or tilt
  204. }programSetpointPayload_t;
  205. /*** Window Covering Command - General struct ***/
  206. typedef struct
  207. {
  208. afAddrType_t *srcAddr; // requestor's address
  209. uint8 cmdID; // Command id
  210. uint8 seqNum; // Sequence number received with the message
  211. union // Payload
  212. {
  213. uint8 indexOfLiftSetpoint;
  214. uint8 percentageLiftValue;
  215. uint16 liftValue;
  216. uint8 indexOfTiltSetpoint;
  217. uint8 percentageTiltValue;
  218. uint16 TiltValue;
  219. programSetpointPayload_t programSetpoint;
  220. }un;
  221. }zclWindowCovering_t;
  222. //This callback is called to process an incoming Door Lock/Unlock command
  223. // cmd - Which is the received command, either Door Lock or Door Unlock command
  224. // seqNum - Transaction Sequence Number
  225. // srcAddr - requestor's address
  226. typedef void (*zclClosures_DoorLock_t) ( uint8 cmd, afAddrType_t *srcAddr, uint8 seqNum );
  227. //This callback is called to process an incoming Door Lock/Unlock response
  228. // cmd - Which is the received command, either Door Lock or Door Unlock response
  229. // seqNum - Transaction Sequence Number
  230. // srcAddr - requestor's address
  231. typedef void (*zclClosures_DoorLockRes_t) ( uint8 cmd, afAddrType_t *srcAddr, uint8 seqNum );
  232. //This callback is called to process an incoming Window Covering cluster basic commands
  233. typedef void (*zclClosures_WindowCoveringSimple_t) ( void );
  234. //This callback is called to process an incoming Window Covering cluster goto percentage commands
  235. // percentage - value to process
  236. // return TRUE on success
  237. typedef bool (*zclClosures_WindowCoveringGotoPercentage_t) ( uint8 percentage );
  238. //This callback is called to process an incoming Window Covering cluster goto value commands
  239. // value - value to process
  240. // return TRUE on success
  241. typedef bool (*zclClosures_WindowCoveringGotoValue_t) ( uint16 value );
  242. //This callback is called to process an incoming Window Covering cluster goto setpoint commands
  243. // index - value to process
  244. // return ZCL status: ZCL_STATUS_SUCCESS, ZCL_STATUS_INVALID_VALUE or ZCL_STATUS_NOT_FOUND.
  245. typedef uint8 (*zclClosures_WindowCoveringGotoSetpoint_t) ( uint8 index );
  246. //This callback is called to process an incoming Window Covering cluster program setpoint commands
  247. // setpoint - values to process, including version, type, index and value
  248. // return TRUE on success, FALSE in case of insufficient space
  249. typedef bool (*zclClosures_WindowCoveringProgramSetpoint_t) ( programSetpointPayload_t *setpoint );
  250. // Register Callbacks table entry - enter function pointers for callbacks that
  251. // the application would like to receive
  252. typedef struct
  253. {
  254. zclClosures_DoorLock_t pfnDoorLock; // Door Lock cluster commands
  255. zclClosures_DoorLockRes_t pfnDoorLockRes; // Door Lock cluster response
  256. zclClosures_WindowCoveringSimple_t pfnWindowCoveringUpOpen;
  257. zclClosures_WindowCoveringSimple_t pfnWindowCoveringDownClose;
  258. zclClosures_WindowCoveringSimple_t pfnWindowCoveringStop;
  259. zclClosures_WindowCoveringGotoSetpoint_t pfnWindowCoveringGotoLiftSetpoint;
  260. zclClosures_WindowCoveringGotoValue_t pfnWindowCoveringGotoLiftValue;
  261. zclClosures_WindowCoveringGotoPercentage_t pfnWindowCoveringGotoLiftPercentage;
  262. zclClosures_WindowCoveringGotoSetpoint_t pfnWindowCoveringGotoTiltSetpoint;
  263. zclClosures_WindowCoveringGotoValue_t pfnWindowCoveringGotoTiltValue;
  264. zclClosures_WindowCoveringGotoPercentage_t pfnWindowCoveringGotoTiltPercentage;
  265. zclClosures_WindowCoveringProgramSetpoint_t pfnWindowCoveringProgramSetpoint;
  266. } zclClosures_AppCallbacks_t;
  267. /*********************************************************************
  268. * VARIABLES
  269. */
  270. /*********************************************************************
  271. * FUNCTIONS
  272. */
  273. /*
  274. * Register for callbacks from this cluster library
  275. */
  276. extern ZStatus_t zclClosures_RegisterCmdCallbacks( uint8 endpoint, zclClosures_AppCallbacks_t *callbacks );
  277. extern ZStatus_t zclClosures_SendDoorLockRequest( uint8 srcEP, afAddrType_t *dstAddr,
  278. uint8 cmd, uint16 clusterID,
  279. uint8 disableDefaultRsp, uint8 seqNum );
  280. extern ZStatus_t zclClosures_SendDoorLockResponse( uint8 srcEP, afAddrType_t *dstAddr,
  281. uint8 cmd, uint16 clusterID,
  282. uint8 disableDefaultRsp, uint8 seqNum, uint8 status );
  283. extern ZStatus_t zclClosures_WCSimpleRequest( uint8 srcEP, afAddrType_t *dstAddr,
  284. uint8 cmd, uint8 disableDefaultRsp, uint8 seqNum );
  285. extern ZStatus_t zclClosures_WCSendGoToSetpointRequest( uint8 srcEP, afAddrType_t *dstAddr,
  286. uint8 cmd, uint8 disableDefaultRsp,
  287. uint8 seqNum, uint8 SetpointIndex );
  288. extern ZStatus_t zclClosures_WCSendGoToValueRequest( uint8 srcEP, afAddrType_t *dstAddr,
  289. uint8 cmd, uint8 disableDefaultRsp,
  290. uint8 seqNum, uint16 Value );
  291. extern ZStatus_t zclClosures_WCSendGoToPercentageRequest( uint8 srcEP, afAddrType_t *dstAddr,
  292. uint8 cmd, uint8 disableDefaultRsp,
  293. uint8 seqNum, uint8 percentageValue );
  294. extern ZStatus_t zclClosures_WCSendProgramSetpointRequest( uint8 srcEP, afAddrType_t *dstAddr,
  295. uint8 cmd, uint8 disableDefaultRsp,
  296. uint8 seqNum, programSetpointPayload_t *programSetpoint );
  297. /*********************************************************************
  298. * FUNCTION MACROS
  299. */
  300. /*
  301. * Send a Door Lock Command
  302. * Use like:
  303. * ZStatus_t zclClosures_SendDoorLock( uint8 srcEP, afAddrType_t *dstAddr, uint8 disableDefaultRsp, uint8 seqNum )
  304. */
  305. #define zclClosures_SendDoorLock(a, b, c, d) zclClosures_SendDoorLockRequest((a), (b), COMMAND_CLOSURES_LOCK_DOOR, ZCL_CLUSTER_ID_CLOSURES_DOOR_LOCK, (c), (d))
  306. /*
  307. * Send a Door Lock Response
  308. * Use like:
  309. * ZStatus_t zclClosures_SendDoorLockRes( uint8 srcEP, afAddrType_t *dstAddr, uint8 disableDefaultRsp, uint8 seqNum, uint8 status )
  310. */
  311. #define zclClosures_SendDoorLockRsp(a, b, c, d, e) zclClosures_SendDoorLockResponse( (a), (b), COMMAND_CLOSURES_LOCK_DOOR_RESPONSE, ZCL_CLUSTER_ID_CLOSURES_DOOR_LOCK, (c), (d), (e) )
  312. /*
  313. * Send a Door Unlock Command
  314. * Use like:
  315. * ZStatus_t zclClosures_SendDoorUnlock( uint8 srcEP, afAddrType_t *dstAddr, uint8 disableDefaultRsp, uint8 seqNum )
  316. */
  317. #define zclClosures_SendDoorUnlock(a, b, c, d) zclClosures_SendDoorLockRequest((a), (b), COMMAND_CLOSURES_UNLOCK_DOOR, ZCL_CLUSTER_ID_CLOSURES_DOOR_LOCK, (c), (d))
  318. /*
  319. * Send a Door Lock Response
  320. * Use like:
  321. * ZStatus_t zclClosures_SendDoorUnlockRes( uint8 srcEP, afAddrType_t *dstAddr, uint8 disableDefaultRsp, uint8 seqNum, uint8 status )
  322. */
  323. #define zclClosures_SendDoorUnlockRsp(a, b, c, d, e) zclClosures_SendDoorLockResponse( (a), (b), COMMAND_CLOSURES_UNLOCK_DOOR_RESPONSE, ZCL_CLUSTER_ID_CLOSURES_DOOR_LOCK, (c), (d), (e) )
  324. /*
  325. * Send a Up/Open Request Command
  326. * Use like:
  327. * ZStatus_t zclClosures_SendUpOpen( uint8 srcEP, afAddrType_t *dstAddr, uint8 disableDefaultRsp, uint8 seqNum )
  328. */
  329. #define zclClosures_SendUpOpen(a, b, c, d) zclClosures_WCSimpleRequest( (a), (b), COMMAND_CLOSURES_UP_OPEN, (c), (d) )
  330. /*
  331. * Send a Down/Close Request Command
  332. * Use like:
  333. * ZStatus_t zclClosures_SendDownClose( uint8 srcEP, afAddrType_t *dstAddr, uint8 disableDefaultRsp, uint8 seqNum )
  334. */
  335. #define zclClosures_SendDownClose(a, b, c, d) zclClosures_WCSimpleRequest( (a), (b), COMMAND_CLOSURES_DOWN_CLOSE, (c), (d) )
  336. /*
  337. * Send a Stop Request Command
  338. * Use like:
  339. * ZStatus_t zclClosures_SendStop( uint8 srcEP, afAddrType_t *dstAddr, uint8 disableDefaultRsp, uint8 seqNum )
  340. */
  341. #define zclClosures_SendStop(a, b, c, d) zclClosures_WCSimpleRequest( (a), (b), COMMAND_CLOSURES_STOP, (c), (d) )
  342. /*
  343. * Send a GoToLiftSetpoint Request Command
  344. * Use like:
  345. * ZStatus_t zclClosures_SendGoToLiftSetpoint( uint8 srcEP, afAddrType_t *dstAddr, uint8 disableDefaultRsp, uint8 seqNum, uint8 liftSetpoint )
  346. */
  347. #define zclClosures_SendGoToLiftSetpoint(a, b, c, d, e) zclClosures_WCSendGoToSetpointRequest( (a), (b), COMMAND_CLOSURES_GO_TO_LIFT_SETPOINT, (c), (d), (e) )
  348. /*
  349. * Send a GoToLiftValue Request Command
  350. * Use like:
  351. * ZStatus_t zclClosures_SendGoToLiftValue( uint8 srcEP, afAddrType_t *dstAddr, uint8 disableDefaultRsp, uint8 seqNum, uint16 liftValue )
  352. */
  353. #define zclClosures_SendGoToLiftValue(a, b, c, d, e) zclClosures_WCSendGoToValueRequest((a), (b), COMMAND_CLOSURES_GO_TO_LIFT_VALUE, (c), (d), (e))
  354. /*
  355. * Send a GoToLiftPercentage Request Command
  356. * Use like:
  357. * ZStatus_t zclClosures_SendGoToLiftPercentage( uint8 srcEP, afAddrType_t *dstAddr, uint8 disableDefaultRsp, uint8 seqNum, uint8 percentageLiftValue )
  358. */
  359. #define zclClosures_SendGoToLiftPercentage(a, b, c, d, e) zclClosures_WCSendGoToLiftPercentageRequest((a), (b), COMMAND_CLOSURES_GO_TO_LIFT_PERCENTAGE, (c), (d), (e))
  360. /*
  361. * Send a GoToTiltSetpoint Request Command
  362. * Use like:
  363. * ZStatus_t zclClosures_SendGoToTiltSetpoint( uint8 srcEP, afAddrType_t *dstAddr, uint8 disableDefaultRsp, uint8 seqNum, uint8 tiltSetpoint)
  364. */
  365. #define zclClosures_SendGoToTiltSetpoint(a, b, c, d, e) zclClosures_WCSendGoToSetpointRequest( (a), (b), COMMAND_CLOSURES_GO_TO_TILT_SETPOINT, (c), (d), (e) )
  366. /*
  367. * Send a GoToTiltValue Request Command
  368. * Use like:
  369. * ZStatus_t zclClosures_SendGoToTiltValue( uint8 srcEP, afAddrType_t *dstAddr, uint8 disableDefaultRsp, uint8 seqNum, uint16 tiltValue)
  370. */
  371. #define zclClosures_SendGoToTiltValue(a, b, c, d, e) zclClosures_WCSendGoToValueRequest((a), (b), COMMAND_CLOSURES_GO_TO_TILT_VALUE, (c), (d), (e))
  372. /*
  373. * Send a GoToTiltPercentage Request Command
  374. * Use like:
  375. * ZStatus_t zclClosures_SendGoToTiltPercentage( uint8 srcEP, afAddrType_t *dstAddr, uint8 disableDefaultRsp, uint8 seqNum, uint8 percentageTiltValue)
  376. */
  377. #define zclClosures_SendGoToTiltPercentage(a, b, c, d, e) zclClosures_WCSendGoToTiltPercentageRequest((a), (b), COMMAND_CLOSURES_GO_TO_TILT_PERCENTAGE, (c), (d), (e))
  378. /*
  379. * Send a GoToTiltPercentage Request Command
  380. * Use like:
  381. * ZStatus_t zclClosures_SendProgramSetpoint( uint8 srcEP, afAddrType_t *dstAddr, uint8 disableDefaultRsp, uint8 seqNum, programSetpointPayload_t *programSetpoint )
  382. */
  383. #define zclClosures_SendProgramSetpoint(a, b, c, d, e) zclClosures_WCSendProgramSetpointRequest((a), (b), COMMAND_CLOSURES_PROGRAM_SETPOINT, (c), (d), (e))
  384. #ifdef __cplusplus
  385. }
  386. #endif
  387. #endif /* ZCL_CLOSURES_H */