32 #define K_NUM_UARTS YOTTA_CFG_HARDWARE_UARTCOUNT 35 #ifndef K_UART_CONSOLE 36 #define K_UART_CONSOLE YOTTA_CFG_HARDWARE_CONSOLE_UART 39 #ifndef K_UART_CONSOLE_BAUDRATE 40 #define K_UART_CONSOLE_BAUDRATE YOTTA_CFG_HARDWARE_CONSOLE_BAUDRATE 101 #ifdef YOTTA_CFG_HARDWARE_PINS_UART1_RX 102 case K_UART1:
return YOTTA_CFG_HARDWARE_PINS_UART1_RX;
104 #ifdef YOTTA_CFG_HARDWARE_PINS_UART2_RX 105 case K_UART2:
return YOTTA_CFG_HARDWARE_PINS_UART2_RX;
107 #ifdef YOTTA_CFG_HARDWARE_PINS_UART3_RX 108 case K_UART3:
return YOTTA_CFG_HARDWARE_PINS_UART3_RX;
110 #ifdef YOTTA_CFG_HARDWARE_PINS_UART4_RX 111 case K_UART4:
return YOTTA_CFG_HARDWARE_PINS_UART4_RX;
113 #ifdef YOTTA_CFG_HARDWARE_PINS_UART5_RX 114 case K_UART5:
return YOTTA_CFG_HARDWARE_PINS_UART5_RX;
116 #ifdef YOTTA_CFG_HARDWARE_PINS_UART6_RX 117 case K_UART6:
return YOTTA_CFG_HARDWARE_PINS_UART6_RX;
125 #ifdef YOTTA_CFG_HARDWARE_PINS_UART1_TX 126 case K_UART1:
return YOTTA_CFG_HARDWARE_PINS_UART1_TX;
128 #ifdef YOTTA_CFG_HARDWARE_PINS_UART2_TX 129 case K_UART2:
return YOTTA_CFG_HARDWARE_PINS_UART2_TX;
131 #ifdef YOTTA_CFG_HARDWARE_PINS_UART3_TX 132 case K_UART3:
return YOTTA_CFG_HARDWARE_PINS_UART3_TX;
134 #ifdef YOTTA_CFG_HARDWARE_PINS_UART4_TX 135 case K_UART4:
return YOTTA_CFG_HARDWARE_PINS_UART4_TX;
137 #ifdef YOTTA_CFG_HARDWARE_PINS_UART5_TX 138 case K_UART5:
return YOTTA_CFG_HARDWARE_PINS_UART5_TX;
140 #ifdef YOTTA_CFG_HARDWARE_PINS_UART6_TX 141 case K_UART6:
return YOTTA_CFG_HARDWARE_PINS_UART6_TX;
KStopBits
Definition: uart.h:58
int dev
Definition: uart.h:82
KUART * kprv_uart_get(KUARTNum uart)
KStopBits stop_bits
Definition: uart.h:74
void kprv_uart_enable_tx_int(KUARTNum uart)
KParity
Definition: uart.h:64
int k_uart_write(KUARTNum uart, char *ptr, int len)
void k_uart_console_init(void)
void kprv_uart_dev_init(KUARTNum uart)
KUARTNum
Definition: uart.h:43
KUARTConf conf
Definition: uart.h:83
uint8_t tx_queue_len
Definition: uart.h:78
QueueHandle_t rx_queue
Definition: uart.h:84
KWordLen
Definition: uart.h:52
uint8_t rx_queue_len
Definition: uart.h:77
int k_uart_read(KUARTNum uart, char *ptr, int len)
int k_uart_rx_queue_len(KUARTNum uart)
int k_uart_rx_pin(KUARTNum uart)
Definition: uart.h:99
QueueHandle_t tx_queue
Definition: uart.h:85
void k_uart_init(KUARTNum uart, KUARTConf *conf)
KParity parity
Definition: uart.h:75
uint32_t baud_rate
Definition: uart.h:72
KWordLen word_len
Definition: uart.h:73
KUARTConf k_uart_conf_defaults(void)
const char * dev_path
Definition: uart.h:71
void k_uart_write_immediate(KUARTNum uart, char c)
void k_uart_rx_queue_push(KUARTNum uart, char c, void *task_woken)
int k_uart_tx_pin(KUARTNum uart)
Definition: uart.h:123