- From: David Schleef <ds_at_schleef.org>
- Date: Wed, 9 Oct 2002 18:47:38 -0700
On Wed, Oct 09, 2002 at 05:09:35PM -0700, rhk_at_newimage.com wrote: > > Message-Id: <20021010000933.D2E2EE034_at_newimage.com> > Date: Wed, 9 Oct 2002 20:09:33 -0400 (EDT) > From: rhk_at_newimage.com (Apache User) > > I found a problem with long-term analog input and output streaming > when using select() or poll() to determine when to send data. > > When sampling at 1Mhz, the counters used to determine buffer space > wrap around every 35 minutes. At some point, buf_write_count wraps > and becomes less than buf_read_count, so select() never indicates > that data is available, and eventually the buffer will fill up with > data from the card, and an overflow will occur. Thanks for noticing this (and the other) bug. It's simply a matter of the difference between "a > b" and "a - b > 0". Correctly determining buffer fullness requires the latter. I fixed it in CVS, could you check if it also solves your problems? dave...
Received on 2002-10-10Z00:47:38