Hi guys,
I will appreciate if someone can explain me the purpose of the following files:
1) serial_port_uart.c
2) serial_manager.c
3) lpuart_adapter.c
I would like to know how they work, but code comments are almost non existent.
Where do I define that the UART has to be connected to the USB PHY, to create an USB COM port?
Thank you,
Patricio
Solved! Go to Solution.
Hi Patricio
serial_port_uart.c defined LPUART APIs with user-defined settings, such as baudrate, parity mode.... please see functions Serial_UartInit/Read/write/...
These Serial_Uartxxx functions will call HAL_Uartxxxx, they are defined in LPUART_adapter.c
I would suggest refer to the uart demo for how to use lpuart driver .
SDK_2.6.0_EVK-MIMXRT1020\boards\evkmimxrt1020\driver_examples\lpuart
Please also read SDK API reference Manual: chapter 24 LPUART.
Regards
Daniel
Hi
The purpose of the serial manger is to mask the differences in multiple hardware modules.
The architecture of the serial manger is shown below:
For your case, serial_manage.c is in a high level.
Regards
Daniel
Hi Daniel,
Thanks for your reply.
And what about the other 2 files ( serial_port_uart.c and lpuart_adapter.c) ?
Thank you!
Hi Patricio
serial_port_uart.c defined LPUART APIs with user-defined settings, such as baudrate, parity mode.... please see functions Serial_UartInit/Read/write/...
These Serial_Uartxxx functions will call HAL_Uartxxxx, they are defined in LPUART_adapter.c
I would suggest refer to the uart demo for how to use lpuart driver .
SDK_2.6.0_EVK-MIMXRT1020\boards\evkmimxrt1020\driver_examples\lpuart
Please also read SDK API reference Manual: chapter 24 LPUART.
Regards
Daniel
Thank you Daniel