Hello, I have a problem to get analog input using external trigger.
I'm a newbie, so probably I missed very basic point.
Actually, I wanna do this job via python, but I came here cause there's no forum for python user. It shouldn't be very different from C++ I guess.
(Well, the question is not related to the measurement studio too..)
I have USB-6212 (windows10, python 3.7.6, NI MAX 18.5) and want to get analog signal, and am using sync signal(TTL) from a function generator as a trigger.
First, I created a task, then created AI voltage channel and set sample clock timing.
And then I connected BNC cable from function generator output to AI0, generated ~for example, sine wave(+-4V, 100Hz).
If I read the data without trigger, I can see the waveform generated by the function generator very well.
However, if I put
Solved! Go to Solution.
I forgot to write one thing.
I can translate C++ to python, so please let me know if somebody know how to do it in C++.
And to make the question clear,
what I wanna do is start data acquisition(AI) at the falling edge of TTL signal(from an external source) and stop the data acquisition at the rising edge of TTL signal.
Thank you in advance!
I found the reason.
I should declare the trigger source like '/Dev1/PFI0'. Not 'Dev1/PFI0'.
I could create VI channel without slash in front of Dev#, but not for trigger...that's strange.
Is there anybody know why should I add slash?
Anyway, the problem solved.