public inbox for ecos-discuss@sourceware.org
 help / color / mirror / Atom feed
From: Matt Holgate <matt@dcs.gla.ac.uk>
To: <ecos-discuss@sources.redhat.com>
Subject: [ECOS] Serial overruns
Date: Mon, 17 Sep 2001 10:32:00 -0000	[thread overview]
Message-ID: <Pine.OSF.4.33.0109171816340.26791-100000@bathurst.dcs.gla.ac.uk> (raw)

Hi,

I have a very simple application with two threads - one that reads from a
serial port into a circular buffer (the producer), and the other that
writes the data back out to the same serial port from the buffer (the
consumer). The effect should be that any data sent over the serial line is
echoed back. Mutexes and condition variables are used to synchronise the
two threads and protect the shared buffer.

The program runs fine if send a small amount of data down the serial line.
However, if I send more than 16 characters (the size of the FIFO in the
UART), then I get buffer overruns and only receive the first 16
characters.

I've enabled hardware flow control, although I'm pretty sure the problem
is that the serial DSR is not responding in time to keep up with the data
rate (only 38400 baud), rather than the eCos buffer overflowing (it is set
to the default size of 128 bytes).

I've no idea what the problem is, so any suggestions would be much
appreciated!

thanks,
Matt







             reply	other threads:[~2001-09-17 10:32 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2001-09-17 10:32 Matt Holgate [this message]
2001-09-17 23:47 ` Robin Farine
2001-09-18  3:51 ` Robert Cragie
2001-09-18  8:43   ` Matt Holgate
2001-09-18 11:13   ` David Airlie
2001-09-18 11:17     ` David Airlie
2001-09-18 14:03       ` Jonathan Larmour
2001-09-18 14:25 ` Jonathan Larmour
2001-09-19  2:52   ` Matt Holgate
2001-09-19  3:29     ` Jesper Skov
2001-09-19  3:36       ` Jonathan Larmour
2001-09-19  3:41         ` Jesper Skov
2001-09-19  3:29     ` Jonathan Larmour
2001-09-19  8:47     ` Robert Cragie
2001-09-19 12:38       ` Jonathan Larmour
2001-09-19 12:59       ` Matt Holgate

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=Pine.OSF.4.33.0109171816340.26791-100000@bathurst.dcs.gla.ac.uk \
    --to=matt@dcs.gla.ac.uk \
    --cc=ecos-discuss@sources.redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).