Is it normal for serial ports to drop characters at the end?

Marcus Sundberg marcus at cendio.se
Thu May 4 06:05:37 EST 2000


Dan Malek <dan at netx4.com> writes:

> Marcus Sundberg wrote:
>
> > Right on target.
> > rs_8xx_wait_until_sent() will wait for the *first* buffer descriptor
> > to be finished, instead of waiting for the last one as it should.
> > This patch fixes that problem:
>
> That's part of it, but we also need to perform a graceful shutdown
> of the port so we wait until the hardware FIFOs are empty.  Waiting
> for the buffer descriptor just means the CPM moved the last data
> from the buffer, not that it has gone out the wire.

Sure, but the above "works perfect for me(tm)", at least in 9600bps.

> I thought I did this once.....but, why are you closing devices anyway :-).

I think I experienced this first when using the busybox init
implementation, which IIRC opens and closes /dev/console for each
message. Otherwise I've never seen it in a real application.

/Marcus
--
-------------------------------+-----------------------------------
        Marcus Sundberg        |       Phone: +46 707 452062
  Embedded Systems Consultant  |      Email: marcus at cendio.se
       Cendio Systems AB       |       http://www.cendio.com

** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/





More information about the Linuxppc-embedded mailing list