read()
Description
Reads the servo angle.
Syntax
servo.read()
Parameters
servo
: A variable of type AIServo
.
Return
The current angle of the servo. If the servo is not generating any force, the return value will be -1. (Unit: degree)
Example
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 |
|
See also
– attach()
– write()
Library Reference Page
The text in the 86Duino reference material is modified from the Arduino reference material and is licensed under the Creative Commons Attribution-Share Alike 3.0 License . The code examples in the reference material have been released into the public domain.