tinyproto
|
Structure describes configuration of lowest HDLC level Initialize this structure by 0 before passing to hdlc_ll_init() function. More...
#include <hdlc.h>
Public Attributes | |
on_frame_cb_t | on_frame_read |
User-defined callback, which is called when new packet arrives from hw channel. More... | |
on_tx_frame_cb_t | on_frame_send |
User-defined callback, which is called when the packet is sent to TX channel. More... | |
void * | buf |
Buffer to be used by hdlc level to receive data to. More... | |
int | buf_size |
size of hdlc buffer | |
hdlc_crc_t | crc_type |
crc field type to use on hdlc level. More... | |
void * | user_data |
User data, which will be passed to user-defined callback as first argument. | |
int | mtu |
mtu size, can be 0 | |
Structure describes configuration of lowest HDLC level Initialize this structure by 0 before passing to hdlc_ll_init() function.
void* hdlc_ll_init_t::buf |
Buffer to be used by hdlc level to receive data to.
Use hdlc_ll_get_buf_size() to calculate minimum buffer size.
hdlc_crc_t hdlc_ll_init_t::crc_type |
crc field type to use on hdlc level.
If HDLC_CRC_DEFAULT is passed, crc type will be selected automatically (depending on library configuration), but HDLC_CRC_16 has higher priority.
on_frame_cb_t hdlc_ll_init_t::on_frame_read |
User-defined callback, which is called when new packet arrives from hw channel.
The context of this callback is context, where hdlc_ll_run_rx() is called from.
user_data | user-defined data |
data | pointer to received data |
len | size of received data in bytes |
on_tx_frame_cb_t hdlc_ll_init_t::on_frame_send |
User-defined callback, which is called when the packet is sent to TX channel.
The context of this callback is context, where hdlc_ll_run_tx() is called from.
user_data | user-defined data |
data | pointer to sent data |
len | size of sent data in bytes |