LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Set of unique controls within array

Is it possible to get a set of unique, individual controls with different ranges within an array of controls?
This is not the default operation.
 
For example, I'm using Analog Output VI with Fieldpoint AO module.
 
I have distinct scaling on each channel and need controls whose ranges fit each individual scale.
 
I don't want to create a separate VI for each channel one the AO module.  Surely that's not necessary.
 
 
0 Kudos
Message 1 of 9
(3,055 Views)
Hi wes,

in an array ALL elements have the same properties, the only difference is their value!

You cannot set different ranges for controls in an array...
Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 2 of 9
(3,046 Views)

Well, that's a shame.

It makes things much more cumbersome.

Here's something to add to the next LV release NI.

 

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

Hi Wes

Would a cluster do what you need? The cluster can hold different controls with varying ranges.


Paul

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

If the FP Write VI will accept it.

It looks like the default is a single DBL value.

I'll give it a shot though.

 

0 Kudos
Message 5 of 9
(3,033 Views)
I don't have any experience with FP, but perhaps you should do the range error checking separately and then feed the values to the array. You indicated that the datatype is DBL which covers a much wider range than any physical attribute you would be measuring or controlling. Use the In Range and Coerce function to check the values.

Lynn
0 Kudos
Message 6 of 9
(3,023 Views)

Tried the cluster.

Yes, one can assign unique data range values to individual controls within the cluster.

But the VI still doesn't recognize the scaling set in MAX and imported to the project when I select the entire bank in the Fieldpoint I/O control.

IF  I place a single control knob with my 8-16 range, and IF I select only the channel I configured in MAX as the item for the FP Write, THEN it works fine.

That still leaves me hanging when I have unique scaling for each channel.

I can't seem to group to controls and send the whole group of values to the FP Write VI and get the correct result.

 

0 Kudos
Message 7 of 9
(3,018 Views)

The FP Write VI found under Measurement Controls expects a 1-D array input for values, so I have to use the Cluster to Array conversion and that puts me back in the situation with using a fixed array structure.

 

0 Kudos
Message 8 of 9
(3,015 Views)
Hello Wes,

It sounds to me like you are trying to configure these ranges such that your user cannot select values that are outside of an acceptable range. If this is the case, then a cluster control on the front panel would allow you to individually control these input ranges. Using the cluster to array function, you will then convert the user's selection to a numeric value in an array. As you have seen, you can then write these values to the FieldPoint VIs as an array. Because those values are inherently within the ranges specified, it should not matter that the individual array elements are not configured for range.

I hope this information is useful for you. Please post back if I have misunderstood your application. Thanks,

Mike D.
National Instruments
Applications Engineer
0 Kudos
Message 9 of 9
(2,972 Views)