I am Jagir. I want to set the baud-rate to one of the UART component in my project programmatically.
I had gone through much APIs & functions But i did not find any way.
If any one had tried this ,Please guide me for that.
Solved! Go to Solution.
Select an external clock for your UART. There are APIs to change the clock divider, see "System Reference Guide" from Creator Help.
Thanks for your response,
I got a function void CySysClkWriteSysclkDiv (uint32 divider) from this we can set appropreate devider but here i want to change baudrate of my uart component only Because i think this will change my system clock also.
Is there any API for UART SCB u know with that we can change devider to change baudrate ?
If i had changed it then is there any API to read it ?
I wasn't quite right, sorry.
Use Clock_SetDivider() API for the clock you connected to the UART. See clock datasheet.