Multifunction DAQ

cancel
Showing results for 
Search instead for 
Did you mean: 

urgent help: measure voltage with pci-mio-16e-1 card

I post my difficulty several times here, so far I did not figure it out. I may not make my question clear. I summerize my peoblems again here:
 
I am using PCI-MIO-16E-1 DAQ card to measure a squarewave voltage pulse.  I need trigger at rise edge and just single trigger to capture one squarewave. I get help from this discussion and modify Hardware Input and Output » DAQmx » Analog Measurements » Voltage » Acq&Graph Voltage-Int Clk-HW Trig Restarts.vi by  removing While Loop (since I only want to acquire one square wave), deleting the Stop Boolean, the Unbundle By Name (Status), and the OR from the block diagram. I configured the Physical Channel on the Front Panel to “Dev#/ai0”. I also adjusted Sample Rate and the number of samples per channel according to what I got from test penel with measurement & automation Explorer.. The card  works ok at sample rate (Hz) 1500000, sample to read : 500 with test panel. But I got following error:

Error_200284 occurred at DAQmx read (analog wfm 1chan 1 samp).vi

Possible reason (s):

Some of all of the samples requested have not yet been acquired.......

 I searched ni.com and got:

A timeout (-200284) will occur if you call the DAQmx read and there are not enough samples available after waiting the designated time ('Timeout' input to DAQmx Read.vi).  Following the same above suggestions you can avoid getting a timeout error.  The default timeout is 10 seconds.  You could also increase this number.  Given your sampling rate and number of samples, your application could take up to 120 seconds or 2 minutes to acquire enough data.

 

From here I got problem. what ever I do I have the same error. I even change timeout for DAQmx to -1, which makes ifinit waiting time. But the vi seems stop at subvi Dqamx read.vi for ever.

However if I use continouse sample in Dqamx timing .vi, I do not have any problem. It seems the problem comes from DQAmx read.vi and DQAmx timing.vi settings.

 

I attach my modified vi. Please help to see what I did wrong. I really need to resolve this very quick.

Thanks

Liming

 

 

 

 

Liming 

0 Kudos
Message 1 of 5
(3,438 Views)

Hi Liming,

If you're getting a timeout, it means you're not receiving the correct number of clock edges, or you're not receiving your trigger signal. Since your vi looks correct and DAQmx configures your clock for you, I would focus on your trigger signal. Are you taking your trigger signal (the square wave) and also connecting it to PFI 0 (the default AI trigger pin)? If so, when you read your signal in a test panel, does it meet the specifications of the trigger (high/low enough level)? Also, if you're doing just a single channel acquisition, you can use the channel you are acquiring from to trigger - you can wire your physical channel control directly to the "Source" input on the DAQmx Trigger.vi.

If you have everything connected correctly and you're reading the correct signal, does the DAQmx Read return any values, or just an empty array?

Also, if it turns out to be a HW problem with your card and you don't have time to send it in for repair, you can use a SW trigger. You could start with the "Cont Acq&Graph Voltage-Analog SW Trigger.vi" example and modify it to be a single acquisition.

Hope the helps,

Andrew S

Message 2 of 5
(3,421 Views)
This appears to be a duplicate of this thread. Andrew S is correct, however please continue on the origional post.
Neal M.
Applications Engineering       National Instruments        www.ni.com/support
0 Kudos
Message 3 of 5
(3,414 Views)
Thanks very much. I read from somewhere that PCI-MIO-16E-1 card not work with SW trigger. Anyway I am going to try it.
Liming 
0 Kudos
Message 4 of 5
(3,404 Views)

Just for completeness sake, a Software trigger works by just performing a continuous acquisition with the DAQ device, and processing the data on the fly to look for the trigger conditions. Once the conditions (Level, slope...) have been met it grabs the required number of pretrigger samples from a software buffer (usually a shift register in LabVIEW) and acquires the specified number of post trigger samples and then stops. Any DAQ device can perform some sort of software triggering provided the program supports it.

cheers,

Andrew S



Message Edited by stilly32 on 11-26-2007 09:41 AM
0 Kudos
Message 5 of 5
(3,383 Views)