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: 

DAQmx Custom Scaling Issue

With the configure channel inside a for loop with shift registers and arrays of min and max is one way. Separate functions for each channel is another.
0 Kudos
Message 11 of 19
(968 Views)

Darn, was hoping to not have to build anouther array of 32 channels min/max

 

 

0 Kudos
Message 12 of 19
(964 Views)

One more question.

 

With the code i provided before. on the first iteration, i get the following error:

Error -200088 occurred at Property Node DAQmx Timing (arg 1) in DAQmx Timing (Sample Clock).vi:4730001->main.vi

Possible reason(s):

Task specified is invalid or does not exist.

 

 

0 Kudos
Message 13 of 19
(955 Views)
You haven't provided any code. All that I see is a partial image. Do you have a create task function?

You can cheat a bit by creating a DAQ Assistant with multiple channels and then converting that to a VI. Look at the block diagram.
0 Kudos
Message 14 of 19
(948 Views)

Opps, sorry

 

 

0 Kudos
Message 15 of 19
(941 Views)
Sorry, I'm away from a pc for a while. Please try the DAQ Assistant trick I mentioned to get the proper functions and order.
0 Kudos
Message 16 of 19
(928 Views)

Hi Tesla,

 

In the Measurement and Automation Studio, you can click in the task you created and in the configuration tab. Then you can set the custom scale for each channel. 

 

Regards,

 

William Fernandez

Applications Engineer 

National Instruments 

 

0 Kudos
Message 17 of 19
(902 Views)
There is no such thing as Measurement and Automation Studio. There is however Measurement and Automation Explorer. The op had a problem with the ranges of scales that had been created so your answer would appear off-topic.
Message 18 of 19
(898 Views)

There are some clear errors in your code.

 

If you look at the probes, then probe 45 to 48 has not been executed.

All these probes are in the for loop. That means that you for loop has not run a single time.

 

As the Task tunnel coming in and the Task tunnel going out of the for loop is a normal tunnel, if the for loop does not run, the value on the Task out of the for loop will be a default value, namely an empty undefined task. 

 

So what can make your for loop not to run?

You have 3 auto-indexed input to the for loop, if at least one of them is an empty array, the for loop will not run.

 

To prevent the loose of your Task if the for loop is not running, change the Task tunnels to use Shift Register. That will maintain the task value, even if the loop doesn't run.

0 Kudos
Message 19 of 19
(885 Views)