NSDL C library

Dependents:   NSDL_HelloWorld_WiFi UbloxModemNanoServiceClient IOT-NSDL_HelloWorld LWM2M_NanoService_Ethernet ... more

Fork of nsdl_lib by Tero Heinonen

Embed: (wiki syntax)

« Back to documentation index

sn_coap_hdr_ Struct Reference

sn_coap_hdr_ Struct Reference

Main CoAP message struct. More...

#include <sn_coap_header.h>

Data Fields

sn_coap_status_e coap_status
 Used for telling to User special cases when parsing message.
sn_coap_msg_type_e msg_type
 Confirmable, Non-Confirmable, Acknowledgement or Reset.
sn_coap_msg_code_e msg_code
 Empty: 0; Requests: 1-31; Responses: 64-191.
uint16_t msg_id
 Message ID.
uint16_t uri_path_len
 0-255 bytes.
uint8_t * uri_path_ptr
 Must be set to NULL if not used.
uint8_t token_len
 1-8 bytes.
uint8_t * token_ptr
 Must be set to NULL if not used.
uint8_t content_type_len
 0-2 bytes.
uint8_t * content_type_ptr
 Must be set to NULL if not used.
sn_coap_options_list_soptions_list_ptr
 Must be set to NULL if not used.
uint16_t payload_len
 Must be set to zero if not used.
uint8_t * payload_ptr
 Must be set to NULL if not used.

Detailed Description

Main CoAP message struct.

Definition at line 193 of file sn_coap_header.h.


Field Documentation

Used for telling to User special cases when parsing message.

Definition at line 195 of file sn_coap_header.h.

0-2 bytes.

Definition at line 217 of file sn_coap_header.h.

uint8_t* content_type_ptr

Must be set to NULL if not used.

Definition at line 218 of file sn_coap_header.h.

Empty: 0; Requests: 1-31; Responses: 64-191.

Definition at line 202 of file sn_coap_header.h.

uint16_t msg_id

Message ID.

Parser sets parsed message ID, builder sets message ID of built coap message

Definition at line 203 of file sn_coap_header.h.

Confirmable, Non-Confirmable, Acknowledgement or Reset.

Definition at line 201 of file sn_coap_header.h.

Must be set to NULL if not used.

Definition at line 221 of file sn_coap_header.h.

uint16_t payload_len

Must be set to zero if not used.

Definition at line 227 of file sn_coap_header.h.

uint8_t* payload_ptr

Must be set to NULL if not used.

Definition at line 228 of file sn_coap_header.h.

uint8_t token_len

1-8 bytes.

Definition at line 214 of file sn_coap_header.h.

uint8_t* token_ptr

Must be set to NULL if not used.

Definition at line 215 of file sn_coap_header.h.

uint16_t uri_path_len

0-255 bytes.

Repeatable.

Definition at line 211 of file sn_coap_header.h.

uint8_t* uri_path_ptr

Must be set to NULL if not used.

E.g: temp1/temp2

Definition at line 212 of file sn_coap_header.h.