Signal Conditioning

cancel
Showing results for 
Search instead for 
Did you mean: 

Trouble Acquiring Digital Input through 1302->1180->1349-PCI 6220->software

Hi,
 
I've got an SCXI-1000 chasis, and I'm trying to use an external clock and trigger signal to acquire data from a BNC 2095 board.  I have the 1302 unit to input my external digital signals.  The information feeds through the following units:  1180--> 1349 --> SHC 6868 EPM cable --> PCI 6220 card --> software
 
I've got my trigger connected to terminals 39(+) and 24(-) in the 1302 unit.  The external clock is connected to terminals 38(+) and 33(-). 
 
Within the DAQ Assistant, I've selected the trigger as PFI 1 and the clock as PFI 0.
 
I'd like to test the setup, but the test panel in the MAX won't let me select PFI0 or PFI0 as a channel.  I've also got a acquisition VI made, but it doesn't log any data even though there are no errors.  That's why I want to check that I'm getting the trigger/clock signals properly.
 
Any ideas on what to check or change? 
 
Thanks,
Michael
0 Kudos
Message 1 of 7
(4,007 Views)

Now that I've changed from a start trigger to a reference trigger, I get error -200278 as I'm sampling at 12,000 Hz (which I need to do).

The bottom of the message reads:

Attempted to Read Sample: 796

Property: RelativeTo
Corresponding Value: Current Read Position

Property: Offset
Corresponding Value:

Task Name: _unnamedTask<20>

After reading the other posts with this error, I tried reducing my scan rate significantly to 1,000 Hz and to 1 Hz, but I still get the same error.  Thanks again for the help.

0 Kudos
Message 2 of 7
(3,997 Views)

mrad,

This error occurs when a DAQmx read function attempts to return data after the board has stopped acquiring it. One common occurrence of this error is when a DAQmx read function is used inside of a while loop when the task is configured for a finite acquisition. By configuring a finite acquisition at the ‘DAQmx Timing’ VI, the board will only acquire data for a finite period of time. Once the board has acquired the specified number of samples, it will stop acquiring data. Thus, calling the DAQmx read function at this point will return error -200278.  If this is your case, the solution to this problem may be to configure the task to perform a “continuous acquisition.” When this option is selected at the ‘DAQmx Timing’ VI, the board will continue acquiring data until the task is explicitly stopped.

Regards,

Lon

Message 3 of 7
(3,985 Views)

Hi Lon,

That's exactly what's going on in my system.  I've got a DAQ assistant inside of a while loop.

I'd like to acuire a certain number of samples using a reference trigger, and I cannot do this with in the continuous sample mode.  I'm sampling at a high speed 120,000 Hz, and need to take 720 samples every cycle for a set of say, 10 cycles.  I've attached a trial VI.

Any suggestions?

Thanks again,
Michael
0 Kudos
Message 4 of 7
(3,978 Views)

Hi Michael,

In general, it's not a good idea to call the DAQ Assistant in a loop, since it allocates and frees resources every time it runs. You might want to take a look at the DAQmx examples in the NI Example Finder (Help>>Find Examples). There are located in the Hardware Input and Output\DAQmx directory in the Example Finder. There are several examples, with several timing and triggering configurations.

Here is some information about reference triggers: In NI-DAQmx, the stop trigger is referred to as a reference trigger. The reference trigger establishes the reference point in a set of input samples. It allows you to acquire samples both before and after the trigger is received. The number of pretrigger samples to be acquired is set using the Pretrigger Samples input. The number of posttrigger samples to be acquired is automatically determined by subtracting the number of Pretrigger Samples specified from the number of Samples to Read specified.

Also, take a look at the article I am linking below for information about NI-DAQmx. I hope all of this helps!

Learn 10 Functions in NI-DAQmx and Solve 80% of Data Acquisition Applications

--
Michael P
National Instruments
Message 5 of 7
(3,955 Views)

RDE,

Thanks for the help.  I got the idea of using the DAQ assistant in the loop from the standard LabView dialog box when you click on "new" --> "Data Acq with NI-DAQmx."  If this isn't a good idea, maybe LabView shouldn't have it as a starting format! Smiley Wink  The link with the 10 functions was helpful.

For now, the issues with this post have been resolved.  However, the main problem I'm having now is:

http://forums.ni.com/ni/board/message?board.id=170&message.id=171451#M171451

Feel free to take a crack at that one- Michael

0 Kudos
Message 6 of 7
(3,946 Views)
Michael,
 
In the case of continuous acquisition, you have no choice but to put the DAQ Assistant in a loop. Let us know if you have any more questions.
--
Michael P
National Instruments
0 Kudos
Message 7 of 7
(3,940 Views)