Arduino Toolkit - @servo/readPosition


: position = readPosition (servo)

Read the position of a servo

Inputs

servo - servo object created from arduino.servo.

Outputs

position - value between 0 .. 1 for the current servo position, where 0 is the servo min position, 1 is the servo maximum position.

See also: servo, writePosition.