15#ifndef ZAF_APPLICATIONUTILITIES_ZAF_TYPES_H_
16#define ZAF_APPLICATIONUTILITIES_ZAF_TYPES_H_
19#include <ZW_classcmd.h>
86 uint8_t multichanCmdEncap[4];
207 ZW_APPLICATION_TX_BUFFER *,
209 ZW_APPLICATION_TX_BUFFER *,
255typedef void(*
basic_get_mapper_t)(uint8_t endpoint, uint8_t * p_current_value, uint8_t * p_target_value, uint8_t * p_duration);
351#define HANDLER_V2_SECTION "__TEXT,__cc_handlers_v3"
352extern CC_handler_map_v3_t __start__cc_handlers_v3 __asm(
"section$start$__TEXT$__cc_handlers_v3");
353extern CC_handler_map_v3_t __stop__cc_handlers_v3 __asm(
"section$end$__TEXT$__cc_handlers_v3");
355#define HANDLER_SECTION "zw_cc_handlers_v3"
360#define cc_handlers_start __start_zw_cc_handlers_v3
367#define cc_handlers_stop __stop_zw_cc_handlers_v3
402#define REGISTER_CC_V5(cc,version,handler,basic_set_mapper,basic_get_mapper, lifeline_report_cb, flags, init_cb, reset_cb) \
403 static const CC_handler_map_latest_t thisHandler##cc __attribute__((aligned(4), __used__, __section__( HANDLER_SECTION ))) = {3,cc,version,(cc_handler_t)handler,basic_set_mapper,basic_get_mapper,lifeline_report_cb,flags,init_cb,reset_cb}; \
439#define REGISTER_CC_V4(cc,version,handler,basic_set_mapper,basic_get_mapper, lifeline_report_cb, flags, init_cb, reset_cb) \
440 static const CC_handler_map_latest_t thisHandler##cc __attribute__((aligned(4), __used__, __section__( HANDLER_SECTION ))) = {2,cc,version,(cc_handler_t)handler,basic_set_mapper,basic_get_mapper,lifeline_report_cb,flags,init_cb,reset_cb}; \
473#define REGISTER_CC_V3(cc,version,handler,basic_set_mapper,basic_get_mapper, lifeline_report_cb, flags) \
474 static const CC_handler_map_latest_t thisHandler##cc __attribute__((aligned(4), __used__, __section__( HANDLER_SECTION ))) = {2,cc,version,(cc_handler_t)handler,basic_set_mapper,basic_get_mapper,lifeline_report_cb,flags,NULL,NULL}; \
482#define REGISTER_CC_V2(cc,version,handler) \
483 static const CC_handler_map_latest_t thisHandler##cc __attribute__((aligned(4), __used__, __section__( HANDLER_SECTION ))) = {2,cc,version,(cc_handler_t)handler,NULL,NULL,NULL,0,NULL,NULL}; \
491#define REGISTER_CC(cc,version,handler) \
492 static const CC_handler_map_latest_t thisHandler##cc __attribute__((aligned(4), __used__, __section__( HANDLER_SECTION ))) = {1,cc,version,(cc_handler_t)handler,NULL,NULL,NULL,0,NULL,NULL}; \
517#define ZAF_CC_CONFIG_SECTION "__TEXT,__zaf_cc_config"
519#define ZAF_CC_CONFIG_SECTION "zw_zaf_cc_config"
529#define ZAF_CC_REGISTER_CONFIG(cc, config, index) \
530 static const zaf_cc_config_entry_latest_t cc_config##index##cc __attribute__((aligned(4), __used__, __section__(ZAF_CC_CONFIG_SECTION))) = { cc, (zaf_cc_config_t *) config }; \
531 void * cc_register_config##index##cc
void(* ZW_TX_Multi_Callback_t)(uint8_t txStatus)
Definition ZAF_types.h:343
void(* ZAF_TX_Callback_t)(transmission_result_t *pTxResult)
Definition ZAF_types.h:330
struct _MULTICHAN_SOURCE_NODE_ID_ MULTICHAN_SOURCE_NODE_ID
TRANSMISSION_RESULT_FINISH_STATUS
Definition ZAF_types.h:165
struct _RECEIVE_OPTIONS_TYPE_EX_ RECEIVE_OPTIONS_TYPE_EX
received_frame_status_t(* cc_handler_v1_t)(RECEIVE_OPTIONS_TYPE_EX *, ZW_APPLICATION_TX_BUFFER *, uint8_t)
Defines a type for version 1 of the command class handler.
Definition ZAF_types.h:200
cc_group_t CMD_CLASS_GRP
Definition ZAF_types.h:129
ccc_pair_t cc_group_t
Definition ZAF_types.h:128
received_frame_status_t(* cc_handler_v3_t)(cc_handler_input_t *, cc_handler_output_t *)
Defines a type for version 3 of the command class handler.
Definition ZAF_types.h:233
received_frame_status_t(* cc_handler_v2_t)(RECEIVE_OPTIONS_TYPE_EX *, ZW_APPLICATION_TX_BUFFER *, uint8_t, ZW_APPLICATION_TX_BUFFER *, uint8_t *)
Defines a type for version 2 of the command class handler.
Definition ZAF_types.h:205
void(* basic_set_mapper_t)(ZW_APPLICATION_TX_BUFFER *p_frame)
Definition ZAF_types.h:244
received_frame_status_t
Definition ZAF_types.h:107
void(* ZW_TX_Callback_t)(uint8_t txStatus, TX_STATUS_TYPE *extendedTxStatus)
Definition ZAF_types.h:337
zaf_job_status_t job_status_t
Definition ZAF_types.h:158
void(* ZW_Void_Callback_t)(void)
Definition ZAF_types.h:348
zaf_cc_config_entry_v1_t zaf_cc_config_entry_latest_t
Definition ZAF_types.h:514
zaf_job_status_t
Definition ZAF_types.h:149
agi_profile_t AGI_PROFILE
Definition ZAF_types.h:143
e_cmd_handler_return_code_t
Definition ZAF_types.h:95
const CC_handler_map_latest_t __start_zw_cc_handlers_v3
CC_handler_map_v4_t CC_handler_map_latest_t
Definition ZAF_types.h:328
void(* cc_reset_function_t)(void)
Definition ZAF_types.h:258
void(* cc_handler_t)(void)
Defines a type for the generic command class handler.
Definition ZAF_types.h:195
transmission_result_t TRANSMISSION_RESULT
Definition ZAF_types.h:190
const CC_handler_map_latest_t __stop_zw_cc_handlers_v3
struct _MULTICHAN_DEST_NODE_ID_ MULTICHAN_DEST_NODE_ID
job_status_t JOB_STATUS
Definition ZAF_types.h:159
void(* basic_get_mapper_t)(uint8_t endpoint, uint8_t *p_current_value, uint8_t *p_target_value, uint8_t *p_duration)
Definition ZAF_types.h:255
struct _cc_handler_output_t cc_handler_output_t
Defines the output parameters of a command class handler.
uint8_t(* lifeline_report_get_t)(cc_group_t *p_cc_pair)
Definition ZAF_types.h:264
struct _cc_handler_input_t cc_handler_input_t
Defines the input parameters of a command class handler.
void(* cc_init_function_t)(void)
Definition ZAF_types.h:257
@ TRANSMISSION_RESULT_UNKNOWN
Definition ZAF_types.h:168
@ TRANSMISSION_RESULT_NOT_FINISHED
Definition ZAF_types.h:166
@ TRANSMISSION_RESULT_FINISHED
Definition ZAF_types.h:167
@ RECEIVED_FRAME_STATUS_CC_NOT_FOUND
CC handler was not found in CC handler map.
Definition ZAF_types.h:112
@ RECEIVED_FRAME_STATUS_NO_SUPPORT
Frame not supported.
Definition ZAF_types.h:108
@ RECEIVED_FRAME_STATUS_CANCEL
Don't care about status. CC or App will send the report.
Definition ZAF_types.h:111
@ RECEIVED_FRAME_STATUS_FAIL
Could not handle incoming frame.
Definition ZAF_types.h:110
@ RECEIVED_FRAME_STATUS_WORKING
Frame received successfully and timed change started.
Definition ZAF_types.h:109
@ RECEIVED_FRAME_STATUS_SUCCESS
Frame received successfully.
Definition ZAF_types.h:113
@ JOB_STATUS_SUCCESS
Definition ZAF_types.h:150
@ JOB_STATUS_NO_DESTINATIONS
Definition ZAF_types.h:152
@ JOB_STATUS_BUSY
Definition ZAF_types.h:151
@ E_CMD_HANDLER_RETURN_CODE_HANDLED
Accepted and executed by the command handler. Command class returns SUCCESS.
Definition ZAF_types.h:97
@ E_CMD_HANDLER_RETURN_CODE_NOT_SUPPORTED
Command handler does not support this command. Command class returns NO_SUPPORT.
Definition ZAF_types.h:99
@ E_CMD_HANDLER_RETURN_CODE_NO_CHANGE
Accepted but device was already in final state, so no change was made. Command class returns SUCCESS.
Definition ZAF_types.h:100
@ E_CMD_HANDLER_RETURN_CODE_WORKING
Accepted but is not fully executed. Command class returns WORKING.
Definition ZAF_types.h:98
@ E_CMD_HANDLER_RETURN_CODE_FAIL
Not accepted or accepted but failed to execute. Command class returns FAIL.
Definition ZAF_types.h:96
enum SECURITY_KEY security_key_t
uint16_t node_id_t
Node ID type.
Definition zpal_radio.h:230
Definition ZAF_types.h:270
cc_handler_t pHandler
Definition ZAF_types.h:273
uint16_t version
Definition ZAF_types.h:272
uint16_t CC
Definition ZAF_types.h:271
Definition ZAF_types.h:281
uint16_t version
Definition ZAF_types.h:284
uint16_t CC
Definition ZAF_types.h:283
cc_handler_t handler
Definition ZAF_types.h:285
uint32_t handler_api_version
Definition ZAF_types.h:282
Definition ZAF_types.h:293
uint16_t CC
Definition ZAF_types.h:295
cc_handler_t handler
Definition ZAF_types.h:297
basic_set_mapper_t basic_set_mapper
Definition ZAF_types.h:298
uint32_t handler_api_version
Definition ZAF_types.h:294
basic_get_mapper_t basic_get_mapper
Definition ZAF_types.h:299
lifeline_report_get_t lifeline_report_get
Definition ZAF_types.h:300
uint32_t flags
Definition ZAF_types.h:301
uint16_t version
Definition ZAF_types.h:296
Definition ZAF_types.h:309
uint16_t CC
Definition ZAF_types.h:311
lifeline_report_get_t lifeline_report_get
Definition ZAF_types.h:316
uint32_t flags
Definition ZAF_types.h:317
basic_set_mapper_t basic_set_mapper
Definition ZAF_types.h:314
cc_reset_function_t reset
Definition ZAF_types.h:319
uint8_t handler_api_version
Definition ZAF_types.h:310
basic_get_mapper_t basic_get_mapper
Definition ZAF_types.h:315
uint8_t version
Definition ZAF_types.h:312
cc_handler_t handler
Definition ZAF_types.h:313
cc_init_function_t init
Definition ZAF_types.h:318
Definition ZAF_types.h:57
uint8_t BitAddress
Definition ZAF_types.h:64
uint8_t nodeId
The ID of the destination node.
Definition ZAF_types.h:58
uint8_t endpoint
Definition ZAF_types.h:61
Definition ZAF_types.h:85
ZW_APPLICATION_TX_BUFFER appTxBuf
Definition ZAF_types.h:88
ZW_SUPERVISION_GET_FRAME supervisionGet
Definition ZAF_types.h:87
Definition ZAF_types.h:40
node_id_t nodeId
The ID of the destination node.
Definition ZAF_types.h:41
uint8_t BitAddress
Definition ZAF_types.h:47
uint8_t endpoint
Definition ZAF_types.h:44
Definition ZAF_types.h:30
node_id_t nodeId
The ID of the source node.
Definition ZAF_types.h:31
uint8_t res
Definition ZAF_types.h:36
uint8_t endpoint
Definition ZAF_types.h:34
Definition ZAF_types.h:71
uint8_t bSupervisionActive
true if supervision is active
Definition ZAF_types.h:76
MULTICHAN_SOURCE_NODE_ID sourceNode
Definition ZAF_types.h:74
uint8_t rxStatus
Frame header info.
Definition ZAF_types.h:72
MULTICHAN_DEST_NODE_ID destNode
Definition ZAF_types.h:75
uint8_t statusUpdate
Is statusUpdate enabled for current session.
Definition ZAF_types.h:78
security_key_t securityKey
Definition ZAF_types.h:73
uint8_t sessionId
Current sessionId.
Definition ZAF_types.h:77
Definition ZW_transport_api.h:143
Defines the output parameters of a command class handler.
Definition ZAF_types.h:224
ZW_APPLICATION_TX_BUFFER * frame
Definition ZAF_types.h:225
uint8_t duration
Definition ZAF_types.h:227
uint8_t length
Definition ZAF_types.h:226
Definition ZAF_types.h:135
uint8_t profile_MS
Definition ZAF_types.h:136
uint8_t profile_LS
Definition ZAF_types.h:137
Definition ZAF_types.h:120
uint8_t cmdClass
Definition ZAF_types.h:121
uint8_t cmd
Definition ZAF_types.h:122
Definition ZAF_types.h:178
node_id_t nodeId
Definition ZAF_types.h:179
uint8_t status
Definition ZAF_types.h:180
TRANSMISSION_RESULT_FINISH_STATUS isFinished
Definition ZAF_types.h:184
Definition ZAF_types.h:503
uint16_t command_class
Definition ZAF_types.h:504
zaf_cc_config_t * p_cc_configuration
Definition ZAF_types.h:508
Definition ZAF_types.h:498
uint8_t endpoint
Definition ZAF_types.h:500
RECEIVE_OPTIONS_TYPE_EX rxOpt
Definition ZAF_types.h:499
Definition ZAF_types.h:533
uint8_t list_size
Definition ZAF_types.h:534
uint8_t * cc_list
Definition ZAF_types.h:535