LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Numeric Control Horizontal Scale Digits of Precision, Sig. Digits

Hello,

I am new with LabVIEW and am trying to place a numeric control on the front panel that allows a user to select a range of numbers that span from seconds to nanoseconds. The problem I am having is when I try to edit items in the control, LabVIEW doesn't seem able to respond when I get to the nanosecond range. When I type 0.0000005 (500 ns), LabVIEW returns 0.00000 (up to 5 decimal places). I've tried adjusting the number of sig digits to display, this doesn't change a thing. Then when I try to input another item, such as 200 ns, LabVIEW returns an ERROR telling me I have 2 items with the same value, in this case, 0.00000. I've included an image of my problem to better clarify. Any help is appreciated.

Thanks!


0 Kudos
Message 1 of 5
(2,730 Views)

Hi Newbie217,

i´m not sure and i don´t have checked it, but is it possible to enter the number in this way: 5e-10??
Maybe this helps.

Mike

0 Kudos
Message 2 of 5
(2,712 Views)
It looks like you are using a ring control. An alternative is to use a ring or enum as a selector to a case structure. The ring or enum is an integer datatype and the numerical values of 1e-6, 500e-9, ... are put into the cases as constants. The output of the case structure is the numerical value for your program.

Lynn
0 Kudos
Message 3 of 5
(2,706 Views)
Hi newbie,

you're talking about a ring control, "horizontal scale" is just the label of that ring...

Well, it seems the ring allows for DBL values, but rounds them to 6 decimal places... Possible workarounds:
- use a numeric control, set to SI notation and use physical units
- make the values of the ring as multiples of nanoseconds, this way you can use integer values (1µs = 1000 ns...)
- use sequential numbers for the ring values, use these values for indexing an array holding your actual timings
- use a property node to get the string of the current ring value, convert the string back to number


Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 4 of 5
(2,705 Views)
thanks so much for your help guys! I will try and implement your suggestions the next time I work on the program.

Thanks again!
0 Kudos
Message 5 of 5
(2,687 Views)