This module performs serial input/output functionalities via USB.
Functions | |
void | dtr_cb (bool) |
This function is callled with the value set as true whenever a device is connected to the terminal. More... | |
uint8_t | sio2host_getchar (void) |
This function performs a blocking character receive functionality. More... | |
int | sio2host_getchar_nowait (void) |
This function performs a non-blocking character receive functionality. More... | |
void | sio2host_init (void) |
Initializes the Serial IO Module of the Host Device. More... | |
void | sio2host_putchar (uint8_t) |
uint8_t | sio2host_rx (uint8_t *data, uint8_t max_length) |
Receives data from USB. More... | |
uint8_t | sio2host_tx (uint8_t *data, uint8_t length) |
Transmits data via USB. More... | |
void | usb_rx_notify (void) |
This function is called by the USB data receive Interrupt The Receive buffer is filled in this function. More... | |
void dtr_cb | ( | bool | ) |
This function is callled with the value set as true whenever a device is connected to the terminal.
References stdio_usb_disable(), and stdio_usb_enable().
uint8_t sio2host_getchar | ( | void | ) |
This function performs a blocking character receive functionality.
References sio2host_rx().
int sio2host_getchar_nowait | ( | void | ) |
This function performs a non-blocking character receive functionality.
References sio2host_rx().
Referenced by range_test_tx_off_task(), and range_test_tx_on_task().
void sio2host_init | ( | void | ) |
Initializes the Serial IO Module of the Host Device.
References stdio_usb_init().
Referenced by performance_analyzer_init().
void sio2host_putchar | ( | uint8_t | ) |
References sio2host_tx().
uint8_t sio2host_rx | ( | uint8_t * | data, |
uint8_t | max_length | ||
) |
Receives data from USB.
data | pointer to the buffer where the received data is to be stored |
max_length | maximum length of data to be received |
References serial_rx_buf, serial_rx_buf_head, SERIAL_RX_BUF_SIZE_HOST, serial_rx_buf_tail, and serial_rx_count.
Referenced by serial_data_handler(), sio2host_getchar(), and sio2host_getchar_nowait().
uint8_t sio2host_tx | ( | uint8_t * | data, |
uint8_t | length | ||
) |
Transmits data via USB.
data | Pointer to the buffer where the data to be transmitted is present |
length | Number of bytes to be transmitted |
References udi_cdc_putc().
Referenced by serial_data_handler(), and sio2host_putchar().
void usb_rx_notify | ( | void | ) |
This function is called by the USB data receive Interrupt The Receive buffer is filled in this function.
References cpu_irq_disable, cpu_irq_enable, main_b_cdc_enable, serial_rx_buf, SERIAL_RX_BUF_SIZE_HOST, serial_rx_buf_tail, serial_rx_count, udi_cdc_getc(), and udi_cdc_is_rx_ready().