Hazelnet 3.0.0
Reference implementation of the CAN Bus Security (CBS) protocol
Data Fields
hzl_ClientCtx Struct Reference

Configuration and status of the HazelNet Client library. More...

#include <hzl_Client.h>

Collaboration diagram for hzl_ClientCtx:
Collaboration graph
[legend]

Data Fields

HZL_SET_BY_USER const hzl_ClientConfig_tclientConfig
 Pointer to one struct with the constant Client configuration. More...
 
HZL_SET_BY_USER const hzl_ClientGroupConfig_tgroupConfigs
 Pointer to an array of structs, each with the constant configuration of one Group. More...
 
HZL_SET_BY_USER hzl_ClientGroupState_tgroupStates
 Pointer to an array of structs, each with the variable state of one Group. More...
 
HZL_SET_BY_USER hzl_Io_t io
 Set of function pointers binding the API to the rest of the system. More...
 

Detailed Description

Configuration and status of the HazelNet Client library.

Initialised by the user on embedded, loaded from file on an OS.

Field Documentation

◆ clientConfig

HZL_SET_BY_USER const hzl_ClientConfig_t* hzl_ClientCtx::clientConfig

Pointer to one struct with the constant Client configuration.

Set by the user to point to a valid configuration. Must be not NULL.

◆ groupConfigs

HZL_SET_BY_USER const hzl_ClientGroupConfig_t* hzl_ClientCtx::groupConfigs

Pointer to an array of structs, each with the constant configuration of one Group.

The array must contain hzl_ClientConfig_t.amountOfGroups elements (structs). Set by the user to point to a valid configuration. Must be not NULL.

Constraints:

  • structs must be sorted by the gid field strictly ascending without repetition
  • the first struct (at index 0) must always be with gid == 0
  • the array must contain at least one struct (thus the one with gid == 0)

◆ groupStates

HZL_SET_BY_USER hzl_ClientGroupState_t* hzl_ClientCtx::groupStates

Pointer to an array of structs, each with the variable state of one Group.

Set by the user to point to a memory location, does not have to be initialised. The Client handles the initialisation on init and clears it at deinit. Must be not NULL.

The array must contain hzl_ClientConfig_t.amountOfGroups elements (structs), which will be indexed in the same was as in the groupConfigs array; i.e. groupConfigs[i] and groupStates[i] are respectively the configuration and state of the same group, for every i.

◆ io

HZL_SET_BY_USER hzl_Io_t hzl_ClientCtx::io

Set of function pointers binding the API to the rest of the system.

Including random number generation, timestamp generation and message transmission.


The documentation for this struct was generated from the following file: