LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Send a trigger to an external dev by time

Hi,

 

I have a very simple program that sends a sine wave function to an analog output channel and moves accordingly a vibrational table. My idea is to take  pictures with an external camera at the maximum amplitude of this movement.

Since the frequency I am using to move the table is very high the camera cannot take a picture every cycle and therefore I would have to wait several cycles so that the camera can be used again.

I was thinking to send a pulse to the camera (has a trigger input) every X time depending on the frequency I am using but I am not really sure how to do it, my problem is that I do not really know how to really synch the AO and the trigger.

Any help would be welcome. Thanks!

0 Kudos
Message 1 of 8
(4,246 Views)

Hi cobayatron,

 

Do you have any LabVIEW code developed yet that you could post? This would help in troubleshooting your application.

Thanks.

 

Mike

Certified LabVIEW Architect
Miami University
Instrumentation Laboratory

CLA Logo
0 Kudos
Message 2 of 8
(4,219 Views)

Well I have the basic sine generator program but I do not know how to do the trigger thing so you won't find a try here. If it helps, here you have a plot.Acquisiton frequency.JPG

0 Kudos
Message 3 of 8
(4,200 Views)

A few questions:

 

1. Can you post the actual VI (screen caputures are helpful, but not as helpful as the actual code)?

 

2. What type of hardware are you using (model # of the card, etc.)?

 

3. What type of interface does the camera have for the trigger input (TTL, etc.)?

 

Thanks.

Certified LabVIEW Architect
Miami University
Instrumentation Laboratory

CLA Logo
0 Kudos
Message 4 of 8
(4,194 Views)

Sure

I use a PXI chassis with a PXIe 6341 module and a SCB-68 connector block from where I am generating the sine output reading several channels and -I was hoping- send the trigger signal.

The array of cameras says to have a TTL trigger input available for this sort of synchronization.

Hope it helps

0 Kudos
Message 5 of 8
(4,190 Views)

6341 has counters that can generate TTL pulses. If software synchronization is enough, just generate single pulse in this loop. if you need pulse every fifth cycle, it will be every 50-th iteration of the loop. Depending on the phase (where is maximum), it can be 3, 53, 103, etc. Precision ~10 ms.

6341 can do hardware synchronization: for example generated pulse triggers camera acquisition and analog task (resumes movement). Check here how to do retriggerable tasks: https://www.ni.com/en/support/documentation/supplemental/21/retriggerable-tasks-in-ni-daqmx.html

To decimate pulses and control phase, use the second trigger. Precision of this pulse position can be ~10 ns,

0 Kudos
Message 6 of 8
(4,165 Views)

Someone else may be able to confirm this (or offer a better solution), but it also looks like you are using two different sample clocks in your application. It may be advisble to use one sample clock for everything.

 

Thanks.

 

Mike

Certified LabVIEW Architect
Miami University
Instrumentation Laboratory

CLA Logo
0 Kudos
Message 7 of 8
(4,159 Views)

Thanks everyone!

Sorry I was extremely busy. I'll try Alexander's solution, seems good enough for my case.

Thanks again!

0 Kudos
Message 8 of 8
(4,081 Views)