Infuse-IoT SDK API
0.0.1
A Scalable Open Source RTOS
Loading...
Searching...
No Matches
common.h
Go to the documentation of this file.
1
9
10
#ifndef INFUSE_SDK_INCLUDE_INFUSE_EPACKET_INTERFACE_COMMON_H_
11
#define INFUSE_SDK_INCLUDE_INFUSE_EPACKET_INTERFACE_COMMON_H_
12
13
#include <stdint.h>
14
15
#ifdef __cplusplus
16
extern
"C"
{
17
#endif
18
25
27
struct
epacket_v0_versioned_frame_format
{
28
union
{
29
struct
{
31
uint8_t
version
;
33
uint8_t
type
;
35
uint16_t
flags
;
37
uint8_t
key_identifier
[3];
39
uint32_t
device_id_upper
;
40
} __packed;
42
uint8_t
raw
[11];
43
}
associated_data
;
44
union
{
45
struct
{
47
uint32_t
device_id_lower
;
49
uint32_t
gps_time
;
51
uint16_t
sequence
;
53
uint16_t
entropy
;
54
} __packed;
56
uint8_t
raw
[12];
57
}
nonce
;
59
uint8_t
ciphertext_tag
[];
60
} __packed;
61
63
struct
epacket_v0_unversioned_frame_format
{
64
union
{
65
struct
{
67
uint8_t
type
;
69
uint16_t
flags
;
71
uint8_t
key_identifier
[3];
73
uint32_t
device_id_upper
;
74
} __packed;
76
uint8_t
raw
[10];
77
}
associated_data
;
78
union
{
79
struct
{
81
uint32_t
device_id_lower
;
83
uint32_t
gps_time
;
85
uint16_t
sequence
;
87
uint16_t
entropy
;
88
} __packed;
90
uint8_t
raw
[12];
91
}
nonce
;
93
uint8_t
ciphertext_tag
[];
94
} __packed;
95
99
100
#ifdef __cplusplus
101
}
102
#endif
103
104
#endif
/* INFUSE_SDK_INCLUDE_INFUSE_EPACKET_INTERFACE_COMMON_H_ */
epacket_v0_unversioned_frame_format
Unversioned data frame.
Definition
common.h:63
epacket_v0_unversioned_frame_format::associated_data
union epacket_v0_unversioned_frame_format::@272204106316167027063363310250142276302305161326 associated_data
AEAD associated data.
epacket_v0_unversioned_frame_format::key_identifier
uint8_t key_identifier[3]
Network or device key identifier.
Definition
common.h:71
epacket_v0_unversioned_frame_format::device_id_lower
uint32_t device_id_lower
Infuse device ID (lower 4 bytes)
Definition
common.h:81
epacket_v0_unversioned_frame_format::entropy
uint16_t entropy
Random entropy.
Definition
common.h:87
epacket_v0_unversioned_frame_format::gps_time
uint32_t gps_time
Local GPS time (seconds)
Definition
common.h:83
epacket_v0_unversioned_frame_format::ciphertext_tag
uint8_t ciphertext_tag[]
Ciphertext + tag bytes.
Definition
common.h:93
epacket_v0_unversioned_frame_format::type
uint8_t type
Payload type.
Definition
common.h:67
epacket_v0_unversioned_frame_format::flags
uint16_t flags
Payload flags.
Definition
common.h:69
epacket_v0_unversioned_frame_format::raw
uint8_t raw[10]
Raw associated data bytes.
Definition
common.h:76
epacket_v0_unversioned_frame_format::device_id_upper
uint32_t device_id_upper
Infuse device ID (upper 4 bytes)
Definition
common.h:73
epacket_v0_unversioned_frame_format::nonce
union epacket_v0_unversioned_frame_format::@303215267266307153371221101153320020155042206255 nonce
AEAD encryption nonce (IV)
epacket_v0_unversioned_frame_format::sequence
uint16_t sequence
Packet sequence number.
Definition
common.h:85
epacket_v0_versioned_frame_format
Versioned data frame.
Definition
common.h:27
epacket_v0_versioned_frame_format::raw
uint8_t raw[11]
Raw associated data bytes.
Definition
common.h:42
epacket_v0_versioned_frame_format::flags
uint16_t flags
Payload flags.
Definition
common.h:35
epacket_v0_versioned_frame_format::gps_time
uint32_t gps_time
Local GPS time (seconds)
Definition
common.h:49
epacket_v0_versioned_frame_format::key_identifier
uint8_t key_identifier[3]
Network or device key identifier.
Definition
common.h:37
epacket_v0_versioned_frame_format::device_id_upper
uint32_t device_id_upper
Infuse device ID (upper 4 bytes)
Definition
common.h:39
epacket_v0_versioned_frame_format::type
uint8_t type
Payload type.
Definition
common.h:33
epacket_v0_versioned_frame_format::version
uint8_t version
Frame version.
Definition
common.h:31
epacket_v0_versioned_frame_format::nonce
union epacket_v0_versioned_frame_format::@133066105073167256262160014315265142232335102045 nonce
AEAD encryption nonce (IV)
epacket_v0_versioned_frame_format::associated_data
union epacket_v0_versioned_frame_format::@165022206334351152251361054230316307167157377361 associated_data
AEAD associated data.
epacket_v0_versioned_frame_format::entropy
uint16_t entropy
Random entropy.
Definition
common.h:53
epacket_v0_versioned_frame_format::ciphertext_tag
uint8_t ciphertext_tag[]
Ciphertext + tag bytes.
Definition
common.h:59
epacket_v0_versioned_frame_format::sequence
uint16_t sequence
Packet sequence number.
Definition
common.h:51
epacket_v0_versioned_frame_format::device_id_lower
uint32_t device_id_lower
Infuse device ID (lower 4 bytes)
Definition
common.h:47
infuse
epacket
interface
common.h
Generated on
for Infuse-IoT SDK API by
1.14.0