IceCube display
LED display to show IceCube event data
tlv_list.h File Reference

Support for lists of type-length-value items. More...

Include dependency graph for tlv_list.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Data Structures

struct  dp_tlv_item_t
 Item in a TLV list. More...


#define TLV_TYPE_END   0xFF
#define TLV_ENTRY(type, memspace, address)   {type, sizeof(*address), memspace, address}
 Macro for TLV list item.
 Macro for last item in TLV list.


uint16_t get_tlv_list_length_P (const struct dp_tlv_item_t *tlv_data)

Detailed Description

Support for lists of type-length-value items.

Sander Vanheule (Universiteit Gent)

Macro Definition Documentation


#define TLV_TYPE_END   0xFF

Last field in TLV list with length 0. Same value as unprogrammed flash/EEPROM to lower chances of get_tlv_list_length_P() failing when it is provided with a bad pointer.

Function Documentation

◆ get_tlv_list_length_P()

uint16_t get_tlv_list_length_P ( const struct dp_tlv_item_t tlv_data)

Calculate the total length of the TLV list stored in program memory, not including a TLV_TYPE_END field.