evk_uart.h
This module controls UART features of SPARK EVK board.
- Copyright
Copyright (C) 2026 SPARK Microsystems International Inc. All rights reserved.
- License
This source code is proprietary and subject to the SPARK Microsystems Software EULA found in this package in file EULA.txt.
- Author
SPARK FW Team.
Functions
-
void evk_exp_uart_init(void)
Initialize the UART bus connected to the expansion board.
-
void evk_exp_lpuart_init(void)
Initialize the low power UART bus connected to the expansion board.
-
void evk_exp_lpuart_update_config(void)
Update the configuration of the low power UART, useful when clock changes.
-
void evk_uart_debug_read_blocking(uint8_t *data, uint16_t size, uint32_t timeout_ms)
Read data on the LPUART which is on the expansion board.
- Parameters:
data – [in] Data buffer to write.
size – [in] Size of the data to write.
timeout_ms – [in] The amount of milliseconds before timeout.
-
void evk_uart_debug_write_blocking(uint8_t *data, uint16_t size, uint32_t timeout_ms)
Write data on the debug UART.
- Parameters:
data – [in] Data buffer to write.
size – [in] Size of the data to write.
timeout_ms – [in] The amount of milliseconds before timeout.
-
void evk_uart_debug_write_non_blocking(uint8_t *data, uint16_t size)
Write data on the debug UART in non blocking mode.
- Parameters:
data – [in] Data buffer to write.
size – [in] Size of the data to write.
-
void evk_uart_debug_read_byte_non_blocking(uint8_t *data)
Read byte on the debug UART in non blocking mode.
- Parameters:
data – [in] Data byte to write.
-
void evk_uart_debug_set_tx_callback(void (*callback)(void))
Set the debug LPUART TX callback.
- Parameters:
callback – [in] Pointer to the LPUART TX callback.
-
void evk_uart_debug_set_rx_callback(void (*callback)(void))
Set the debug LPUART RX callback.
- Parameters:
callback – [in] Pointer to the LPUART RX callback.
-
void evk_uart_debug_dma_rx_enter_critical(void)
Disable debug UART DMA RX interrupt.
-
void evk_uart_debug_dma_rx_exit_critical(void)
Enable debug UART DMA RX interrupt.
-
void evk_uart_debug_stop_read_non_blocking(void)
Stop debug UART receive with DMA peripheral.
-
void evk_uart_exp_set_rx_callback(void (*callback)(void))
Set the expansion UART RX callback.
- Parameters:
callback – [in] Pointer to the UART RX callback.
-
void evk_uart_exp_set_tx_callback(void (*callback)(void))
Set the expansion UART TX callback.
- Parameters:
callback – [in] Pointer to the UART TX callback.
-
void evk_uart_exp_write_non_blocking_interrupt(uint8_t *data, uint16_t size)
Write data on the expansion UART in non blocking interrupt mode.
- Parameters:
data – [in] Data buffer to write.
size – [in] Size of the data to write.
-
void evk_uart_exp_read_non_blocking_interrupt(uint8_t *data, uint16_t size)
Read data from the expansion UART in non blocking interrupt mode.
- Parameters:
data – [in] Data buffer to read.
size – [in] Size of the data to read.