LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Having several DAQ Assist.

Solved!
Go to solution

Hello there.

I started by setting up one DAQ assistant supplying both "reading supply" but that made an error.

Then I started on doing this as shown in the VI (see attached file) - having one DAQ for each.

I simply want to supply two level sensors and read from them, so that i'm able to see whether the water level is high or low.

I really can't see what my problem should be, now that I have specified which output and input each DAQ should work with.

Are there someone who please can help me out?

 

Getting this for both "reading supply":

Error -50103 occurred at DAQmx Start Task.vi:9

NI Platform Services:  The specified resource is reserved. The operation could not be completed as specified.

 

 

Best Regards

Kenneth G. Vejen

0 Kudos
Message 1 of 9
(3,473 Views)

You forgot to attach the vi. I guee the problem is with the Task configuration, how are you creating the task?

-----

The best solution is the one you find it by yourself
0 Kudos
Message 2 of 9
(3,470 Views)

Ups, sorry 😉

Here it is..

0 Kudos
Message 3 of 9
(3,461 Views)

Regarding the tasks.

I have created the tasks by "right click" on a block diagram, then "Express"-->"Input"-->"DAQ Assist".

From there I have configured the single DAQ.

0 Kudos
Message 4 of 9
(3,458 Views)

As a search for the error code or the error message would have shown, you have a common beginner's error. You simply cannot have two separate DAQ Assistants. Create one for both analog outputs and one for both analog inputs.

0 Kudos
Message 5 of 9
(3,442 Views)

I have actually tried that as well, but that does not work either, unfortunately!

But then I just get this error:

 

Write cannot be performed, because the number of channels in the data does not match the number of channels in the task.

When writing, supply data for all channels in the task. Alternatively, modify the task to contain the same number of channels as the data written.

Number of Channels in Task: 2
Number of Channels in Data: 1

 

 

There is probably something i'm missing, to make this code work, right? - see attached file.

Also I want to see bot measurements and have no idea how to do that. I have searched on the internet for hours, but no luck.

0 Kudos
Message 6 of 9
(3,439 Views)

I have deleted my power supply now that I only need a constant 5V which an can get from USB-6008.

Then I have one last problem, how is it possible to read from both AI0 and AI1 from a single DAQ assist data-output?

See attached file.

 

-Kenneth

0 Kudos
Message 7 of 9
(3,436 Views)
Solution
Accepted by topic author kennethgv

If you want to control 2 analog outputs, you need to provide 2 analog sources. I think the error message is pretty clear. You only have a single control. Have 2 controls and create an array.

 

Your analog read does not make any sense either. You have a single comparison and a single (hidden) indicator. Why would you do that when you are trying to read 2 channels?

 

p.s. Creating an indicator and wiring it to the knob control is silly. Simply right click on the knob and select Visible Items>Digital Display.

0 Kudos
Message 8 of 9
(3,435 Views)

I agree with you all the way and have simplified my code a lot.

I came up with this example instead.

Thank you for your time.

 

- Kenneth

0 Kudos
Message 9 of 9
(3,432 Views)