|
Z-Wave Protocol Controller Reference
|
#include "zwave_command_class_multi_channel.h"#include <assert.h>#include <stdbool.h>#include <string.h>#include "ZW_classcmd.h"#include "zwave_command_handler.h"#include "zwave_controller_connection_info.h"#include "zwave_controller_utils.h"#include "zwave_command_class_indices.h"#include "zwave_rx.h"#include "attribute_store.h"#include "attribute_store_helper.h"#include "zpc_attribute_store_network_helper.h"#include "attribute_store_defined_attribute_types.h"#include "attribute_resolver.h"#include "zwave_unid.h"#include "sl_log.h"Macros | |
| #define | LOG_TAG "zwave_command_class_multi_channel" |
| #define | REPORT_IDENTICAL_ENDPOINTS_MASK 0x40 |
| #define | REPORT_IDENTICAL_ENDPOINTS_INDEX 2 |
| #define | REPORT_INDIVIDUAL_ENDPOINTS_INDEX 3 |
| #define | REPORT_AGGREGATED_ENDPOINTS_INDEX 4 |
| #define | CAPABILITY_REPORT_ENDPOINT_INDEX 2 |
| #define | CAPABILITY_REPORT_GENERIC_DEVICE_CLASS_INDEX 3 |
| #define | CAPABILITY_REPORT_SPECIFIC_DEVICE_CLASS_INDEX 4 |
| #define | CAPABILITY_REPORT_COMMAND_CLASS_LIST_INDEX 5 |
| #define | CAPABILITY_REPORT_ENDPOINT_LIST_INDEX 5 |
| #define | AGGREGATED_MEMBER_REPORT_ENDPOINT_INDEX 2 |
| #define | AGGREGATED_MEMBER_REPORT_NUMBER_OF_BIT_MASKS_INDEX 3 |
| #define | AGGREGATED_MEMBER_REPORT_FIRST_BITMASK_INDEX 4 |
Functions | |
| static attribute_store_node_t | create_new_endpoint (attribute_store_node_t node_id_node, zwave_endpoint_id_t endpoint_id, bool is_aggregated) |
| Creates a new endpoint in the attribute store. More... | |
| static void | create_aggregated_endpoints (attribute_store_node_t node_id_node) |
| Creates aggregated endpoints for a Z-Wave Node. More... | |
| static void | check_if_all_individual_endpoints_are_found (attribute_store_node_t node_id_node) |
| Counts in the attribute store if the number of individual endpoints attribute matches the current list of individual endpoints. More... | |
| static sl_status_t | zwave_command_class_multi_channel_handle_endpoint_report_command (const zwave_controller_connection_info_t *connection_info, const uint8_t *frame_data, uint16_t frame_length) |
| static sl_status_t | zwave_command_class_multi_channel_handle_capability_report_command (const zwave_controller_connection_info_t *connection_info, const uint8_t *frame_data, uint16_t frame_length) |
| static sl_status_t | zwave_command_class_multi_channel_handle_endpoint_find_report_command (const zwave_controller_connection_info_t *connection_info, const uint8_t *frame_data, uint16_t frame_length) |
| static sl_status_t | zwave_command_class_multi_channel_handle_aggregated_members_report_command (const zwave_controller_connection_info_t *connection_info, const uint8_t *frame_data, uint16_t frame_length) |
| sl_status_t | zwave_command_class_multi_channel_control_handler (const zwave_controller_connection_info_t *connection_info, const uint8_t *frame_data, uint16_t frame_length) |
| static sl_status_t | zwave_command_class_multi_channel_endpoint_get (attribute_store_node_t node, uint8_t *frame, uint16_t *frame_len) |
| sl_status_t | zwave_command_class_multi_channel_capability_get (attribute_store_node_t node, uint8_t *frame, uint16_t *frame_len) |
| Resolves a Non-secure NIF for an Endpoint ID > 0. More... | |
| static sl_status_t | zwave_command_class_multi_channel_endpoint_find (attribute_store_node_t node, uint8_t *frame, uint16_t *frame_len) |
| static sl_status_t | zwave_command_class_multi_channel_aggregated_members_get (attribute_store_node_t node, uint8_t *frame, uint16_t *frame_len) |
| static void | zwave_command_class_multi_channel_on_version_attribute_update (attribute_store_node_t updated_node, attribute_store_change_t change) |
| bool | is_endpoint_aggregated (attribute_store_node_t endpoint_node) |
| Checks if an endpoints is aggregated. More... | |
| sl_status_t | zwave_command_class_multi_channel_init () |
| Initialize the Multi Channel Command Class (handler) *. More... | |
Variables | |
| static const attribute_store_type_t | v3_attributes [] |
| static const attribute_store_type_t | v4_attributes [] = {ATTRIBUTE_COMMAND_CLASS_MULTI_CHANNEL_AGGREGATED_ENDPOINTS} |
| #define AGGREGATED_MEMBER_REPORT_ENDPOINT_INDEX 2 |
| #define AGGREGATED_MEMBER_REPORT_FIRST_BITMASK_INDEX 4 |
| #define AGGREGATED_MEMBER_REPORT_NUMBER_OF_BIT_MASKS_INDEX 3 |
| #define CAPABILITY_REPORT_COMMAND_CLASS_LIST_INDEX 5 |
| #define CAPABILITY_REPORT_ENDPOINT_INDEX 2 |
| #define CAPABILITY_REPORT_ENDPOINT_LIST_INDEX 5 |
| #define CAPABILITY_REPORT_GENERIC_DEVICE_CLASS_INDEX 3 |
| #define CAPABILITY_REPORT_SPECIFIC_DEVICE_CLASS_INDEX 4 |
| #define LOG_TAG "zwave_command_class_multi_channel" |
| #define REPORT_AGGREGATED_ENDPOINTS_INDEX 4 |
| #define REPORT_IDENTICAL_ENDPOINTS_INDEX 2 |
| #define REPORT_IDENTICAL_ENDPOINTS_MASK 0x40 |
| #define REPORT_INDIVIDUAL_ENDPOINTS_INDEX 3 |
|
static |
Counts in the attribute store if the number of individual endpoints attribute matches the current list of individual endpoints.
It will write the value 1 to the ATTRIBUTE_COMMAND_CLASS_MULTI_CHANNEL_ALL_INDIVIDUAL_ENDPOINTS_FOUND attribute under endpoint 0 when it is the case.
| node_id_node | The attribute store node that represents the NodeID |
|
static |
Creates aggregated endpoints for a Z-Wave Node.
Call this function only when all the individual endpoints have been discovered. It will verify how many aggregated endpoints are reported under the endpoint 0 "number of aggregated endpoints" attribute, then create them in a consecutive range after the last individual endpoint.
| node_id_node | The attribute store node that represents the NodeID |
|
static |
Creates a new endpoint in the attribute store.
Creation will be skipped if the endpoint already exists.
| node_id_node | The attribute store node that represents the NodeID |
| endpoint_id | Endpoint ID to create for the node. |
| is_aggregated | is the endpoint aggregated? |
|
static |
| sl_status_t zwave_command_class_multi_channel_control_handler | ( | const zwave_controller_connection_info_t * | connection_info, |
| const uint8_t * | frame_data, | ||
| uint16_t | frame_length | ||
| ) |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |