06-15-2023 10:25 AM
I will also note that I have my DO connected to a multimeter which does receive a 5V reading when I activate my external trigger.
06-15-2023 12:59 PM
Insert a pause after writing DO and then measure the signal Digital Output to ensure that the sw is doing what you requested.
Then exececute the write FAlse to ensure that the signal is back to 0.
06-15-2023 04:54 PM
I don't think that will solve the issue. When I highlight the execution and activate the trigger, the Analog 2D DBL NChan NSamp goes off first and then the Digital Bool 1Line 1Point activates. Ideally I would want it to activate at near the same time as the Analog 2D DBL NChan NSamp block.
06-16-2023 03:16 AM
@svazquez22 wrote:
I don't think that will solve the issue. When I highlight the execution and activate the trigger, the Analog 2D DBL NChan NSamp goes off first and then the Digital Bool 1Line 1Point activates. Ideally I would want it to activate at near the same time as the Analog 2D DBL NChan NSamp block.
Do you want the digital output to go high at the point the trigger occurs, or when the AI task finishes? At the moment your code waits until all AI samples are acquired before leaving the flat sequence and writing to the DO.
If you want the DO to start "at near the same time", you can add a trigger from PFI0 to the DO task. You'd need to write the digital pulse data to the DO task first, either as a 1D array of integers or a digital waveform, then start the AI and DO tasks in the first frame of the flat sequence (you can remove the second frame as both tasks are now waiting for the same trigger).
Andy
06-16-2023 11:02 AM
How can I go about doing this? I have tried setting up a triggered digital waveform before, but it does not seem to work properly. In the example I have attached, it runs with no error but it does not seem to work off the trigger I specified. The voltage also isn't read on my multimeter. Thanks for your help so far.
06-23-2023 12:45 PM
I think I managed to solve my problem so I am going to close this forum now, I'll include my solution.