LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

How do I generate multiple analog outputs on the same board, One signal a square wave the other a constant DC voltage

Hi cjp1,

  Please post the exact question along with a screen shot of your code or attach the VI..

 

 

Thanks and regards,

srikrishnaNF

Regards,
Srikrishna


0 Kudos
Message 2 of 16
(6,107 Views)

assuming that you have a NI card with some analog output channels you can do the same.

 

Now the question is would you like to have a simulataneous AO or not and based on this you can select the NI card.

 

Some examples are aailable in the location C:\Program Files\National Instruments\LabVIEW 8.5\examples\DAQmx\Analog Out\Generate Voltage.llb\Cont Gen Voltage Wfm-Int Clk.vi

Regards
Guru (CLA)
0 Kudos
Message 3 of 16
(6,101 Views)
I am going to use a NI USB-6221 and want to use the AO0 and AO1 outputs to generate a 0-5 VDC, varying Duty Cycle, 100 Hz square wave on the AO0 output and a 0 to 10VDC signal on the AO1 output. I was able to get it working using the DAQmx vi's. I would like to be able to do it using the DAQ Assistant, I can generate the DAQ Assistant with the AO0 And AO1 terminals, no problem but how do I generate the input to the data terminal, a square wave and a dc signal?
0 Kudos
Message 4 of 16
(6,070 Views)

Hi cjp1,

  Just wire the daq assistant which is configured for both A01 and Ao0 to the signal express Vi which is configured to square wave of 50% duty cylce and dc signal.

 

 

Thanks and regards,

srikrishnaNF

Regards,
Srikrishna


0 Kudos
Message 5 of 16
(6,061 Views)

cjp1,

 

srikrishnaNF  gave a good suggestion. You want to use the Simulate Signal Express VI as shown below.

 

 

 

simulate signals.png

---

Peter Flores
Applications Engineer
0 Kudos
Message 6 of 16
(6,034 Views)

I realized this was an old post. But I am still wondering how to do this "in the DAQmx vi's" ?

0 Kudos
Message 7 of 16
(5,096 Views)

See the following example VI:

 

\Program Files (x86)\National Instruments\LabVIEW 2014\examples\DAQmx\Analog Output\Voltage (non-regeneration) - Continuous Output.vi

0 Kudos
Message 8 of 16
(5,045 Views)

Thanks, Blokk. I am new to Labview... How to modify this code to set two channels, especially for the "output array"? Is it possible to send me some figures? That will be very helpful. Thanks a lot!...

0 Kudos
Message 9 of 16
(5,006 Views)

It is described in the Front Panel of the VI how to configure it for multiple channels.

At the channel settings set the two physical channels which you wanna use: click on the little arrow at the right of the control, and chose "browse...". Using the CTRL button on the keyboard, you can select two channels with your mouse.

 

After this is done, go to the "Waveform settings" part, and click on the little up arrow on the Index display of the array. You will see this is grayed out, meaning the array by default is set to have only one element (Sine Wave by default). Set something else to test how it works, for example chose the Triangle Wave option. You can also play with frequencies/amplitudes...

Note here the description: "The number of elements in the waveform array must equal the number of channels in the task." Obviously...

 

I would recommend you to take some tutorials, so you will get more familiar with LabVIEW:

 

NI Learning Center

NI Getting Started

-Hardware Basics

-MyRIO Project Essentials Guide (lots of good simple circuits with links to youtube demonstrations)

-LabVEW Basics

-DAQ Application Tutorials

-cRIO Developer's Guide

 

Learn NI Training Resource Videos

3 Hour LabVIEW Introduction

6 Hour LabVIEW Introduction
Self Paced training for students
Self Paced training beginner to advanced, SSP Required
LabVIEW Wiki on Training

 

Here is a snapshot of the example VI configured to output two signals:

 

Application Example_BD.png

0 Kudos
Message 10 of 16
(4,997 Views)