A joystick has a potentiometer that can measure resistance in the range of 0-10000 ohms. Write a program in Blockly that converts the resistance reading to a percentage value.

Blockly
when joystick moved
   set resistance to joystick resistance reading
   set percentage to (resistance / 10000) * 100

Related Questions