816 B
816 B
Serial outputing API
Introduction
Shelter provide an abstraction around the serial port for outputing on it. This should act as the central point for outputing on the serial. The API is defined in shelter/lib/include/cpu/serial.h and implemented in shelter/lib/src/cpu/serial.c. This API obey the serial_port_disabled killswitch defined in kernel boot configuration. The subsystem prefix is sh_serial_.
Overview
The API define the following elements:
sh_serial_load_serial_port_setting: should be used only once at the start of the boot process to load the serial port setting using the argumentis_disabledwhich is ash_boolsh_serial_send_byte: safely (wait for previous byte to finish being send) send a byte to the serial port The default and only serial port available is COM1.