Hi,
I am using FRDM K22f baord for evaluation of K22 microcontroller series. I am trying to verify UART functionality using "lpuart_interrupt Example " driver example project but i am not able to configure the stop bit.
The stop bit declaration has been prevented with "FSL_FEATURE_UART_HAS_STOP_BIT_CONFIG_SUPPORT" macro.
I have tried enabling the macro through MCU setting in properties of project but still i am getting error while using stop bit varaiable in config structure of UART.
Please help in resolving the issue.
Thanks and best regards,
Prasanna
Hi Prasanna,
In K22 MCU LPUART has programmable 1-bit or 2-bit stop bits. On the other hand UART module doesn’t have this feature. That is why the FSL_FEATURE_UART_HAS_STOP_BIT_CONFIG_SUPPORT macro is '0' and FSL_FEATURE_LPUART_HAS_STOP_BIT_CONFIG_SUPPORT is '1'.
However, as you are using lpuart_interrupt example you don’t need to change the corresponding macro. In LPUART_GetDefaultConfig() function stop bit is configure to kLPUART_OneStopBit, please take a look to the snippet below.
I hope it helps!
Best regards,
Felipe
-------------------------------------------------------------------------------
Note:
- If this post answers your question, please click the "Mark Correct" button. Thank you!
- We are following threads for 7 weeks after the last post, later replies are ignored
Please open a new thread and refer to the closed one, if you have a related question at a later point in time.
-------------------------------------------------------------------------------