libosmocore 1.9.0.67-be3c3.202311292026
Osmocom core library
|
#include <soft_uart.h>
Data Fields | |
uint8_t | num_data_bits |
number of data bits (typically 5, 6, 7 or 8) More... | |
uint8_t | num_stop_bits |
number of stop bits (typically 1 or 2) More... | |
enum osmo_soft_uart_parity_mode | parity_mode |
parity mode (none, even, odd) More... | |
unsigned int | rx_buf_size |
size of receive buffer; UART will buffer up to that number of characters before calling the receive call-back More... | |
unsigned int | rx_timeout_ms |
receive timeout; UART will flush receive buffer via the receive call-back after indicated number of milliseconds even if it is not full yet More... | |
void * | priv |
opaque application-private data; passed to call-backs More... | |
void(* | rx_cb )(void *priv, struct msgb *rx_data, unsigned int flags) |
receive call-back. More... | |
void(* | tx_cb )(void *priv, struct msgb *tx_data) |
transmit call-back. More... | |
void(* | status_change_cb )(void *priv, unsigned int status) |
modem status line change call-back. More... | |
uint8_t osmo_soft_uart_cfg::num_data_bits |
number of data bits (typically 5, 6, 7 or 8)
Referenced by osmo_soft_uart_configure(), osmo_soft_uart_tx_ubits(), osmo_uart_rx_bit(), and osmo_uart_tx_bit().
uint8_t osmo_soft_uart_cfg::num_stop_bits |
number of stop bits (typically 1 or 2)
Referenced by osmo_soft_uart_configure(), osmo_soft_uart_tx_ubits(), osmo_uart_rx_bit(), and osmo_uart_tx_bit().
enum osmo_soft_uart_parity_mode osmo_soft_uart_cfg::parity_mode |
parity mode (none, even, odd)
Referenced by osmo_soft_uart_configure(), osmo_soft_uart_tx_ubits(), osmo_uart_rx_bit(), and osmo_uart_tx_bit().
void* osmo_soft_uart_cfg::priv |
opaque application-private data; passed to call-backs
Referenced by osmo_soft_uart_flush_rx(), and osmo_soft_uart_tx_ubits().
unsigned int osmo_soft_uart_cfg::rx_buf_size |
size of receive buffer; UART will buffer up to that number of characters before calling the receive call-back
Referenced by osmo_soft_uart_configure(), osmo_soft_uart_flush_rx(), osmo_soft_uart_set_rx(), and suart_rx_ch().
receive call-back.
Either rx_buf_size characters were received or rx_timeout_ms expired, or an error flag was detected (related to last byte received). 'flags' is a bit-mask of osmo_soft_uart_flags,
Referenced by osmo_soft_uart_flush_rx().
unsigned int osmo_soft_uart_cfg::rx_timeout_ms |
receive timeout; UART will flush receive buffer via the receive call-back after indicated number of milliseconds even if it is not full yet
Referenced by osmo_soft_uart_configure(), and suart_rx_ch().
void(* osmo_soft_uart_cfg::status_change_cb) (void *priv, unsigned int status) |
modem status line change call-back.
gets bitmask of osmo_soft_uart_status
transmit call-back.
The implementation is expected to provide at most tx_data->data_len characters (the actual amount is determined by the number of requested bits and the effective UART configuration).
Referenced by osmo_soft_uart_tx_ubits().