bar
3
counter
2
change
1
block_value
bar
i
Turn on all the bars up to the chosen number
0
bar
1
i
100
secondNumber
Get what the number from the other block is and determine the sum
140160
sum
ADD
ADD
secondNumber
bar
2
WHILE
while the mapped sensor value doesn't match the correct sum keep getting the sensor value and mapping it
NEQ
sum
val
i
clear the number
bar
0
-1
i
750
convertSensorVal
Describe this function...
sensorVal
36523
val
0
upperVal
25.5
NEQ
sensorVal
0
val
1
WHILE
GT
sensorVal
upperVal
upperVal
25.5
val
1
sensorVal
36523
setBars
This function chooses how many bars lite up. Using random uses too much memory so I played around trying to find what would feel random. It takes 22 times to repeat its pattern.
bar
ADD
bar
change
5
counter
1
EQ
counter
5
change
ADD
change
2
5
counter
0