Entra:     


Forum: General Discussion

Topic: Value range of get_level
Hello!

I'm trying to light various button LEDs dependent on the volume levels of each deck. I was thinking that get_level was the verb to use.

Something along the lines of:
button_led_1
deck 1 get_level > 10% ? color 'darkgreen'
button_led_2
deck 1 get_level > 50% ? color 'darkyellow'
button_led_2
deck 1 get_level > 90% ? color 'darkred'

Through trial and error with the above examples:
button_led_1
The light would come on when the meters reported LESS than 10%
button_led_2
The light would come on when the meters reported LESS than 50%
button_led_3
The light stayed on regardless.

My questions:
What value range does get_level spew out?
Is there a way to check other than trial and error?
Is there a better verb to use?
Do I need more coffee?
 

Inviato 11 hours ago
Put the action get_level in a custom button, and name the button "query"

BTW: get_level returns a float from 0.0 to 1.0
Therefore most likely you need to either cast the float to percentage, or compare it against a float value
 

You're not actually using '>' are you?