Digi XBee(R) ANSI C Host Library
|
Files | |
file | zcl_basic.h |
ZigBee Cluster Library; Basic Cluster (ZCL_CLUSTER_BASIC, 0x0000) | |
file | zcl_basic_attributes.h |
file | zcl_basic.c |
Support for the "Reset to Factory Defaults" command on the Basic Server Cluster. | |
Data Structures | |
struct | zcl_basic_dev_info |
Global used to hold values referenced by zcl_basic_attributes[]. More... | |
Macros | |
#define | ZCL_VERSION 0x01 |
ZCL_VERSION is sent as ZCLVersion attribute. More... | |
#define | ZCL_BASIC_PS_BATTERY_BACKUP 0x80 |
definition of b7 of PowerSource attribute (device has battery backup) | |
#define | ZCL_BASIC_CMD_FACTORY_DEFAULTS 0x00 |
Single command of the Basic Server Cluster. | |
#define | ZCL_CLUST_ENTRY_BASIC_SERVER |
Macro used to add a Basic Cluster Server to an endpoint's cluster table. More... | |
Functions | |
int | _zcl_basic_server (const wpan_envelope_t FAR *envelope, void FAR *context) |
Handles commands for the Basic Server Cluster. More... | |
Variables | |
const struct zcl_basic_dev_info | zcl_basic_dev_info |
const zcl_attribute_base_t FAR | zcl_basic_attributes [] |
Table of attributes for the Basic Cluster Server. | |
const zcl_attribute_tree_t FAR | zcl_basic_attribute_tree [] |
ZCL Basic Cluster Attribute IDs | |
#define | ZCL_BASIC_ATTR_ZCL_VERSION 0x0000 |
ZCLVersion, UINT8, read-only. | |
#define | ZCL_BASIC_ATTR_APP_VERSION 0x0001 |
ApplicationVersion, UINT8, read-only. | |
#define | ZCL_BASIC_ATTR_STACK_VERSION 0x0002 |
StackVersion, UINT8, read-only. | |
#define | ZCL_BASIC_ATTR_HW_VERSION 0x0003 |
HWVersion, UINT8, read-only. | |
#define | ZCL_BASIC_ATTR_MANUFACTURER_NAME 0x0004 |
ManufacturerName, 32-char STRING, read-only. | |
#define | ZCL_BASIC_ATTR_MODEL_IDENTIFIER 0x0005 |
ModelIdentifier, 32-char STRING, read-only. | |
#define | ZCL_BASIC_ATTR_DATE_CODE 0x0006 |
DateCode, 16-char STRING, read-only. | |
#define | ZCL_BASIC_ATTR_POWER_SOURCE 0x0007 |
PowerSource, ENUM8, read-only. | |
#define | ZCL_BASIC_ATTR_LOCATION_DESC 0x0010 |
LocationDescription, 16-char STRING, r/w. | |
#define | ZCL_BASIC_ATTR_PHYSICAL_ENV 0x0011 |
PhysicalEnvironment, ENUM8, r/w. | |
#define | ZCL_BASIC_ATTR_DEVICE_ENABLED 0x0012 |
DeviceEnabled, BOOLEAN, r/w. | |
#define | ZCL_BASIC_ATTR_ALARM_MASK 0x0013 |
AlarmMask, BITMAP8, r/w. | |
#define | ZCL_BASIC_PS_UNKNOWN 0x00 |
Unknown. | |
#define | ZCL_BASIC_PS_SINGLE_PHASE 0x01 |
Mains (single phase) | |
#define | ZCL_BASIC_PS_THREE_PHASE 0x02 |
Mains (3 phase) | |
#define | ZCL_BASIC_PS_BATTERY 0x03 |
Battery. | |
#define | ZCL_BASIC_PS_DC 0x04 |
DC source. | |
#define | ZCL_BASIC_PS_EMERGENCY_CONST 0x05 |
Emergency mains, constant power. | |
#define | ZCL_BASIC_PS_EMERGENCY_SWITCH 0x06 |
Emergency mains, transfer switch. | |
#define ZCL_CLUST_ENTRY_BASIC_SERVER |
Macro used to add a Basic Cluster Server to an endpoint's cluster table.
If #ZCL_FACTORY_RESET_FN is defined, the Basic Server Cluster will support the optional "Reset to Factory Defaults" command.
Note that you must #include "zcl_basic_attributes.h" in your program (to create constants referenced by the macros) before using these macros in a cluster table.
#define ZCL_VERSION 0x01 |
ZCL_VERSION is sent as ZCLVersion attribute.
Per the ZCL Spec, 3.2.2.2.2: "For the initial version of the ZCL, this attribute shall be set to 0x01."
int _zcl_basic_server | ( | const wpan_envelope_t FAR * | envelope, |
void FAR * | context | ||
) |
Handles commands for the Basic Server Cluster.
Currently supports the only command ID in the spec, 0x00 - Reset to Factory Defaults.
References zcl_command_t::command, zcl_command_t::frame_control, ZCL_BASIC_CMD_FACTORY_DEFAULTS, ZCL_CMD_MATCH, zcl_command_build(), zcl_default_response(), and zcl_general_command().
const zcl_attribute_tree_t FAR zcl_basic_attribute_tree[] |
const struct zcl_basic_dev_info zcl_basic_dev_info |