comedi_poll for cb_pcidas64

Hi all,

I'm recording the AIN channels of a MC PCI-DAS6025 board (cb_pcidas64) 
with a comedi_cmd.
While one application thread writes the recorded data into a file, 
another thread must read the most recent sample from time to time.
As it's impossible to comedi_data_read a subdevice while executing a cmd 
(it yields EBUSY), I mmap'ed the device's streaming buffer so I can read 
both buffer front and back.

Now the problem is that the samples do only arrive in 4k junks in the 
buffer which means that the buffer front can be up to 256ms old 
(4kS/16channels/1000Hz). This is way too much latency for my needs. So 
I've inserted a comedi_poll instruction before reading the buffer front, 
but this always fails with EINVAL, AFAICT because the cb_pcidas64 driver 
doesn't implement the POLL ioctl.

Now my question(s):
Is this a hardware limitation or could this be implemented?
Are there any other possibilities, e.g. tuning the size of sample junks 
or something like that?

It would be quite annoying if I'd have to make an RTAI module for such a 
basic data recording function that could easily be done in hardware.

Thanks in advance for any comments,
Jan

Received on 2005-04-06Z09:28:40