
Data Structures | |
| struct | zb_zcl_ota_upgrade_file_header_s |
| Structure representation of OTA File Header, see ZCL8 specification, subsection 11.4.2, Table 11-2. OTA Header Fields. More... | |
| struct | zb_zcl_ota_upgrade_file_header_optional_s |
| struct | zb_zcl_ota_upgrade_sub_element_s |
| Structure representation of OTA File Sub-element, see ZCL8 specification, subsection 11.4.3. More... | |
| struct | zb_zcl_ota_upgrade_ecdsa_s |
| Structure representation of OTA ECDSA Signature (Crypto Suite 1), see ZCL8 specification, subsection 11.4.6. More... | |
| struct | zb_zcl_ota_upgrade_ecdsa_signing_s |
| Structure representation of OTA ECDSA Signature, see OTA spec 6.3.6. More... | |
| struct | zb_zcl_ota_upgrade_ecdsa_certificate_s |
| Structure representation of OTA ECDSA Certificate, see OTA spec 6.3.7. More... | |
| struct | zb_zcl_ota_upgrade_server_insert_file_s |
| Structure representation of Data for insert OTA file to upgrade mechanism. More... | |
| struct | zb_zcl_ota_upgrade_server_remove_file_s |
| Structure representation of Data for insert OTA file to upgrade mechanism. More... | |
| struct | zb_zcl_ota_upgrade_data_s |
| Structure representation of OTA file on server side. More... | |
| struct | zb_zcl_ota_upgrade_server_variable_s |
| Structure representation of server side variables. More... | |
| struct | zb_zcl_ota_upgrade_srv_query_img_param_s |
| struct | zb_zcl_ota_upgrade_srv_upgrade_started_param_s |
| struct | zb_zcl_ota_upgrade_srv_upgrade_aborted_param_s |
| struct | zb_zcl_ota_upgrade_srv_upgrade_end_param_s |
| struct | zb_zcl_ota_upgrade_client_variable_s |
| Structure representation of client side variables. More... | |
| struct | zb_zcl_ota_upgrade_attrs_s |
| OTA Upgrade cluster attributes structure. More... | |
| struct | zb_zcl_ota_upgrade_query_next_image_s |
| Structure representation of Query Next Image Request command payload. More... | |
| struct | zb_zcl_ota_upgrade_image_block_s |
| Structure representation of Image Block Request command payload. More... | |
| struct | zb_zcl_ota_upgrade_image_page_s |
| Structure representation of Image Page Request command payload. More... | |
| struct | zb_zcl_ota_upgrade_upgrade_end_s |
| Structure representation of Upgrade End Request command payload. More... | |
| struct | zb_zcl_ota_upgrade_query_specific_file_s |
| Structure representation of Query Specific File Request command payload. More... | |
| struct | zb_zcl_ota_upgrade_image_notify_s |
| Structure representation of Image Notify response command payload. More... | |
| struct | zb_zcl_ota_upgrade_query_next_image_res_s |
| Structure representation of Query Next Image Response command payload. More... | |
| struct | zb_zcl_ota_upgrade_image_block_res_s |
| Structure representation of Image Block Response command payload. More... | |
| struct | zb_zcl_ota_upgrade_upgrade_end_res_s |
| Structure representation of Upgrade End Response command payload. More... | |
| struct | zb_zcl_ota_upgrade_query_specific_file_res_s |
| Structure representation of Query Specific File Response command payload. More... | |
| struct | zb_zcl_ota_upgrade_value_param_s |
| Declare User Application about upgrade status. More... | |
Macros | |
| #define | ZB_ZCL_CLUSTER_ID_OTA_UPGRADE_SERVER_ROLE_INIT zb_zcl_ota_upgrade_init_srv |
| #define | ZB_ZCL_CLUSTER_ID_OTA_UPGRADE_CLIENT_ROLE_INIT zb_zcl_ota_upgrade_init_cli |
Typedefs | |
| typedef struct zb_zcl_ota_upgrade_value_param_s | zb_zcl_ota_upgrade_value_param_t |
| Declare User Application about upgrade status. More... | |
Functions | |
| zb_ret_t | zb_zcl_check_value_ota_upgrade (zb_uint16_t attr_id, zb_uint8_t endpoint, zb_uint8_t *value) |
| void | zcl_ota_abort (zb_uint8_t endpoint, zb_uint8_t param) |
| Abort OTA Upgrade process. More... | |
| void | zb_zcl_ota_upgrade_init_srv (void) |
| void | zb_zcl_ota_upgrade_init_cli (void) |
| void | zb_zcl_ota_upgrade_send_query_next_image_response (zb_zcl_parsed_hdr_t *zcl_parsed_hdr, zb_bool_t image_present, zb_uindex_t table_idx) |
| void | zb_zcl_ota_upgrade_send_image_block_response (zb_zcl_parsed_hdr_t *zcl_header, zb_uindex_t table_idx, zb_bool_t block_present, zb_uint32_t offset, zb_uint8_t data_size, const zb_uint8_t *data) |
OTA File Header format | |
Hook on Write attribute send Check-in if change Check-in interval & Check-in remain time > new check-in interval Structures for representation OTA File Header | |
| #define | ZB_ZCL_OTA_FILE_IS_FILE_SPECIFIC(head) (((head)->fc) & ZB_ZCL_OTA_UPGRADE_FILE_HEADER_FC_DEVICE_SPECIFIC) |
| #define | ZB_ZCL_OTA_UPGRADE_FILE_HEADER_FILE_ID 0x0BEEF11E |
| Default OTA Upgrade File Identifier, see ZCL8 specification, subsection 11.4.2.1. More... | |
| #define | ZB_ZCL_OTA_UPGRADE_FILE_HEADER_FILE_VERSION 0x0100 |
| Default OTA Upgrade File Version, see ZCL8 specification, subsection 11.4.2.2. More... | |
| #define | ZB_ZCL_OTA_UPGRADE_FILE_HEADER_MANUFACTURE_CODE_WILD_CARD 0xffff |
| Special Manufacturer Code, see ZCL8 specification, subsection 11.4.2.5. More... | |
| #define | ZB_ZCL_OTA_UPGRADE_FILE_GET_APP_RELEASE(ver) (((ver) >>24) & 0xff) |
| OTA Upgrade File Version, App release, see ZCL8 specification, subsection 11.4.2.7. More... | |
| #define | ZB_ZCL_OTA_UPGRADE_FILE_GET_APP_BUILD(ver) (((ver) >>16) & 0xff) |
| OTA Upgrade File Version, App build, see ZCL8 specification, subsection 11.4.2.7. More... | |
| #define | ZB_ZCL_OTA_UPGRADE_FILE_GET_STACK_RELEASE(ver) (((ver) >>8) & 0xff) |
| OTA Upgrade File Version, Stack release, see ZCL8 specification, subsection 11.4.2.7. More... | |
| #define | ZB_ZCL_OTA_UPGRADE_FILE_GET_STACK_BUILD(ver) ((ver) & 0xff) |
| OTA Upgrade File Version, Stack build, see ZCL8 specification, subsection 11.4.2.7. More... | |
| #define | ZB_ZCL_OTA_UPGRADE_FILE_MAKE_VERSION(app_rel, app_build, stack_rel, stack_build) ((app_rel) << 24 | (app_build) << 16 | (stack_rel) << 8 | (stack_build)) |
| OTA Upgrade File Version, make file version, see ZCL8 specification, subsection 11.4.2.7. More... | |
| #define | ZB_ZCL_OTA_UPGRADE_VERSION_CMP(ver1, ver2) ( (ver1) != (ver2) ) |
| Compare 2 OTA versions and decide if it is needed to do upgrade. More... | |
| #define | ZB_ZCL_OTA_UPGRADE_FILE_GET_HW_VERSION(ver) (((ver) >>8) & 0xff) |
| OTA Upgrade HW Version Get Version, see ZCL8 specification, subsection 11.4.2.13. More... | |
| #define | ZB_ZCL_OTA_UPGRADE_FILE_GET_HW_REVISION(ver) ((ver) & 0xff) |
| OTA Upgrade HW Version Get Revision, see ZCL8 specification, subsection 11.4.2.13. More... | |
| #define | ZB_ZCL_OTA_UPGRADE_FILE_MAKE_HW_VERSION(ver, rev) ((ver) << 8 | (rev)) |
| OTA Upgrade Make HW Version, see ZCL8 specification, subsection 11.4.2.13. More... | |
| #define | ZB_ZCL_OTA_UPGRADE_FILE_HW_VERSION_DEF_VALUE 0xffff |
| Default value of OTA Upgrade HW Version. More... | |
| #define | ZB_ZCL_OTA_UPGRADE_FILE_DEST_ADDRESS_DEF_VALUE { 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff } |
| Default value of OTA Upgrade destination address. More... | |
| enum | zb_zcl_ota_upgrade_file_header_fc_e { ZB_ZCL_OTA_UPGRADE_FILE_HEADER_FC_CREDENTIAL_VER = 1 << 0, ZB_ZCL_OTA_UPGRADE_FILE_HEADER_FC_DEVICE_SPECIFIC = 1 << 1, ZB_ZCL_OTA_UPGRADE_FILE_HEADER_FC_HW_VER = 1 << 2 } |
| OTA File header - fc fields structure. More... | |
| enum | zb_zcl_ota_upgrade_file_header_image_type_e { ZB_ZCL_OTA_UPGRADE_FILE_HEADER_IMAGE_MANUF_SPEC_MAX = 0xffbf, ZB_ZCL_OTA_UPGRADE_FILE_HEADER_IMAGE_SECURITY_CRED = 0xffc0, ZB_ZCL_OTA_UPGRADE_FILE_HEADER_IMAGE_CONFIG = 0xffc1, ZB_ZCL_OTA_UPGRADE_FILE_HEADER_IMAGE_LOG = 0xffc2, ZB_ZCL_OTA_UPGRADE_FILE_HEADER_IMAGE_WILD_CARD = 0xffff } |
| OTA File header - Image Type Values. More... | |
| enum | zb_zcl_ota_upgrade_file_header_stack_version_e { ZB_ZCL_OTA_UPGRADE_FILE_HEADER_STACK_2006 = 0x0000, ZB_ZCL_OTA_UPGRADE_FILE_HEADER_STACK_2007 = 0x0001, ZB_ZCL_OTA_UPGRADE_FILE_HEADER_STACK_PRO = 0x0002, ZB_ZCL_OTA_UPGRADE_FILE_HEADER_STACK_IP = 0x0003 } |
| OTA File header - Zigbee Stack version. More... | |
| enum | zb_zcl_ota_upgrade_file_header_security_version_e { ZB_ZCL_OTA_UPGRADE_FILE_HEADER_SECURITY_VER_SE1_0 = 0x00, ZB_ZCL_OTA_UPGRADE_FILE_HEADER_SECURITY_VER_SE1_1 = 0x01, ZB_ZCL_OTA_UPGRADE_FILE_HEADER_SECURITY_VER_SE2_0 = 0x02, ZB_ZCL_OTA_UPGRADE_FILE_HEADER_SECURITY_VER_SE1_2 = 0x03 } |
| OTA File header - Security Credential Version. More... | |
| typedef struct zb_zcl_ota_upgrade_file_header_s | zb_zcl_ota_upgrade_file_header_t |
| Structure representation of OTA File Header, see ZCL8 specification, subsection 11.4.2, Table 11-2. OTA Header Fields. More... | |
| typedef struct zb_zcl_ota_upgrade_file_header_optional_s | zb_zcl_ota_upgrade_file_header_optional_t |
OTA File Sub-element format | |
| #define | ZB_ZCL_OTA_UPGRADE_ECDSA_TAG_ID ZB_ZCL_OTA_UPGRADE_FILE_TAG_ECDSA |
| Special Manufacturer Code, see ZCL8 specification, subsection 11.4.6. More... | |
| #define | ZB_ZCL_OTA_UPGRADE_ECDSA_LENGTH 0x00000032 |
| Special Manufacturer Code, see ZCL8 specification, subsection 11.4.6. More... | |
| #define | ZB_ZCL_OTA_UPGRADE_ECDSA_SIGNING_TAG_ID 0x0002 |
| Special Manufacturer Code, see spec 6.3.6. More... | |
| #define | ZB_ZCL_OTA_UPGRADE_ECDSA_SIGNING_LENGTH 0x00000030 |
| Special Manufacturer Code, see spec 6.3.6. More... | |
| #define | ZB_ZCL_OTA_UPGRADE_ECDSA_CERTIFICATE_TAG_ID 0x0003 |
| Special Manufacturer Code, see spec 6.3.7. More... | |
| #define | ZB_ZCL_OTA_UPGRADE_ECDSA_CERTIFICATE_LENGTH 0x00000010 |
| Special Manufacturer Code, see spec 6.3.7. More... | |
| enum | zb_zcl_ota_upgrade_sub_element_tags_e { ZB_ZCL_OTA_UPGRADE_FILE_TAG_UPGRADE_IMAGE = 0x0000, ZB_ZCL_OTA_UPGRADE_FILE_TAG_ECDSA = 0x0001, ZB_ZCL_OTA_UPGRADE_FILE_TAG_ECDSA_CERT = 0x0002, ZB_ZCL_OTA_UPGRADE_FILE_TAG_IMAGE_INTEGRITY_CODE = 0x0003, ZB_ZCL_OTA_UPGRADE_FILE_TAG_PICTURE_DATA = 0x0004, ZB_ZCL_OTA_UPGRADE_FILE_TAG_ECDSA_V_2 = 0x0005, ZB_ZCL_OTA_UPGRADE_FILE_TAG_ECDSA_CERT_V_2 = 0x0006, ZB_ZCL_OTA_UPGRADE_FILE_TAG_MANUF_MIN = 0xf000, ZB_ZCL_OTA_UPGRADE_FILE_TAG_MANUF_MAX = 0xffff } |
| OTA File header - Tag Identifiers. More... | |
| typedef struct zb_zcl_ota_upgrade_sub_element_s | zb_zcl_ota_upgrade_sub_element_t |
| Structure representation of OTA File Sub-element, see ZCL8 specification, subsection 11.4.3. More... | |
| typedef struct zb_zcl_ota_upgrade_ecdsa_s | zb_zcl_ota_upgrade_ecdsa_t |
| Structure representation of OTA ECDSA Signature (Crypto Suite 1), see ZCL8 specification, subsection 11.4.6. More... | |
| typedef struct zb_zcl_ota_upgrade_ecdsa_signing_s | zb_zcl_ota_upgrade_ecdsa_signing_t |
| Structure representation of OTA ECDSA Signature, see OTA spec 6.3.6. More... | |
| typedef struct zb_zcl_ota_upgrade_ecdsa_certificate_s | zb_zcl_ota_upgrade_ecdsa_ertificate_t |
| Structure representation of OTA ECDSA Certificate, see OTA spec 6.3.7. More... | |
OTA Upgrade cluster attributes | |
| #define | ZB_ZCL_OTA_UPGRADE_CLUSTER_REVISION_DEFAULT ((zb_uint16_t)0x0004u) |
| Default value for OTA Upgrade cluster revision global attribute. More... | |
| #define | ZB_ZCL_OTA_UPGRADE_QUERY_IMAGE_BLOCK_DATA_SIZE_MAX 64 |
| Maximum size data for Query Image Block Request. More... | |
| #define | ZB_ZCL_OTA_UPGRADE_INSERT_FILE(buf, ep, i, file, upgrade_tm, notify, ret_code) |
| #define | ZB_ZCL_OTA_UPGRADE_REMOVE_FILE(buf, ep, i, ret_code) |
| #define | ZB_ZCL_OTA_UPGRADE_DATA_SIZE_DEF_VALUE 0xff |
| Default value for DataSize, OTA spec. More... | |
| #define | ZB_ZCL_OTA_UPGRADE_QUERY_JITTER_MIN_VALUE 0x01 |
| Minimum value for QueryJitter, OTA spec. More... | |
| #define | ZB_ZCL_OTA_UPGRADE_QUERY_JITTER_MAX_VALUE 0x64 |
| Maximum value for QueryJitter, OTA spec. More... | |
| #define | ZB_ZCL_OTA_UPGRADE_QUERY_JITTER_DEF_VALUE 0x32 |
| Default value for QueryJitter, OTA spec. More... | |
| #define | ZB_ZCL_OTA_UPGRADE_CURRENT_TIME_DEF_VALUE 0xffffffff |
| Default value for currentTime, OTA spec. More... | |
| #define | ZB_ZCL_OTA_UPGRADE_UPGRADE_TIME_DEF_VALUE 0xffffffff |
| Default value for UpgradeTime, OTA spec. More... | |
| #define | ZB_ZCL_OTA_UPGRADE_SERVER_DEF_VALUE { 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff } |
| Default value for UpgradeServerID attribute, ZCL8 specification, subsection 11.10.1. More... | |
| #define | ZB_ZCL_OTA_UPGRADE_FILE_OFFSET_DEF_VALUE 0xffffffff |
| Default value for FileOffset attribute, ZCL8 specification, subsection 11.10.2. More... | |
| #define | ZB_ZCL_OTA_UPGRADE_FILE_VERSION_DEF_VALUE 0xffffffff |
| Default value for CurrentFileVersion attribute, ZCL8 specification, subsection 11.10.3. More... | |
| #define | ZB_ZCL_OTA_UPGRADE_STACK_VERSION_DEF_VALUE 0xffff |
| Default value for CurrentZigbeeStackVersion attribute, ZCL8 specification, subsection 11.10.4. More... | |
| #define | ZB_ZCL_OTA_UPGRADE_DOWNLOADED_FILE_VERSION_DEF_VALUE 0xffffffff |
| Default value for DownloadedFileVersion attribute, ZCL8 specification, subsection 11.10.5. More... | |
| #define | ZB_ZCL_OTA_UPGRADE_DOWNLOADED_STACK_DEF_VALUE 0xffff |
| Default value for DownloadedZigbeeStackVersion attribute, ZCL8 specification, subsection 11.10.6. More... | |
| #define | ZB_ZCL_OTA_UPGRADE_IMAGE_STATUS_DEF_VALUE 0x00 |
| Default value for ImageUpgradeStatus attribute, ZCL8 specification, subsection 11.10.7. More... | |
| #define | ZB_ZCL_OTA_UPGRADE_IMAGE_STAMP_MIN_VALUE 0xfffe |
| Maximum value for MinimumBlockPeriod attribute, ZCL8 specification, subsection 11.10.10. More... | |
| #define | ZB_ZCL_OTA_UPGRADE_SERVER_ENDPOINT_DEF_VALUE 0xff |
| Default value for OTA server endpoint custom attribute. More... | |
| #define | ZB_ZCL_OTA_UPGRADE_SERVER_ADDR_DEF_VALUE 0xffff |
| Default value for OTA server addr custom attribute. More... | |
| #define | ZB_ZCL_OTA_UPGRADE_QUERY_TIMER_COUNT_DEF (24*60) |
| Default Frequency request server about new upgrade file (minutes) More... | |
| #define | ZB_ZCL_OTA_UPGRADE_QUERY_TIMER_INTERVAL 60l * ZB_TIME_ONE_SECOND |
| Timer interval for Query timer. More... | |
| #define | ZB_ZCL_OTA_UPGRADE_MAX_INTERVAL 60 |
| Maximum value of nextImageQuery interval. More... | |
| #define | ZB_ZCL_OTA_UPGRADE_RESEND_BUFFER_DELAY ZB_TIME_ONE_SECOND * 15 |
| Resend buffer delay. More... | |
| #define | ZB_ZCL_OTA_UPGRADE_END_RES_TIMEOUT ZB_TIME_ONE_SECOND * 90 |
| End Response timeout. More... | |
| #define | ZB_ZCL_DECLARE_OTA_UPGRADE_ATTRIB_LIST(attr_list, upgrade_server, file_offset, file_version, stack_version, downloaded_file_ver, downloaded_stack_ver, image_status, manufacturer, image_type, min_block_reque, image_stamp, server_addr, server_ep, hardware_version, max_data_size, query_timer) |
| Declare attribute list for OTA Upgrade cluster - client side. More... | |
| #define | ZB_ZCL_DECLARE_OTA_UPGRADE_ATTR_LIST(attr_list, attrs) |
| Declare attribute list for OTA upgrade cluster (using structure) More... | |
| #define | ZB_ZCL_DECLARE_OTA_UPGRADE_ATTRIB_LIST_SERVER(attr_list, query_jitter, current_time, length) |
| Declare attribute list for OTA Upgrade cluster - server side. More... | |
| enum | zb_zcl_ota_upgrade_attr_e { ZB_ZCL_ATTR_OTA_UPGRADE_SERVER_ID = 0x0000, ZB_ZCL_ATTR_OTA_UPGRADE_FILE_OFFSET_ID = 0x0001, ZB_ZCL_ATTR_OTA_UPGRADE_FILE_VERSION_ID = 0x0002, ZB_ZCL_ATTR_OTA_UPGRADE_STACK_VERSION_ID = 0x0003, ZB_ZCL_ATTR_OTA_UPGRADE_DOWNLOADED_FILE_VERSION_ID = 0x0004, ZB_ZCL_ATTR_OTA_UPGRADE_DOWNLOADED_STACK_VERSION_ID = 0x0005, ZB_ZCL_ATTR_OTA_UPGRADE_IMAGE_STATUS_ID = 0x0006, ZB_ZCL_ATTR_OTA_UPGRADE_MANUFACTURE_ID = 0x0007, ZB_ZCL_ATTR_OTA_UPGRADE_IMAGE_TYPE_ID = 0x0008, ZB_ZCL_ATTR_OTA_UPGRADE_MIN_BLOCK_REQUE_ID = 0x0009, ZB_ZCL_ATTR_OTA_UPGRADE_IMAGE_STAMP_ID = 0x000a, ZB_ZCL_ATTR_OTA_UPGRADE_UPGRADE_ACTIVATION_POLICY_ID = 0x000b, ZB_ZCL_ATTR_OTA_UPGRADE_UPGRADE_TIMEOUT_POLICY_ID = 0x000c, ZB_ZCL_ATTR_OTA_UPGRADE_SERVER_ENDPOINT_ID = 0xfff3, ZB_ZCL_ATTR_OTA_UPGRADE_SERVER_ADDR_ID = 0xfff2, ZB_ZCL_ATTR_OTA_UPGRADE_CLIENT_DATA_ID = 0xfff1, ZB_ZCL_ATTR_OTA_UPGRADE_SERVER_DATA_ID = 0xfff0 } |
| OTA Upgrade cluster attribute identifiers. More... | |
| enum | zb_zcl_ota_upgrade_image_status_e { ZB_ZCL_OTA_UPGRADE_IMAGE_STATUS_NORMAL = 0x00, ZB_ZCL_OTA_UPGRADE_IMAGE_STATUS_DOWNLOADING = 0x01, ZB_ZCL_OTA_UPGRADE_IMAGE_STATUS_DOWNLOADED = 0x02, ZB_ZCL_OTA_UPGRADE_IMAGE_STATUS_WAITING_UPGRADE = 0x03, ZB_ZCL_OTA_UPGRADE_IMAGE_STATUS_COUNT_DOWN = 0x04, ZB_ZCL_OTA_UPGRADE_IMAGE_STATUS_WAIT_FOR_MORE = 0x05, ZB_ZCL_OTA_UPGRADE_IMAGE_STATUS_WAIT_TO_UPGRADE_VIA_EXT_EVENT = 0x06 } |
| OTA Image Upgrade Status Attribute Values. More... | |
| typedef zb_ret_t(* | zb_zcl_ota_upgrade_next_data_ind_t) (zb_uint8_t index, zb_zcl_parsed_hdr_t *zcl_header, zb_uint32_t offset, zb_uint8_t size, zb_uint8_t **data) |
| Callback function for send next data portion. More... | |
| typedef struct zb_zcl_ota_upgrade_server_insert_file_s | zb_zcl_ota_upgrade_server_insert_file_t |
| Structure representation of Data for insert OTA file to upgrade mechanism. More... | |
| typedef struct zb_zcl_ota_upgrade_server_remove_file_s | zb_zcl_ota_upgrade_server_remove_file_t |
| Structure representation of Data for insert OTA file to upgrade mechanism. More... | |
| typedef struct zb_zcl_ota_upgrade_data_s | zb_zcl_ota_upgrade_data_t |
| Structure representation of OTA file on server side. More... | |
| typedef struct zb_zcl_ota_upgrade_server_variable_s | zb_zcl_ota_upgrade_server_variable_t |
| Structure representation of server side variables. More... | |
| typedef struct zb_zcl_ota_upgrade_srv_query_img_param_s | zb_zcl_ota_upgrade_srv_query_img_param_t |
| typedef struct zb_zcl_ota_upgrade_srv_upgrade_started_param_s | zb_zcl_ota_upgrade_srv_upgrade_started_param_t |
| typedef struct zb_zcl_ota_upgrade_srv_upgrade_aborted_param_s | zb_zcl_ota_upgrade_srv_upgrade_aborted_param_t |
| typedef struct zb_zcl_ota_upgrade_srv_upgrade_end_param_s | zb_zcl_ota_upgrade_srv_upgrade_end_param_t |
| typedef struct zb_zcl_ota_upgrade_client_variable_s | zb_zcl_ota_upgrade_client_variable_t |
| Structure representation of client side variables. More... | |
| typedef struct zb_zcl_ota_upgrade_attrs_s | zb_zcl_ota_upgrade_attrs_t |
| OTA Upgrade cluster attributes structure. More... | |
| void | zb_zcl_ota_upgrade_init_server (zb_uint8_t endpoint, zb_zcl_ota_upgrade_next_data_ind_t next_data_ind_cb) |
| Initialize OTA Upgrade cluster - server part For server clear custom data and registry next data indication. More... | |
| zb_ret_t | zb_zcl_ota_upgrade_insert_file (zb_uint8_t param) |
| Insert upgrade OTA file into Server upgrade table. More... | |
| zb_ret_t | zb_zcl_ota_upgrade_remove_file (zb_uint8_t param) |
| Remove upgrade file from Server upgrade table. More... | |
| void | zb_zcl_ota_upgrade_init_client (zb_uint8_t param) |
| Initialize OTA Upgrade cluster - client part For server clear custom data For client initiate search Upgrade server. More... | |
| zb_ret_t | zb_zcl_ota_upgrade_start_client (zb_uint8_t server_ep, zb_uint16_t server_addr) |
| Start OTA Upgrade client with pre-defined OTA Upgrade Server attributes (without Service Discovery) More... | |
| void | zb_zcl_ota_upgrade_stop_client (void) |
| Stop process OTA Upgrade / OTA query new images Client stop schedule OTA command & clear OTA status. More... | |
| void | zb_zcl_ota_upgrade_resume_client (zb_uint8_t param, zb_uint8_t upgrade_status) |
| Resume process OTA Upgrade if it was previously suspended by the application. More... | |
| void | zb_zcl_ota_upgrade_set_query_interval (zb_uint8_t endpoint, zb_uint16_t interval) |
| Set Frequency request server about new upgrade file (minutes) More... | |
| void | zb_zcl_ota_upgrade_file_upgraded (zb_uint8_t endpoint) |
| Clear attribute after upgrade. More... | |
OTA Upgrade cluster commands | |
| #define | ZB_ZCL_OTA_UPGRADE_SEND_QUERY_NEXT_IMAGE_REQ( buffer, addr, dst_addr_mode, dst_ep, ep, prfl_id, def_resp, cb, fc, manufacturer, image_type, file_version, hw_version, aps_secured) |
| Send "Query Next Image Request" command, see ZCL8 specification, subsection 11.13.4. More... | |
| #define | ZB_ZCL_OTA_UPGRADE_GET_QUERY_NEXT_IMAGE_REQ(data_ptr, buffer, status) |
| Macro for getting "Query Next Image Request" command, see ZCL8 specification, subsection 11.13.4. More... | |
| #define | ZB_ZCL_OTA_UPGRADE_SEND_IMAGE_BLOCK_REQ( buffer, addr, dst_addr_mode, dst_ep, ep, prfl_id, def_resp, cb, fc, manufacturer, image_type, file_version, file_offset, data_size_max, node_addr, block_delay, current_delay) |
| Send "Image Block Request" command, see ZCL8 specification, subsection 11.13.6. More... | |
| #define | ZB_ZCL_OTA_UPGRADE_GET_IMAGE_BLOCK_REQ(data_ptr, buffer, status) |
| Macro for getting "Image Block Request" command, see ZCL8 specification, subsection 11.13.6. More... | |
| #define | ZB_ZCL_OTA_UPGRADE_SEND_IMAGE_PAGE_REQ( buffer, addr, dst_addr_mode, dst_ep, ep, prfl_id, def_resp, cb, fc, manufacturer, image_type, file_version, file_offset, data_size_max, page_size, response_spacing, node_addr) |
| Send "Image Page Request" command, see ZCL8 specification, subsection 11.13.7. More... | |
| #define | ZB_ZCL_OTA_UPGRADE_GET_IMAGE_PAGE_REQ(data_ptr, buffer, status) |
| Macro for getting "Image Page Request" command, see ZCL8 specification, subsection 11.13.7. More... | |
| #define | ZB_ZCL_OTA_UPGRADE_SEND_UPGRADE_END_REQ( buffer, addr, dst_addr_mode, dst_ep, ep, prfl_id, def_resp, cb, status, manufacturer, image_type, file_version) |
| Send "Upgrade End Request" command, see ZCL8 specification, subsection 11.13.9. More... | |
| #define | ZB_ZCL_OTA_UPGRADE_GET_UPGRADE_END_REQ(data_ptr, buffer, status_) |
| Macro for getting "Upgrade End Request" command, see ZCL8 specification, subsection 11.13.9. More... | |
| #define | ZB_ZCL_OTA_UPGRADE_SEND_QUERY_SPECIFIC_FILE_REQ( buffer, addr, dst_addr_mode, dst_ep, ep, prfl_id, def_resp, cb, node_addr, manufacturer, image_type, file_version, stack_version) |
| Send "Query Specific File Request" command, see ZCL8 specification, subsection 11.13.10. More... | |
| #define | ZB_ZCL_OTA_UPGRADE_GET_QUERY_SPECIFIC_FILE_REQ(data_ptr, buffer, status) |
| Macro for getting "Query Specific File Request" command, see ZCL8 specification, subsection 11.13.10. More... | |
| #define | ZB_ZCL_OTA_UPGRADE_SEND_IMAGE_NOTIFY_REQ( buffer, addr, dst_addr_mode, dst_ep, ep, prfl_id, def_resp, cb, payload_type, query_jitter, manufacturer, image_type, file_version) |
| Send Image Notify command, see ZCL8 specification, subsection 11.13.3. More... | |
| #define | ZB_ZCL_OTA_UPGRADE_GET_IMAGE_NOTIFY_REQ(data_ptr, buffer, status) |
| #define | ZB_ZCL_OTA_UPGRADE_SEND_QUERY_NEXT_IMAGE_RES( buffer, addr, dst_addr_mode, dst_ep, ep, prfl_id, seq, status, manufacturer, image_type, file_version, image_size) |
| Send Query Next Image Response command, see ZCL8 specification, subsection 11.13.5. More... | |
| #define | ZB_ZCL_OTA_UPGRADE_GET_QUERY_NEXT_IMAGE_RES(data_ptr, buffer, status_) |
| Macro for getting Query Next Image Response command, see ZCL8 specification, subsection 11.13.5. More... | |
| #define | ZB_ZCL_OTA_UPGRADE_SEND_IMAGE_BLOCK_SUCCESS_RES( buffer, addr, dst_addr_mode, dst_ep, ep, prfl_id, seq, manufacturer, image_type, file_version, file_offset, data_size, image_data) |
| Send Image Block Response command - success status, see ZCL8 specification, subsection 11.13.8. More... | |
| #define | ZB_ZCL_OTA_UPGRADE_SEND_IMAGE_BLOCK_WAIT_FOR_DATA_RES( buffer, addr, dst_addr_mode, dst_ep, ep, prfl_id, seq, current_time, request_time, delay) |
| Send Image Block Response command - wait for data status, see ZCL8 specification, subsection 11.13.8. More... | |
| #define | ZB_ZCL_OTA_UPGRADE_SEND_IMAGE_BLOCK_ABORT_RES( buffer, addr, dst_addr_mode, dst_ep, ep, prfl_id, seq) |
| Send Image Block Response command - abort status, see ZCL8 specification, subsection 11.13.8. More... | |
| #define | ZB_ZCL_OTA_UPGRADE_GET_IMAGE_BLOCK_RES(data_ptr, buffer, status_) |
| Macro for getting Image Block Response command, see ZCL8 specification, subsection 11.13.8. More... | |
| #define | ZB_ZCL_OTA_UPGRADE_SEND_UPGRADE_END_RES( buffer, addr, dst_addr_mode, dst_ep, ep, prfl_id, seq, manufacturer, image_type, file_version, current_time, upgrade_time) |
| Send Upgrade End Response command, see ZCL8 specification, subsection 11.13.9.6. More... | |
| #define | ZB_ZCL_OTA_UPGRADE_GET_UPGRADE_END_RES(data_ptr, buffer, status_) |
| Macro for getting Upgrade End Response command, see ZCL8 specification, subsection 11.13.9.6. More... | |
| #define | ZB_ZCL_OTA_UPGRADE_SEND_QUERY_SPECIFIC_FILE_RES( buffer, addr, dst_addr_mode, dst_ep, ep, prfl_id, seq, status, manufacturer, image_type, file_version, image_size) |
| Send Query Specific File Response command, see ZCL8 specification, subsection 11.13.11. More... | |
| #define | ZB_ZCL_OTA_UPGRADE_GET_QUERY_SPECIFIC_FILE_RES(data_ptr, buffer, status_) |
| Macro for getting Query Specific File Response command, see ZCL8 specification, subsection 11.13.11. More... | |
| enum | zb_zcl_ota_upgrade_cmd_e { ZB_ZCL_CMD_OTA_UPGRADE_QUERY_NEXT_IMAGE_ID = 0x01, ZB_ZCL_CMD_OTA_UPGRADE_IMAGE_BLOCK_ID = 0x03, ZB_ZCL_CMD_OTA_UPGRADE_IMAGE_PAGE_ID = 0x04, ZB_ZCL_CMD_OTA_UPGRADE_UPGRADE_END_ID = 0x06, ZB_ZCL_CMD_OTA_UPGRADE_QUERY_SPECIFIC_FILE_ID = 0x08 } |
| OTA Upgrade cluster client to server command identifiers. More... | |
| enum | zb_zcl_ota_upgrade_resp_cmd_e { ZB_ZCL_CMD_OTA_UPGRADE_IMAGE_NOTIFY_ID = 0x00, ZB_ZCL_CMD_OTA_UPGRADE_QUERY_NEXT_IMAGE_RESP_ID = 0x02, ZB_ZCL_CMD_OTA_UPGRADE_IMAGE_BLOCK_RESP_ID = 0x05, ZB_ZCL_CMD_OTA_UPGRADE_UPGRADE_END_RESP_ID = 0x07, ZB_ZCL_CMD_OTA_UPGRADE_QUERY_SPECIFIC_FILE_RESP_ID = 0x09, ZB_ZCL_CMD_OTA_UPGRADE_INTERNAL_ABORT_ID = 0xf9 } |
| OTA Upgrade cluster server to client command identifiers. More... | |
| enum | zb_zcl_ota_upgrade_query_next_image_fc_e { ZB_ZCL_OTA_UPGRADE_QUERY_NEXT_IMAGE_HW_VERSION = 1 << 0 } |
| OTA Image Upgrade Status Attribute Values. More... | |
| enum | zb_zcl_ota_upgrade_image_block_fc_e { ZB_ZCL_OTA_UPGRADE_QUERY_IMAGE_BLOCK_IEEE_PRESENT = 1 << 0, ZB_ZCL_OTA_UPGRADE_QUERY_IMAGE_BLOCK_DELAY_PRESENT = 1 << 1 } |
| OTA Image Upgrade Status Attribute Values. More... | |
| enum | zb_zcl_ota_upgrade_image_page_fc_e { ZB_ZCL_OTA_UPGRADE_QUERY_IMAGE_PAGE_IEEE_PRESENT = 1 << 0 } |
| OTA Image Upgrade Status Attribute Values. More... | |
| enum | zb_zcl_ota_upgrade_image_notify_payload_type_e { ZB_ZCL_OTA_UPGRADE_IMAGE_NOTIFY_PAYLOAD_JITTER = 0x00, ZB_ZCL_OTA_UPGRADE_IMAGE_NOTIFY_PAYLOAD_JITTER_CODE = 0x01, ZB_ZCL_OTA_UPGRADE_IMAGE_NOTIFY_PAYLOAD_JITTER_CODE_IMAGE = 0x02, ZB_ZCL_OTA_UPGRADE_IMAGE_NOTIFY_PAYLOAD_JITTER_CODE_IMAGE_VER = 0x03 } |
| OTA Image Upgrade Status Attribute Values. More... | |
| typedef struct zb_zcl_ota_upgrade_query_next_image_s | zb_zcl_ota_upgrade_query_next_image_t |
| Structure representation of Query Next Image Request command payload. More... | |
| typedef struct zb_zcl_ota_upgrade_image_block_s | zb_zcl_ota_upgrade_image_block_t |
| Structure representation of Image Block Request command payload. More... | |
| typedef struct zb_zcl_ota_upgrade_image_page_s | zb_zcl_ota_upgrade_image_page_t |
| Structure representation of Image Page Request command payload. More... | |
| typedef struct zb_zcl_ota_upgrade_upgrade_end_s | zb_zcl_ota_upgrade_upgrade_end_t |
| Structure representation of Upgrade End Request command payload. More... | |
| typedef struct zb_zcl_ota_upgrade_query_specific_file_s | zb_zcl_ota_upgrade_query_specific_file_t |
| Structure representation of Query Specific File Request command payload. More... | |
| typedef struct zb_zcl_ota_upgrade_image_notify_s | zb_zcl_ota_upgrade_image_notify_t |
| Structure representation of Image Notify response command payload. More... | |
| typedef struct zb_zcl_ota_upgrade_query_next_image_res_s | zb_zcl_ota_upgrade_query_next_image_res_t |
| Structure representation of Query Next Image Response command payload. More... | |
| typedef struct zb_zcl_ota_upgrade_image_block_res_s | zb_zcl_ota_upgrade_image_block_res_t |
| Structure representation of Image Block Response command payload. More... | |
| typedef struct zb_zcl_ota_upgrade_upgrade_end_res_s | zb_zcl_ota_upgrade_upgrade_end_res_t |
| Structure representation of Upgrade End Response command payload. More... | |
| typedef struct zb_zcl_ota_upgrade_query_specific_file_res_s | zb_zcl_ota_upgrade_query_specific_file_res_t |
| Structure representation of Query Specific File Response command payload. More... | |
| #define ZB_ZCL_CLUSTER_ID_OTA_UPGRADE_CLIENT_ROLE_INIT zb_zcl_ota_upgrade_init_cli |
| #define ZB_ZCL_CLUSTER_ID_OTA_UPGRADE_SERVER_ROLE_INIT zb_zcl_ota_upgrade_init_srv |
| void zb_zcl_ota_upgrade_init_cli | ( | void | ) |
| void zb_zcl_ota_upgrade_init_srv | ( | void | ) |
| void zb_zcl_ota_upgrade_send_image_block_response | ( | zb_zcl_parsed_hdr_t * | zcl_header, |
| zb_uindex_t | table_idx, | ||
| zb_bool_t | block_present, | ||
| zb_uint32_t | offset, | ||
| zb_uint8_t | data_size, | ||
| const zb_uint8_t * | data | ||
| ) |
Sends Image Block Response Should be used only in the following case: If application can't return a pointer to the requested block immediately on request it should return RET_BLOCKED status and should call zb_zcl_ota_upgrade_send_image_block_response() If there is no block available application should call this function with block_present parameter set to ZB_FALSE.
| zcl_header | - the header of the request packet |
| table_idx | - the index of requested block image |
| block_present | - whether the block is present |
| offset | - an offset in the image |
| data_size | - size of the provided block |
| data | - a pointer to the requested data |
| void zb_zcl_ota_upgrade_send_query_next_image_response | ( | zb_zcl_parsed_hdr_t * | zcl_parsed_hdr, |
| zb_bool_t | image_present, | ||
| zb_uindex_t | table_idx | ||
| ) |
Sends Query Next Image Response. Should be used only in the following case: If application can't return a table index immediately from user app callback (which is called by query_next_image_handler()) then it should return RET_BLOCKED status and should call zb_zcl_ota_upgrade_send_query_next_image_response(). If there is no image available application should call this function with image_present parameter set to ZB_FALSE.
| zcl_parsed_hdr | - the header of the Query Next Image packet |
| image_present | - whether the image is present |
| table_idx | - a table index of the image if image_present is ZB_TRUE |