Multifunction DAQ

cancel
Showing results for 
Search instead for 
Did you mean: 

External triggering from a digital input

I am controlling a motor that is triggered with a digital output pulse. The motor has a 'propeller' on the back end that sends digital signals through a photodiode. i need to trigger an analog data acquisition with each pulse of the digital input. I do not want to have a fixed number of data points or a hardcoded sample time.

Im using a PCI-MIO-16XE-50 daq card with version 6.9.3 and a 68-pin interface, programming with VB6.0
Heres what Im trying to accomplish:
click a button to start the scan.
the PFI0 sends a pulse to the motor to start.
the motor creates a digital pulse every revolution as a timing signal to any digital channel.
the analog input conversion is triggered by every digital pulse.
i can
then use an array to pull data from a circular buffer.

My question is, can I set this up in a closed-loop fashion(for performance), and what sequence of function calls would best do this? Or is there a better way to accomplish the same thing? Thanks in advance for any help you can provide.
0 Kudos
Message 1 of 2
(2,199 Views)
Hello,

If I understood correctly you need to send an output or a pulse to initialize the motor, and then, this motor will provide a pulse that you want to use it to trigger an analog acquisition, right? If so, then you can do as you were saying of outputting through one of the PFI lines or you can use one of the AO to generate an output.
Now about acquiring the data, it will depend on how many samples you want to acquire on each pulse. If it is just one sample on each pulse, then you can do use the pulse coming out of the motor as a sample clock. You just configure your AI to use external clock and that pulse train coming from the motor you can use input it into one of the PFI lines as clock.
I hope this is what you were looking for.

Ricardo S.
Nati
onal Instruments.
0 Kudos
Message 2 of 2
(2,199 Views)