27 lines
465 B
C
27 lines
465 B
C
#pragma once
|
|
|
|
#include <tpm/TPM.h>
|
|
#include <it2s-tender/time.h>
|
|
#include <stdbool.h>
|
|
|
|
typedef enum TOLLING_PROTOCOL {
|
|
TOLLING_PROTOCOL_SIMPLE,
|
|
TOLLING_PROTOCOL_TLS
|
|
} TOLLING_PROTOCOL_e;
|
|
|
|
typedef struct tolling {
|
|
bool enabled;
|
|
TOLLING_PROTOCOL_e protocol;
|
|
|
|
// Vehicles
|
|
bool active;
|
|
uint64_t nonce;
|
|
uint64_t client_id;
|
|
|
|
uint64_t tz;
|
|
|
|
} tolling_s;
|
|
|
|
int tpm_pay(void* fc);
|
|
int tpm_recv(void* fc, TPM_t* tpm_rx, uint8_t* neighbour);
|