Re: PCI-DAS4020/12 external triggering?

Hi Frank
Thanks for the info.
I am completely new to this AD card and also the comedi lib. I have  
tried the CR_EDGE and CR_INVERT with no luck.
At the moment I am sampling 0.1 MHz with an external trigger. The  
time delay I see from the samples are,  between trigger and data 0.8 ms.

In principle what I am trying to do is very simple. This card will be  
connected to a air warning radar system with one short (5 us long)  
TTL trig pulse output telling that a new radar cycle is started  
maximum frequency for this signal is 1 kHz, the signal I will sample  
is the raw video output from the radar detector with a bandwidth of  
10 MHz which i will sample at around 1 MHz.

So I really need the buffer that I read back with radar data to start  
with the trig pulse.

I am just reading data with  ret = read (comedi_fileno (dev), buf,  
BUFSZ);

Is this the proper way and will I use DMA than, if not how should I  
read the data to get maximum transfer speed.



Best regards Assar Westman


On 22 jun 2007, at 02.56, Frank Mori Hess wrote:
On Wednesday 20 June 2007 09:11, Assar Westman wrote:
Hi
I have just begun to use the comedi lib as the Linux driver for a
Measurement computing PCI-DAS4020/12 AD card. So far I have gotten
the card initialized and samples are taken, but the problem right now
is how the external trigger should be set up. I am using the BNC
connector on the backplane on this board and it seems to trigger but
the data I get is time skewed compared with what I see with a
oscilloscope. I have been looking into the driver code and have seen
that you should be able to change if the trigger should occur on a
positive or negative flank,

You want to bitwise-or the start arg with CR_INVERT to get falling edge.
Really you should do CR_EDGE too for edge triggering, but the driver
doesn't actually care.

and also the trigger level should be
possible to change between 0 or 2.5 V but I have not found how this
should be done through the API and I am not sure what the default
values are.

The driver doesn't support the board's analog triggering or hardware  
gating
capabilities.

-- 
Frank

Received on 2007-06-24Z15:09:57