Developing with ZBOSS
|
Macros | |
#define | ZB_HA_DECLARE_SIMPLE_SENSOR_CLUSTER_LIST( cluster_list_name, basic_attr_list, identify_attr_list, binary_input_attr_list) |
Declare cluster list for Simple Sensor device. More... | |
#define | ZB_HA_DECLARE_SIMPLE_SENSOR_EP(ep_name, ep_id, cluster_list) |
Declare endpoint for Simple Sensor device. More... | |
#define | ZB_HA_DECLARE_SIMPLE_SENSOR_CTX(device_ctx, ep_name) ZBOSS_DECLARE_DEVICE_CTX_1_EP(device_ctx, ep_name) |
Declare Simple Sensor device context. More... | |
Simple Sensor device has 3 clusters (see spec 7.4.13):
Simple Sensor device sample
Declaring clusters:
Registering device list:
Example of command handler:
The complete set of Simple Sensor device samples can be found in /application/HA_samples/simple_sensor
#define ZB_HA_DECLARE_SIMPLE_SENSOR_CLUSTER_LIST | ( | cluster_list_name, | |
basic_attr_list, | |||
identify_attr_list, | |||
binary_input_attr_list | |||
) |
Declare cluster list for Simple Sensor device.
cluster_list_name | - cluster list variable name |
basic_attr_list | - attribute list for Basic cluster |
identify_attr_list | - attribute list for Identify cluster |
binary_input_attr_list | - attribute list for Binary Input cluster |
#define ZB_HA_DECLARE_SIMPLE_SENSOR_CTX | ( | device_ctx, | |
ep_name | |||
) | ZBOSS_DECLARE_DEVICE_CTX_1_EP(device_ctx, ep_name) |
Declare Simple Sensor device context.
device_ctx | - device context variable name. |
ep_name | - endpoint variable name. |
#define ZB_HA_DECLARE_SIMPLE_SENSOR_EP | ( | ep_name, | |
ep_id, | |||
cluster_list | |||
) |
Declare endpoint for Simple Sensor device.
ep_name | - endpoint variable name |
ep_id | - endpoint ID |
cluster_list | - endpoint cluster list |