Serial port (Usart)
method
uart_init(u32 bound)
Initialized serial port usart1
| parameter | type | Annotation |
|---|---|---|
| bound | u32 | Baud rate (Commonly used: 9600/115200) |
USART1_IRQHandler()
USART1 interrupt processing function
Notice!
We rewritten the Printf () method for serial port debugging output. This method is more convenient than the subsequent sending function
Please use Printf () as the output function first
USART1_Send_U8(uint8_t ch)
Send characters
| parameter | type | Annotation |
|---|---|---|
| ch | uint8_t | Send character |
USART1_Send_ArrayU8(uint8_t *BufferPtr, uint16_t Length)
| parameter | type | Annotation |
|---|---|---|
| BufferPtr | uint8_t | String pointer |
| Length | uint16_t | String length |