Struct baton_node_config¶
Node configuration passed to baton_node_init ; copied.More...
#include <baton_node.h>
Public Attributes¶
| Type | Name |
|---|---|
| uint16_t | ack_timeout_ms Wait for an ACK after a DATA frame. |
| uint32_t | baudrate Bit rate, used to compute frame durations. |
| void * | context Passed to every hook and callback. |
| uint16_t | cycle_period_ms Master: shortest time between cycle starts (0 = back to back). |
| baton_critical_fn | enter_critical Disable the UART interrupt (or all interrupts). |
| uint32_t | event_ttl_ms An undelivered event is dropped after this (0 = never). |
| baton_critical_fn | exit_critical Restore it. |
| uint8_t | inter_byte_timeout_ms Silence that aborts a partially received frame. |
| uint8_t | master_address Address of the master. |
| uint8_t | max_retries DATA retransmissions per slot (0 = none). |
| baton_drop_fn | on_drop An event expired. |
| baton_message_fn | on_message A message was received. |
| baton_poll_done_fn | on_poll_done Master: a slot finished. |
| uint8_t | own_address Address of this node (master: master_address). |
| uint8_t | role BATON_ROLE_MASTER or BATON_ROLE_SLAVE. |
| bool | rx_echo true: the UART receives its own bytes (single wire); false: call baton_node_tx_done_isr() . |
| const uint8_t * | slave_addresses Slaves in polling order, identical on every node. |
| uint8_t | slave_count 1..BATON_MAX_NODES - 1. |
| uint16_t | slot_time_ms Longest time a slave owns the bus after a POLL. |
| uint8_t | tx_gap_ms Bus silence required before transmitting. |
| baton_write_fn | write Starts a non-blocking transmission (required). |
Detailed Description¶
Node mask convention: bit 0 = master, bit i (i >= 1) = slave_addresses[i - 1].
Public Attributes Documentation¶
variable ack_timeout_ms¶
Wait for an ACK after a DATA frame.
variable baudrate¶
Bit rate, used to compute frame durations.
variable context¶
Passed to every hook and callback.
variable cycle_period_ms¶
Master: shortest time between cycle starts (0 = back to back).
variable enter_critical¶
Disable the UART interrupt (or all interrupts).
variable event_ttl_ms¶
An undelivered event is dropped after this (0 = never).
variable exit_critical¶
Restore it.
variable inter_byte_timeout_ms¶
Silence that aborts a partially received frame.
variable master_address¶
Address of the master.
variable max_retries¶
DATA retransmissions per slot (0 = none).
variable on_drop¶
An event expired.
variable on_message¶
A message was received.
variable on_poll_done¶
Master: a slot finished.
variable own_address¶
Address of this node (master: master_address).
variable role¶
BATON_ROLE_MASTER or BATON_ROLE_SLAVE.
variable rx_echo¶
true: the UART receives its own bytes (single wire); false: call baton_node_tx_done_isr() .
variable slave_addresses¶
Slaves in polling order, identical on every node.
variable slave_count¶
1..BATON_MAX_NODES - 1.
variable slot_time_ms¶
Longest time a slave owns the bus after a POLL.
variable tx_gap_ms¶
Bus silence required before transmitting.
variable write¶
Starts a non-blocking transmission (required).
The documentation for this class was generated from the following file inc/baton_node.h