Z-Wave Protocol Controller Reference
zwave_crc16_transport.h
Go to the documentation of this file.
1/******************************************************************************
2 * # License
3 * <b>Copyright 2024 Silicon Laboratories Inc. www.silabs.com</b>
4 ******************************************************************************
5 * The licensor of this software is Silicon Laboratories Inc. Your use of this
6 * software is governed by the terms of Silicon Labs Master Software License
7 * Agreement (MSLA) available at
8 * www.silabs.com/about-us/legal/master-software-license-agreement. This
9 * software is distributed to you in Source Code format and is governed by the
10 * sections of the MSLA applicable to Source Code.
11 *
12 *****************************************************************************/
13
22#ifndef ZWAVE_CRC_16_TRANSPORT_H
23#define ZWAVE_CRC_16_TRANSPORT_H
24
25#include "sl_status.h"
27
28// We allow to encapsulate the maximum minus our encapsulation command overhead
29#define CRC_16_ENCAPSULATION_HEADER 2
30#define CRC_16_ENCAPSULATION_FOOTER 2
31#define CRC_16_ENCAPSULATION_OVERHEAD (CRC_16_ENCAPSULATION_HEADER + CRC_16_ENCAPSULATION_FOOTER)
32
33#define CRC_16_ENCAPSULATED_COMMAND_MAXIMUM_SIZE \
34 (ZWAVE_MAX_FRAME_SIZE - CRC_16_ENCAPSULATION_OVERHEAD)
35
37 uint8_t command_class; /* The command class */
38 uint8_t command; /* The command */
40 [CRC_16_ENCAPSULATED_COMMAND_MAXIMUM_SIZE]; /* The checksum will be appended to the command*/
41/* Encapsulated command */
43
44#ifdef __cplusplus
45extern "C" {
46#endif
47
55
56#ifdef __cplusplus
57}
58#endif
59
60#endif //ZWAVE_CRC_16_TRANSPORT_H
uint32_t sl_status_t
Definition: sl_status.h:139
#define CRC_16_ENCAPSULATED_COMMAND_MAXIMUM_SIZE
Definition: zwave_crc16_transport.h:33
sl_status_t zwave_crc16_transport_init(void)
Initialize the CRC16 Transport *.
Definition: zwave_crc16_transport.c:356
struct zwave_crc16_encapsulation_frame zwave_crc16_encapsulation_frame_t
SL Status Codes.
Definition: zwave_crc16_transport.h:36
uint8_t command
Definition: zwave_crc16_transport.h:38
uint8_t encapsulated_command[CRC_16_ENCAPSULATED_COMMAND_MAXIMUM_SIZE]
Definition: zwave_crc16_transport.h:40
uint8_t command_class
Definition: zwave_crc16_transport.h:37