Multifunction DAQ

Showing results for 
Search instead for 
Did you mean: 

Is it possible to Meet an Increment Condition and then Decrement within the same While Loop?

Go to solution



I noticed that the "Equal?" function requires a boolean as an output but say you want to continue by decrementing 10 down to -10 V. 


Is there a way to achieve decrementing after incrementing within the same while loop?


Decrement after Increment.PNG


Many Thanks

0 Kudos
Message 1 of 3

Maintain your state and counts in shift registers and you can decide whether to add or subtract the 10.

There are only two ways to tell somebody thanks: Kudos and Marked Solutions
Unofficial Forum Rules and Guidelines
"Not that we are sufficient in ourselves to claim anything as coming from us, but our sufficiency is from God" - 2 Corinthians 3:5
Message 2 of 3
Accepted by topic author neunited

The indexing array input is a bad idea with your while loop 🙂


AND  unless you exactly now all values of the DBL it's also a bad idea to compare two DBLs with an EQUAL ... better use a >= or <=  or for this case the IN RANGE


Greetings from Germany

LV since v3.1

“ground” is a convenient fantasy

'˙˙˙˙uıɐƃɐ lɐıp puɐ °06 ǝuoɥd ɹnoʎ uɹnʇ ǝsɐǝld 'ʎɹɐuıƃɐɯı sı pǝlɐıp ǝʌɐɥ noʎ ɹǝqɯnu ǝɥʇ'

Message 3 of 3