Re: Serial issue

From: linux-os (Dick Johnson)
Date: Fri Aug 18 2006 - 16:02:50 EST

On Fri, 18 Aug 2006, Lee Revell wrote:

> On Fri, 2006-08-18 at 15:15 -0400, linux-os (Dick Johnson) wrote:
>> A file-transfer protocol??? Has he got hardware the __required__
>> hardware flow-control enabled on both ends? One can't spew
>> high-speed serial data out forever without a hardware handshake.
> Interesting you should mention that. As a matter of fact I have to
> disable all flow control or the serial console doesn't even work. I
> considered this a minor issue and had forgotten about it.
> But, in polled mode with no flow control I can transfer a 10MB file.
> There are a lot of retransmits but it works.
> Lee

Using RS-232C for file transfer and as a serial console are two
different things. Many terminals and terminal emulators don't
even activate RTS/CTS. If you are just getting data from the
output of a UART to view on a screen, the data usually comes
in spurts, a line at a time, and a screen at a time. There
is plenty of time for the receiving terminal to write the
stuff to the screen.

However, with file transfers, data streams with no breaks.
There needs to be time for these buffers of data to be written
to files, etc., or else you eventually run out of buffers even
if no interrupts are ever lost. Therefore, you must use hardware
handshake. In other words, you need to connect your machines
together with a complete null-modem cable, not just three wires.
Then both machines need to cooperate, i.e., the receiving machine
needs to lower CTS before its buffers get full and the sender,
must look at its RTS bit and wait for it to go false before
sending anymore data. Failure to do this __will__ result in
lost data.

Dick Johnson
Penguin : Linux version on an i686 machine (5592.62 BogoMips).
New book:

The information transmitted in this message is confidential and may be privileged. Any review, retransmission, dissemination, or other use of this information by persons or entities other than the intended recipient is prohibited. If you are not the intended recipient, please notify Analogic Corporation immediately - by replying to this message or by sending an email to DeliveryErrors@xxxxxxxxxxxx - and destroy all copies of this information, including any attachments, without reading or disclosing them.

Thank you.
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at
Please read the FAQ at