From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

How to use counter as an start and stop trigger in 6009

Hi ALL.

 

I'm using USB 6009 as a subject of to acquire data.

 

I would like to know on how to use the counter digital input as a start and stop trigger. 

 

The acquisition will only start when the first pulse of the digital signal is received and it will stop when the desired number of pulse is received.

 

I was trying to use the VI as attachment as my reference. However, after tried, the VI is not working for USB 6009 as the counter input cannot be used as a trigger.  

 

I would be happy if anyone could suggest me some ideas on this matter.

 

Thanks.

 

0 Kudos
Message 1 of 4
(2,635 Views)

Hi Fird,

 

The best you can do with 6009 is to build a first loop reading a counter value.

Then, if counter value>0, stop first loop and go to second loop.

In second loop, acquiring both AI and counter, and stop loop, if counter value reach limit.

However, this depends on computer speed and will not be precised control.

If you really wish to do exactly like what you said, you need to use FPGA hardware.

NI has couple of FPGA hardware conform with this kind of project as shown in http://www.ni.com/fpga/

 

Regards, Kate

0 Kudos
Message 2 of 4
(2,610 Views)

Hi Kate. 

 

Thanks for your response.

 

For your information, I've design my VI using the counter method. However, it doesnt work well. Please see the figure below. The file also attached with this reply.

 

Sans titre.JPG 

 

 

 At first, the first counter from Device 2 will start counting. If the counting equal 0, then the acquisition for Device 1/AIO also the counter of Device 1/ctr0 begin acquiring data and counting the edges respectively.

 

However, when I did the test, it doesn't work as wanted. It is happened because when counter of device 2 in not equal to 0, the acquisition for Device 1 not happened as it will go to false state.

 

Is there anything that someone could suggest on how to start the acquisition for device 1 only and if the counter of device 2 is equal to 1. I would like the acquisition of device 1 start only when the counter of device 2 is equal to 1. I cannot use the trigger as 6009 is not support for it. 

 

-Fird- 

Message Edited by Fird on 07-02-2009 04:28 AM
0 Kudos
Message 3 of 4
(2,604 Views)
I'm using 2 USB 6009 for this test. 
0 Kudos
Message 4 of 4
(2,603 Views)