From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Controlling two timed analogue outputs independently

Solved!
Go to solution

Hello,

I'm trying to design a system that has two devices that are each independently controlled by an analogue and digital signal using a PCIe-6363 NI DAQ card. The digital signal is defined as a series of duty cycles and frequencies on a counter line and the analogue signal is a 0-10V signal that is sampled at 1kHz. These signals are then convolved to get the device's output:

Analogue: ReklawLeinad_0-1680002516082.pngDigital:ReklawLeinad_1-1680002851441.png

Convolved:ReklawLeinad_2-1680002918704.png

 

The digital signals I can control using counter lines, so that isn't a problem. However, I'm having trouble with controlling the analogue outputs. They need to send a data point at 1kHz sample rate, so I was hoping to control them with a clock. The attached VI does work, but the two analogue inputs are timed by the same sample clock, and so I've had to set them up on the same task. This means I can't control the analogue outputs independently i.e. they have to be turned on and off or altered simultaneously. Is there a way for me to use the sample clock to time both of the analogue output lines independently at the same sample rate?

If you run the code, it won't actually do anything without the devices in between, but I hope it makes sense despite that. Here's an image of what it reads with the devices in:

ReklawLeinad_3-1680006089046.png

Thanks,

Daniel

0 Kudos
Message 1 of 7
(931 Views)

Sorry, I forgot to attach the VI in the first message XD

0 Kudos
Message 2 of 7
(930 Views)
Solution
Accepted by ReklawLeinad

If you need to truly control each AO line independently, you need a simultaneous output DAQ, unfortunately, your DAQ has only one Timing Engine that can support AO task and hence any AO that needs control has to use the same Timing Engine and hence same task.

Santhosh
Soliton Technologies

New to the forum? Please read community guidelines and how to ask smart questions

Only two ways to appreciate someone who spent their free time to reply/answer your question - give them Kudos or mark their reply as the answer/solution.

Finding it hard to source NI hardware? Try NI Trading Post
Message 3 of 7
(919 Views)

Thanks for the quick reply. That seems pretty definitive. So there's no way to, say, link the two analogue outputs to the same clock at a constant sample rate, and then write to them separately? Or would that still require more than one Timing Engine? 
It's still workable if I have to run them through the same task. I'm just going to have to modularly create tasks based on the number of active devices.

0 Kudos
Message 4 of 7
(818 Views)

Thanks for the quick reply! That sounds pretty definitive then. So there's no way to link two analogue output lines to a sample clock at a constant sample rate and then activate those independently? That would require more than one Timing Engine?

I can still work around it if I can't control them independently. I'll just need to create the tasks modularly based on which devices are active. It's less flexible, but I think it should work.

0 Kudos
Message 5 of 7
(892 Views)

You've to update all channels in a task and not selectively.

Santhosh
Soliton Technologies

New to the forum? Please read community guidelines and how to ask smart questions

Only two ways to appreciate someone who spent their free time to reply/answer your question - give them Kudos or mark their reply as the answer/solution.

Finding it hard to source NI hardware? Try NI Trading Post
Message 6 of 7
(889 Views)