Re: uart vs sio differences ?

From: Mike Tancsa <mike_at_sentex.net>
Date: Mon, 08 Dec 2008 17:39:25 -0500
At 04:02 PM 12/8/2008, Marcel Moolenaar wrote:

>On Dec 8, 2008, at 12:49 PM, Mike Tancsa wrote:
>
>>At 02:18 PM 12/8/2008, Marcel Moolenaar wrote:
>>
>>>I see, so the FreeBSD box with uart(4) is missing data,
>>>not the Windows machine, right?
>>
>>Hi,
>>        Correct.  The FreeBSD box never gets the full data, nor do we
>>see it on the "protocol analyzer".  Our analyzer is just a special
>>serial cable that copies the data from both sides to the monitor
>>program (a dos app) on another machine.
>
>Interesting. If it never shows up on the analyzer, then
>doesn't that indicate that it was never sent?
>Put differently: doesn't that indicate that the transmitter
>stops sending, and not that the receiver stops receiving?

What it appears to be is that as long as data is coming in, even at 
1200bps, the ioctl FIONREAD returns zero and an actual read does not 
return any data until there is either a pause in the data coming in 
or possibly when we do a xmit/write at which point the accumulated 
data is available for us to read.

We dont know if this is due to the hardware fifo or something in the 
driver itself.


>>>Do you know if you get the first 30 bytes or the last 30
>>>bytes or some mix?
>>
>>
>>Just checked, and we get the first 31 bytes each time.
>
>Ok.
>
>Could you check if any of RTS/CTS, DTR/DSR or DCD toggles
>after about 30 characters?

I am not sure if the DOS software we use reliably sees that.  We have 
a fancier windows app that might be more accurate.

         ---Mike


>If the analyzer also just gets the 30 characters, then maybe
>the receiver signaled the transmitter to stop (think of the
>16950 as having HW flow-control enabled and doing it on its
>own, without knowledge of the kernel).
>
>>  Is it possible the larger fifo buffer of the 16950 is holding onto
>>the data too long ? The sio sees it as a plain old 16550, but the
>>uart driver sees it as the 16950 that it is.
>
>The 16950 has a 128-byte FIFO, so even if it holds on to
>data too long, I would expect to receive at least 128
>bytes of data...




>--
>Marcel Moolenaar
>xcllnt_at_mac.com
>
>
Received on Mon Dec 08 2008 - 21:39:30 UTC

This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:39:38 UTC