LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Sending multiple analog outputs to a NI 9264

I'm running LabVIEW 2015 and trying to control two motors with analog voltage outputs through a NI 9264. I'm new to lab view and i've had no problems up until this. I can send multiple digital outputs and receive multiple analog inputs no problem but for some reason i can't get this to work.

I like the DAQ assistant so if anyone can guide me on what im doing wrong please help.

It has something to do with the array dimensions? How do I work around this.

Download All
0 Kudos
Message 1 of 8
(3,666 Views)

I believe to use two channels on the DAQ assistant output task, you'll need to do "Merge Signals" to put the two signals together, rather than build array.

Ian
LabVIEW since 2012
0 Kudos
Message 2 of 8
(3,656 Views)

Your DAQ Assistant is set for 2 channels, continuous samples (100 samples).

 

Your To DDT express VI takes a 1-D array representing a single point for 2 different channels, and converts it to the evil blue dynamic data wire (you really can't tell what the data on it represents) to a 1-D array of scalars - single channel.

 

What you need to do is change that to 1D array of scalars - multiple channels.

 

If you created a 2-D array for multiple channels, and multiple samples, you'd use 2D array of scalars - columns are channels.  (If that didn't work, then use "rows are channels")

 

 

Message 3 of 8
(3,641 Views)
0 Kudos
Message 4 of 8
(3,629 Views)

When you merge the signals i get a buffer size error

Generation cannot be started, because the selected buffer size is too small.

Increase the buffer size.

Selected Buffer Size: 1
Minimum Required Buffer Size: 2

Task Name: _unnamedTask<39A>

0 Kudos
Message 5 of 8
(3,623 Views)

how do i change it to mulitple channels or make it a 2d array.

0 Kudos
Message 6 of 8
(3,621 Views)

If you just want to set a constant value, you probably want to change your generation mode to "1 sample"

 

temp.png

 

If you want to send a time-varying signal, you can use waveforms. Use quickdrop (ctrl + space) to find "Build Waveform" which has inputs for dt (period = 1 / sample frequency) and for 1D array Y. If you're writing 100 samples then Y should have a length of 100. You create 1 waveform for each channel, then build them into an array.

0 Kudos
Message 7 of 8
(3,619 Views)

i dont know if that is what i want. I'm trying to use an analog voltage to control 2 motors simultaniously

0 Kudos
Message 8 of 8
(3,614 Views)