Multifunction DAQ

cancel
Showing results for 
Search instead for 
Did you mean: 

standard cDAQ LabVIEW function generator

Hello everybody,

 

I am currently trying to create a subVI dedicated to create standard waveforms (sine, constant, 12V to GND and 5V to GND) for my cDAQ-9188 with NI-9264 AO module. These types of waveforms will need to be run simultaneously, with high frequency availability (preferably up to 2kHz).

 

This subVI needs to run on LabVIEW standalone and as a model for VeriStand.

 

So, there are two main things I would like to ask:

 

1| Is it possible to accomplish the objectives stated above? (Continously writing AO in multiple channels in parallel to other modules, high frequency, etc)

 

2| The current state of the project can be seen on the image below

 

Capture.PNGCapture2.PNG 

This works fine for generating a single AO, but, if I change a value (frequency, amplitude...), the outputted wave will not change. That is because the script is trapped inside the inner while loop. For solving that problem, I added an update button. This works fine, but as soon as I use this VI as a subVI, the Update button becomes useless. That is because the loop will rather use the perceived value for the button from its first interaction than to request the current status of the main VI button.

 

Is there a way to solve this? I would love a solution that consists in a single subVI (rather thant multiple subVIs for setting up, writing and loops etc) that can perform the above, so I can use it to create a main VI which ressambles a toplevel diagram. I need to be able to update the AO status at any instance.

 

 

All of the project files are attached to this topic.

(Any hints are very welcome)

 

Thank you,

0 Kudos
Message 1 of 3
(2,836 Views)

Hello vglinden,

 

Did you see this link: Update Multiple Analog Output DAQmx Channels On-The-Fly ?
Maybe it can help you!

Best regards.

0 Kudos
Message 2 of 3
(2,759 Views)

Hi DanWilfer,

Thank you. I will take a look.

I was able to "solve my issue" of passing my arguments to the subVI via refnum. But my problem of running more than one continous AO function still holds.

0 Kudos
Message 3 of 3
(2,751 Views)