I am facing some embarrassing problems recently.
After some trouble-shooting, I found that: We have Board-A and Board-B. Board-A and Board-B communicate to each other with a UART TTL Level Communication. The communication cable is around 80cm long. During the communication, I got a lot of UART errors.
My mission is to build a more reliable communication between Board-A and Board-B; but not allowed to modify the hardware design and baud-rate.
To me, it is not wise to use a UART TTL Level Communication between two boards. However, I am being told that, it is very popular to us to use a UART TTL Level Communication between two boards.
I tried to find some articles/documentation to convince the involved people, that, they should not use a UART TTL Level Communication between two boards. But I can not find anything useful. What I could find is something like: The UART usually does not directly generate or receive the external signals used between different items of equipment.
My question is: Where can I find some convincing articles/documentation to convince the involved people? (This is to avoid the future problems.) If I am not allowed to modify the hardware design and baud-rate, what choices do I have to build a more reliable communication?
Not that this has anything at all to do with Keil...
"I got a lot of UART errors"
What kind of "UART errors", exactly? There are plenty of things that could cause errors besides the use of TTL signals...
Possible problems are: Noise pickup; Cable capacitance; Grounding problems.
You should be able to see them with an oscilloscope. If the signal is "clean" at the receiving end, then you have some other problem...
Hi Andy,
Many thanks for your help.
Most UART errors are Framing errors at the receiving end. (UART Framing error flag == 1)
With an oscilloscope, I can see that, at the transmitting end, the signal at MCU tx pin is clean (frequency 19.2xxkHz, square ware), but the signal at the middle junction of the cable is not clean (frequency 20.xxxkHz, wave with rounded corners).
"at the transmitting end ... frequency 19.2xxkHz ... at the middle junction of the cable ... frequency 20.xxxkHz"
How can just a cable change the frequency??!!
"the middle junction of the cable"
What do you mean by that? What is this "junction"?
"not clean"
What, exactly, do you mean by that?
As the late, great Bob Pease used to say, "if something is 'funny', record 'amount of funny'"
I guess the damaged flanks of the signal makes it hard to measure the baudrate, so trying to measure a single bit gives enough measurement errors to make it seem like 20kHz.
Baudrate should always be measured by spanning as many bits as possible.
View all questions in Keil forum