23 #ifndef ETCPAL_ACN_RLP_H_
24 #define ETCPAL_ACN_RLP_H_
29 #include "etcpal/acn_pdu.h"
30 #include "etcpal/acn_prot.h"
31 #include "etcpal/uuid.h"
50 #define ACN_TCP_PREAMBLE_SIZE 16
52 #define ACN_UDP_PREAMBLE_SIZE 16
54 #define ACN_RLP_HEADER_SIZE_NORMAL_LEN 22
56 #define ACN_RLP_HEADER_SIZE_EXT_LEN 23
64 #define ACN_VECTOR_ROOT_SDT ACN_PROTOCOL_SDT
65 #define ACN_VECTOR_ROOT_DRAFT_E131_DATA ACN_PROTOCOL_DRAFT_E131_DATA
66 #define ACN_VECTOR_ROOT_E131_DATA ACN_PROTOCOL_E131_DATA
67 #define ACN_VECTOR_ROOT_E131_EXTENDED ACN_PROTOCOL_E131_EXTENDED
68 #define ACN_VECTOR_ROOT_LLRP ACN_PROTOCOL_LLRP
69 #define ACN_VECTOR_ROOT_BROKER ACN_PROTOCOL_BROKER
70 #define ACN_VECTOR_ROOT_RPT ACN_PROTOCOL_RPT
71 #define ACN_VECTOR_ROOT_EPT ACN_PROTOCOL_EPT
bool acn_parse_root_layer_header(const uint8_t *buf, size_t buflen, AcnRootLayerPdu *pdu, AcnRootLayerPdu *last_pdu)
Parse only the header of an ACN Root Layer PDU.
Definition: acn_rlp.c:124
bool acn_parse_udp_preamble(const uint8_t *buf, size_t buflen, AcnUdpPreamble *preamble)
Parse an ACN UDP Preamble.
Definition: acn_rlp.c:92
struct AcnTcpPreamble AcnTcpPreamble
Holds the information contained in an ACN TCP Preamble.
struct AcnRootLayerPdu AcnRootLayerPdu
Holds the information contained in an ACN Root Layer PDU.
size_t acn_pack_root_layer_block(uint8_t *buf, size_t buflen, const AcnRootLayerPdu *pdu_block, size_t num_pdus)
Pack a Root Layer PDU block into a buffer.
Definition: acn_rlp.c:370
size_t acn_pack_tcp_preamble(uint8_t *buf, size_t buflen, size_t rlp_block_len)
Pack an ACN TCP Preamble into a buffer.
Definition: acn_rlp.c:281
size_t acn_root_layer_buf_size(const AcnRootLayerPdu *pdu_block, size_t num_pdus)
Get the buffer size to allocate for a Root Layer PDU block.
Definition: acn_rlp.c:304
bool acn_parse_tcp_preamble(const uint8_t *buf, size_t buflen, AcnTcpPreamble *preamble)
Parse an ACN TCP Preamble.
Definition: acn_rlp.c:66
bool acn_parse_root_layer_pdu(const uint8_t *buf, size_t buflen, AcnRootLayerPdu *pdu, AcnPdu *last_pdu)
Parse an ACN Root Layer PDU.
Definition: acn_rlp.c:223
struct AcnUdpPreamble AcnUdpPreamble
Holds the information contained in an ACN UDP Preamble.
size_t acn_pack_udp_preamble(uint8_t *buf, size_t buflen)
Pack an ACN UDP Preamble into a buffer.
Definition: acn_rlp.c:254
size_t acn_pack_root_layer_header(uint8_t *buf, size_t buflen, const AcnRootLayerPdu *pdu)
Pack only the header of a Root Layer PDU block into a buffer.
Definition: acn_rlp.c:330
Holds state data used when parsing multiple PDUs in a PDU block.
Definition: acn_pdu.h:162
Holds the information contained in an ACN Root Layer PDU.
Definition: acn_rlp.h:96
const uint8_t * pdata
A pointer to the Data segment of this PDU.
Definition: acn_rlp.h:102
EtcPalUuid sender_cid
The CID of the component that sent this Root Layer PDU.
Definition: acn_rlp.h:98
uint32_t vector
The Vector indicates the type of data contained in the Data segment.
Definition: acn_rlp.h:100
size_t data_len
The length of the Data segment of this PDU.
Definition: acn_rlp.h:104
Holds the information contained in an ACN TCP Preamble.
Definition: acn_rlp.h:78
const uint8_t * rlp_block
Pointer to the beginning of the Root Layer PDU block.
Definition: acn_rlp.h:80
size_t rlp_block_len
Length of the Root Layer PDU block.
Definition: acn_rlp.h:82
Holds the information contained in an ACN UDP Preamble.
Definition: acn_rlp.h:87
const uint8_t * rlp_block
Pointer to the beginning of the Root Layer PDU block.
Definition: acn_rlp.h:89
size_t rlp_block_len
Length of the Root Layer PDU block.
Definition: acn_rlp.h:91
The UUID type.
Definition: uuid.h:94