Multifunction DAQ

cancel
Showing results for 
Search instead for 
Did you mean: 

How can I use a TTL signal at my PFI to start a VI

Hello,

I am writing a VI to controll a motor with Digital Output, this is working. But this Vi has to start after the first (second, third or fourth) TTl pulse. How can I do that? I see some trigger options by AI and AO Vi's. But these Vi's are for different purposes.
Is there a simple way to "receive a pulse and than start a VI?

Thank you.
0 Kudos
Message 1 of 2
(2,572 Views)
Hi wilco,

If you don't mind a slight delay on the order of a couple ms then you could simply poll that bit in software and start your sub-block when that line becomes true.

If you require more precise timing, you could use a counter and configure an interrupt to fire on the output of the counter. You would need to setup the counter for pulse generation and then configure the "pulse spec 1" register with the number of pulses you want to wait before you output (will have to be more than 1 on a counter though). DAQ Occurrence 4 will be the one you want to configure an interrupt for rising edge of a counter output. The LabVIEW help file describes these occurrences and you should also be able to find some examples using occurrences in the shipping examples.
None of them use event 4 but you can get the basic programming concept by looking at the examples.

Anyway, hope that helps. Have a good day.

Ron
0 Kudos
Message 2 of 2
(2,572 Views)