LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Sample data at one rate and output clock at another

Hi all,

 

I'm using an NI USB 6289 DAQ. I'm currently samplying data at 5kHz. I want to sync this to a camera that accepts at 1kHz signal.

 

Is there some way of generating an ouput signal of 1kHz that is synched to the 5kHz sampling clock? 

0 Kudos
Message 1 of 4
(3,120 Views)

As I understand, the idea can be the following - when you'll create tasks for acquiring and generating of the signal, for Timing VI try to set up the same clock source, but run tasks on different sample rate. 

Please, check this tutorial - http://www.ni.com/tutorial/3615/en/ , maybe, you'll find needed information.

0 Kudos
Message 2 of 4
(3,070 Views)

Hi, 

 

Thanks for the reply. That was helpful.

 

I wrote a vi that will acquire data at 5kHz and produce a square wave at 1kHz. Does this look correctly synched? (I modified one of the labview examples). 

 

Edit: I changed the vi attached. I had forgotten to attach the trigger. It now gives and error saying that all the samples were not written.

0 Kudos
Message 3 of 4
(2,983 Views)

Sorry for the double post but it would not let me edit my previous post again. The error I was getting was due to the fact the ai task starting before the ao. 

 

 

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