question about serial communication
wijnen at debian.org
Fri May 28 02:39:13 EDT 2010
On Thu, May 27, 2010 at 08:15:11PM -0400, Tao Jin wrote:
> I ran across this mailing list on the web. I have a question about
> serial comm. in embedded system. Hopefully this is the right place to
> ask such question.
If you're working on an open hardware project, I think this is the right
place. I'll just assume you are. :-)
> I am working a program that has zigbee cc2530 SoC communicate with
> host device, mobile phone, through serial interface. The baud rate is
> set as 115200 Kbps at both zigbee chip and host device.
This is insanely high. I think you mean 115200 bps, which is a normal
> When I ping 1 byte from host dev to zigbee, and zigbee echo back the
> response, the RTT was around 10ms. I think this has to do with some
> uncertain delay on the serial link. Anyone could show some guidance
> how to get around the high overhead on serial link? Or this is
> something unavoidable?
The speed of the link itself is not uncertain at all. One byte using
8n1 is 10 bits, so with 115200 bps, that costs about 87 μs. It's a
round trip, so that must be doubled; the total transfer time is then
The other 9.8 ms must be lost in the logic: The SoC sending an
interrupt and finding out that it is from the serial port, making up a
response, and the phone doing similar things.
One thing which may introduce a significant delay, is if you put the SoC
to sleep. When waking up, it will normally wait until all the clocks
Hope this helps,
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Size: 197 bytes
Desc: Digital signature
More information about the discussion