|
libosmocore
0.9.6.241-b6c8
Osmocom core library
|
Files | |
| file | serial.h |
| file | serial.c |
Macros | |
| #define | dbg_perror(x) do { } while (0) |
Functions | |
| int | osmo_serial_init (const char *dev, speed_t baudrate) |
| Open serial device and does base init. More... | |
| int | osmo_serial_set_baudrate (int fd, speed_t baudrate) |
| Change current baudrate. More... | |
| int | osmo_serial_set_custom_baudrate (int fd, int baudrate) |
| Change current baudrate to a custom one using OS specific method. More... | |
| int | osmo_serial_clear_custom_baudrate (int fd) |
| Clear any custom baudrate. More... | |
| static int | _osmo_serial_set_baudrate (int fd, speed_t baudrate) |
| int osmo_serial_clear_custom_baudrate | ( | int | fd | ) |
Clear any custom baudrate.
| [in] | fd | File descriptor of the open device |
This function might not work on all OS or with all type of serial adapters
Referenced by osmo_serial_set_baudrate().
| int osmo_serial_init | ( | const char * | dev, |
| speed_t | baudrate | ||
| ) |
Open serial device and does base init.
| [in] | dev | Path to the device node to open |
| [in] | baudrate | Baudrate constant (speed_t: B9600, B...) |
| int osmo_serial_set_baudrate | ( | int | fd, |
| speed_t | baudrate | ||
| ) |
Change current baudrate.
| [in] | fd | File descriptor of the open device |
| [in] | baudrate | Baudrate constant (speed_t: B9600, B...) |
References osmo_serial_clear_custom_baudrate().
| int osmo_serial_set_custom_baudrate | ( | int | fd, |
| int | baudrate | ||
| ) |
Change current baudrate to a custom one using OS specific method.
| [in] | fd | File descriptor of the open device |
| [in] | baudrate | Baudrate as integer |
This function might not work on all OS or with all type of serial adapters