Files | Data Structures | Typedefs | Enumerations | Functions
Cayenna LPP Serializer

Interface header file for the Cayenne LPP Serializer feature. More...

+ Collaboration diagram for Cayenna LPP Serializer:


file  XDK_CayenneLPPSerializer.h

Data Structures

union  CayenneLPPSerializer_Data_U
 Union to represent the supported Data payloads for Cayenne LPP. More...
struct  CayenneLPPSerializer_Input_S
 Structure to represent the Input payload informations for serialization. More...
struct  CayenneLPPSerializer_Output_S
 Structure to represent the Output payload informations after serialization. More...


typedef union
 Typedef to represent the supported Data payload for Cayenne LPP. More...
typedef enum
 Typedef to represent the supported Data Type for Cayenne LPP. More...
typedef struct
 Typedef to represent the Input payload information for serialization. More...
typedef struct
 Typedef to represent the Output payload information after serialization. More...


enum  CayenneLPPSerializer_DataType_E
 Enum to represent the supported Data Types for Cayenne LPP. More...


struct {
   uint8_t   DigitalInputValue
__attribute__ ((packed)) DigitalInput
Retcode_T CayenneLPPSerializer_SingleInstance (CayenneLPPSerializer_Input_T *input, CayenneLPPSerializer_Output_T *output)
 This will serialize the payload for single instance (only one data point per payload) More...

Detailed Description

The Cayenne Low Power Payload (LPP) provides a convenient and easy way to send data over LPWAN networks such as LoRaWAN. The Cayenne LPP is compliant with the payload size restriction, which can be lowered down to 11 bytes, and allows the device to send multiple sensor data at one time.

Additionally, the Cayenne LPP allows the device to send different sensor data in different frames. In order to do that, each sensor data must be prefixed with two bytes:

Payload structure 1 Byte 1 Byte N Bytes 1 Byte 1 Byte M Bytes ... Data1 Ch. Data1 Type Data1 Data2 Ch. Data2 Type Data2 ...

Type IPSO LPP Hex Data Size Data Resolution per bit Digital Input 3200 0 0 1 1 Digital Output 3201 1 1 1 1 Analog Input 3202 2 2 2 0.01 Signed Analog Output 3203 3 3 2 0.01 Signed Illuminance Sensor 3301 101 65 2 1 Lux Unsigned MSB Presence Sensor 3302 102 66 1 1 Temperature Sensor 3303 103 67 2 0.1 °C Signed MSB Humidity Sensor 3304 104 68 1 0.5 % Unsigned Accelerometer 3313 113 71 6 0.001 G Signed MSB per axis Barometer 3315 115 73 2 0.1 hPa Unsigned MSB Gyrometer 3334 134 86 6 0.01 °/s Signed MSB per axis GPS Location 3336 136 88 9 Latitude : 0.0001 ° Signed MSB Longitude : 0.0001 ° Signed MSB Altitude : 0.01 meter Signed MSB

So for single instance serializer, the output payload size is two bytes in addition to the Data Size.

Data Structure Documentation

union CayenneLPPSerializer_Data_U

Public Member Functions

struct {
   uint8_t   DigitalInputValue
__attribute__ ((packed)) DigitalInput
struct {
   signed   Altitude:24
   signed   Latitude:24
   signed   Longitude:24
__attribute__ ((packed)) GPSLocation
struct {
   int16_t   GyrometerXValue
   int16_t   GyrometerYValue
   int16_t   GyrometerZValue
__attribute__ ((packed)) Gyrometer
struct {
   uint16_t   BarometerValue
__attribute__ ((packed)) Barometer
struct {
   int16_t   AccelerometerXValue
   int16_t   AccelerometerYValue
   int16_t   AccelerometerZValue
__attribute__ ((packed)) Accelerometer
struct {
   uint8_t   HumiditySensorValue
__attribute__ ((packed)) HumiditySensor
struct {
   int16_t   TemperatureSensorValue
__attribute__ ((packed)) TemperatureSensor
struct {
   uint8_t   PresenceSensorValue
__attribute__ ((packed)) PresenceSensor
struct {
   uint16_t   IlluminanceSensorValue
__attribute__ ((packed)) IlluminanceSensor
struct {
   int16_t   AnalogOutputValue
__attribute__ ((packed)) AnalogOutput
struct {
   int16_t   AnalogInputValue
__attribute__ ((packed)) AnalogInput
struct {
   uint8_t   DigitalOutputValue
__attribute__ ((packed)) DigitalOutput

Member Function Documentation

struct CayenneLPPSerializer_Data_U::@11 __attribute__ ( (packed)  )
struct CayenneLPPSerializer_Data_U::@10 __attribute__ ( (packed)  )
struct CayenneLPPSerializer_Data_U::@9 __attribute__ ( (packed)  )
struct CayenneLPPSerializer_Data_U::@8 __attribute__ ( (packed)  )
struct CayenneLPPSerializer_Data_U::@7 __attribute__ ( (packed)  )
struct CayenneLPPSerializer_Data_U::@6 __attribute__ ( (packed)  )
struct CayenneLPPSerializer_Data_U::@5 __attribute__ ( (packed)  )
struct CayenneLPPSerializer_Data_U::@4 __attribute__ ( (packed)  )
struct CayenneLPPSerializer_Data_U::@3 __attribute__ ( (packed)  )
struct CayenneLPPSerializer_Data_U::@2 __attribute__ ( (packed)  )
struct CayenneLPPSerializer_Data_U::@1 __attribute__ ( (packed)  )

Field Documentation

int16_t AccelerometerXValue
int16_t AccelerometerYValue
int16_t AccelerometerZValue
signed Altitude
int16_t AnalogInputValue
int16_t AnalogOutputValue
uint16_t BarometerValue
uint8_t DigitalInputValue
uint8_t DigitalOutputValue
int16_t GyrometerXValue
int16_t GyrometerYValue
int16_t GyrometerZValue
uint8_t HumiditySensorValue
uint16_t IlluminanceSensorValue
signed Latitude
signed Longitude
uint8_t PresenceSensorValue
int16_t TemperatureSensorValue
struct CayenneLPPSerializer_Input_S
+ Collaboration diagram for CayenneLPPSerializer_Input_S:

Data Fields

CayenneLPPSerializer_Data_T Data
uint8_t DataChannel
CayenneLPPSerializer_DataType_T DataType

Field Documentation

uint8_t DataChannel
struct CayenneLPPSerializer_Output_S

Data Fields

uint32_t BufferFilledLength
uint32_t BufferLength
uint8_t * BufferPointer

Field Documentation

uint32_t BufferFilledLength
uint32_t BufferLength
uint8_t* BufferPointer

Typedef Documentation

Enumeration Type Documentation


Function Documentation

struct CayenneLPPSerializer_Data_U::@0 __attribute__ ( (packed)  )
Retcode_T CayenneLPPSerializer_SingleInstance ( CayenneLPPSerializer_Input_T input,
CayenneLPPSerializer_Output_T output 
[in]inputInput payload information for serialization.
in/out]output Output payload information for and after serialization.
RETCODE_OK on success, or an error code otherwise.
  • The maximum output->BufferFilledLength that a single instance serialized will utilize is a maximum of 11 bytes.

Refer interface header for description

+ Here is the caller graph for this function:

Variable Documentation

uint8_t DigitalInputValue

This documentation file has been automatically generated on Fri Oct 4 2019 03:47:34 by doxygen 1.8.8