DMA buffering scheme

Hello there,

I am new to comedi and would like to clarify few doubts.
I am trying to ADC using NIPCI6036 card.
The card works fine with comedi 'command',  but there are
some difficulties, if i think of the following style of buffering.

I would like the hardware to DMA transfer to two buffers alternatively,
with a flag specifying which buffer is currently being written.
This will get the card going without having to use 'read' to capture the
the streaming bytes.
I dont know whether such functionality is already there.
if so how to access.  This method is possible since the FIFO buffer status
(empty, half-full, full) seems to be available for this card in one of
the registers.

I thought I can emulate this in the software,
using the data pointer in the command structure. But the data pointer seems
to be unused, or atleast  i dont see the data in that pointer.
Additionally, the number of bytes returned in 'chunks' as specified in the
manual is not constant (if I use stop_src = TRIG_NONE and no EOS ).
This happens irrespective of the size I set using comedi_set_buffer_size.
Any clues to how to get this done?


Another issue is that the register_callback funcion is found in libkcomedi,
but this library is not built by default.
Is it built only for real time linux? Is it possible to use callbacks
with the normal linux kernel (not the real time).

Thanks in advance,
Jeyakumar

Received on 2005-05-13Z16:47:25