Fx3 UART Clock and Timeout Relation

Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob
lock attach
Attachments are accessible only for community members.
Anonymous
Not applicable

Hi,

          I have been working with the UART in FX3 (in Register Mode) trying to understand the APIs and it's working using the SuperSpeed Explorer Kit. I found that the timeout time for receiving bytes can be set by the CyU3PUartSetTimeout() API. From the API description I understand that the timeout value depends on the UART core Clock. From the technical Reference manual I get that the UART clock depends on the baud rate provided by the user (i.e. UART clock should be 16 times the baud rate). From this I thought that changing the baud rate value will  change the UART core clock which in turn will affect the timeout timing. I have attached the code with which I tried to get the timeout value without sending any data to UART and using  CyU3PSetTime() & CyU3PGetTime() APIs. But the timeout timings I get are all the same irrespective of the Baud rate. I got 964322ms for the timeout value 0xFFFFFFFF and 60720ms , 3767 ms for 0xFFFFFFF and 0xFFFFFF respectively for all the baud rates supported by TeraTerm. My doubt here is,

i) Does the UART core clock is a constant one and if so what is it's value?

ii) Are 'UART core clock' and 'UART clock' given in your documents the same??

0 Likes
2 Replies
AngelaF_06
Employee
Employee

I will submit this to an Engineer to respond to your post.

Thank You

Angela Freese

0 Likes
Anonymous
Not applicable

Hi,

Please add this API to your code CyU3PUartSetClock (uint32 baud_rate); before the CyU3PUartSetTimeout API.

Regards,

- Madhu Sudhan

0 Likes