4#ifdef USE_PACKET_INTERFACE_HDLC
31 void setup()
override;
A reliability layer that delivers packets in order, without loss or duplicates, between two peers.
void owe_ack_(bool now)
An RR is owed: at once, or after the ack delay unless an I-frame carries it first.
HdlcReliability(PacketInterface *lower)
size_t get_send_capacity() const override
No room while the layer has no send queue: before setup(), or when setup() failed.
void set_ack_delay(uint32_t ack_delay_ms)
void dump_config() override
void set_max_queue_length(uint8_t length)
@ LINK_STATE_RESET_PENDING
void resend_outstanding_()
uint8_t * slot_(uint8_t seq)
void set_ack_timeout(uint32_t timeout_ms)
std::array< uint16_t, MAX_WINDOW > tx_lengths_
void receive_info_(uint8_t control, const uint8_t *payload, size_t length, const PacketMetaData &meta_data)
bool send_frame_(uint8_t control, const uint8_t *payload, size_t length)
uint8_t slot_index_(uint8_t seq) const
static constexpr uint8_t MAX_WINDOW
Most frames that can be unacknowledged at once, set by the 3 bit sequence numbers.
bool send_supervisory_(uint8_t type)
void process_ack_(uint8_t nr)
uint8_t max_queue_length_
uint8_t outstanding_() const
bool send_to_interface(const PacketBuffer &data, const PacketMetaData &meta_data) override
void receive_(const PacketBuffer &data, const PacketMetaData &meta_data)
static constexpr size_t FRAME_OVERHEAD
Control byte plus CRC-16.
bool is_connected() const
void set_max_retries(uint8_t retries)
A buffer class that efficiently represents a composite buffer with three sections:
A class that will transport data to and from an abstract channel.
const size_t max_packet_size_