Serial Drivers¶
A serial driver provides a means of outputting bytes of data via a serial port. A higher-level system component, e.g., a console, uses serial line operations to communicate with a serial driver.
Serial Drivers provided by tomOSii¶
Datatypes Provided for the Serial Drivers¶
Serial Line¶
-
struct serial_line_t¶
Information regarding a serial line.
Public Members
-
serial_line_operations_t *sl_ops¶
The serial line operations implemented by the driver.
-
uint16_t port¶
The port number of the serial port, e.g., SL_COM1.
-
uint16_t baud_rate¶
The baud rate for the serial port, i.e., SL_9600_BAUD.
-
serial_line_operations_t *sl_ops¶
Serial Line Operations¶
The interface between higher-level system components like a console and the serial line driver.
-
struct serial_line_operations_t¶
Callbacks provided by serial line drivers.
These callbacks provide a higher-level driver, e.g., a console, with access to lower-level hardware via a common interface. The callbacks have to be implemented by a serial line driver.
Public Members
-
int (*sl_open)(serial_line_t *sl)¶
Open the serial line specified in
sl.
-
int (*sl_putc)(serial_line_t *sl, char c)¶
Emit one byte
cto the serial linesl.
-
int (*sl_open)(serial_line_t *sl)¶