05-13-2025 02:02 PM
Hello,
I'm using a NI 6363 card and developing in LabVIEW. I'm performing an analog input acquisition that starts automatically with an analog trigger. In parallel, and on the same card, I'm generating an analog output signal.
I would like to synchronize both operations so that the analog output generation starts exactly when the analog input acquisition is triggered.
Here are more details:
The analog input task is triggered by a rising edge on an analog voltage channel.
The analog output should start at the same moment the acquisition begins.
Both tasks run with different sampling rates.
I'm programming this in LabVIEW.
The analog output is a pre-defined waveform.
My question is:
How can I synchronize the start of both tasks if they have different sampling rates? Can I still share a start trigger between the two tasks in this case?
Has anyone dealt with this kind of setup? Any advice or example code would be appreciated.
Thanks in advance!
05-13-2025 03:19 PM
Hi
Check the NI Example Finder Analong Ouput,
you can see how to configure the trigger of the Analog Output to learn about how labview deals with triggering.
There is also another trend on Forum Solved: Simultaneous analog input and output - NI Community
where you can find more information about how to solve your problem.
.
05-14-2025 02:10 AM
Hi ,
Thank you for your response. I have a question regarding triggers in LabVIEW: is it possible to use the same trigger for both an analog input and an analog output? If so, could you please explain how to configure this?
05-14-2025 09:04 AM
Try these two examples:
DAQmx\Analog Output\Voltage - Finite Output.vi
DAQmx\Analog Input\Voltage - Finite Input.vi
Configure each/both examples to use a digital start trigger: <your USB device>/PFI0
Run each example. The examples are armed and will begin outputting and acquiring the instant the digital trigger is received on PFI0.
05-14-2025 09:36 AM
Hello,
thank you
I'm using an analog trigger, and the board refused to work when I applied the same trigger to both (AI and AO).
I’ve tried other approaches, but what I need is for the generation to start after the acquisition begins.
I’ve attached an image showing that the analog output starts before the analog input.
Does anyone have a solution or idea on how to resolve this?
Thanks in advance!
05-14-2025 10:09 AM
Did you mean 'push a button' when you said "analog trigger"?
Your image doesn't show that analog output begins before acquisition; it shows that one task is started before the other. Rather than debate what the image shows, attach your code to help the community help you.
05-15-2025 05:13 AM
Hi,
No, the acquisition starts when I detect a predetermined voltage.
I used the same trigger on both tasks, but it refuses, saying that the task is already reserved. How can I use the same trigger for both tasks: acquisition and generation?
05-15-2025 07:24 AM - edited 05-15-2025 07:24 AM
You can configure the AO task to use an internal digital signal that your AI system will generate when its analog trigger condition is satisfied. Here's an incomplete, minimal screencap to illustrate:
-Kevin P