Skip to content

Struct baton_link

ClassList > baton_link

Link state. More...

  • #include <baton_link.h>

Public Attributes

Type Name
struct baton_link_config config
Copy of the configuration.
struct baton_link_counters counters
Diagnostic counters.
bool echo_error
An echo byte did not match.
uint16_t echo_index
Echo bytes already compared.
uint32_t last_rx_ms
Last byte received from another node (fed to the parser).
uint32_t last_tx_end_ms
End of the last transmission.
struct baton_parser parser
Receive stream parser.
volatile uint8_t rx_buffer
Receive ring (interrupt producer).
volatile uint16_t rx_head
Next write position (interrupt).
volatile uint32_t rx_overflows
Bytes lost because the ring was full.
volatile uint16_t rx_tail
Next read position (process).
const uint8_t * tx_data
Frame being transmitted.
volatile bool tx_done_flag
Set by baton_link_tx_done_isr() .
uint16_t tx_length
Length of tx_data.
uint32_t tx_start_ms
Start of the current transmission.
uint8_t tx_state
Idle, waiting for a silent bus, or busy.

Detailed Description

Treat the members as private; use the functions below.

Public Attributes Documentation

variable config

Copy of the configuration.

struct baton_link_config baton_link::config;


variable counters

Diagnostic counters.

struct baton_link_counters baton_link::counters;


variable echo_error

An echo byte did not match.

bool baton_link::echo_error;


variable echo_index

Echo bytes already compared.

uint16_t baton_link::echo_index;


variable last_rx_ms

Last byte received from another node (fed to the parser).

uint32_t baton_link::last_rx_ms;


variable last_tx_end_ms

End of the last transmission.

uint32_t baton_link::last_tx_end_ms;


variable parser

Receive stream parser.

struct baton_parser baton_link::parser;


variable rx_buffer

Receive ring (interrupt producer).

volatile uint8_t baton_link::rx_buffer[BATON_RX_BUF_SIZE];


variable rx_head

Next write position (interrupt).

volatile uint16_t baton_link::rx_head;


variable rx_overflows

Bytes lost because the ring was full.

volatile uint32_t baton_link::rx_overflows;


variable rx_tail

Next read position (process).

volatile uint16_t baton_link::rx_tail;


variable tx_data

Frame being transmitted.

const uint8_t* baton_link::tx_data;


variable tx_done_flag

Set by baton_link_tx_done_isr() .

volatile bool baton_link::tx_done_flag;


variable tx_length

Length of tx_data.

uint16_t baton_link::tx_length;


variable tx_start_ms

Start of the current transmission.

uint32_t baton_link::tx_start_ms;


variable tx_state

Idle, waiting for a silent bus, or busy.

uint8_t baton_link::tx_state;



The documentation for this class was generated from the following file inc/baton_link.h