How to reconfigure a S32K144 UART?

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 

How to reconfigure a S32K144 UART?

1,266件の閲覧回数
klau
Contributor II

Hi Dear reader(s),

Is there a way to reconfigure a UART during run-time in firmware?

For example, run UART at 9600 baud for some time, then switch to 115200 baud without doing a hardware reset.

Thanks,
Kevin

0 件の賞賛
返信
3 返答(返信)

1,119件の閲覧回数
victorjimenez
NXP TechSupport
NXP TechSupport

Hello Kevin,


It is possible to reconfigure the UART during run-time. With the help of the lpuart driver provided within the SDK is really easy. You just need to call the function LPUART_DRV_Deinit() and the initialize again the module with the new baud rate that you want to configure. If you have the interrupts enabled, then you need to disable the UART interrupt too.


Have a great day,
TIC

-------------------------------------------------------------------------------
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.
-------------------------------------------------------------------------------

0 件の賞賛
返信

1,119件の閲覧回数
klau
Contributor II

Hi Victor,

Thank you for your reply!!

I am not using any SDK. Could I do this without any SDK?

Thanks,

Kevin

On Thu, Jul 4, 2019 at 4:27 PM victorjimenez <admin@community.nxp.com>

0 件の賞賛
返信

1,119件の閲覧回数
victorjimenez
NXP TechSupport
NXP TechSupport

Hello Kevin,

Yes, it would be possible to achieve this without the SDK. However, you will have to make the bare-metal implementation of the function LPUART_DRV_Deinit since we don't provide it.

Best Regards,

Victor

0 件の賞賛
返信