Professional Documents
Culture Documents
5 –
Controlling Speed and
Position
Mr. McBrien
TEJ2O
References
https://www.arduino.cc/en/Reference/Servo
https://www.arduino.cc/en/Reference/Libraries
https://learn.parallax.com/tutorials/robot/shield-bot/rob
otics-board-education-shield-arduino/chapter-2-shield-ligh
ts-servo-11
Yesterday
Motors
Today
Elevators
Propellers
Aim
Left/right
Open/closed
Up/down
Grab/release
Motor + Sensor:
Motor moves slowly
Sensor
monitors situation and specifies stop
when objective is achieved.
The first time that you set up the CR servos, you need to
calibrate using a Philips screwdriver.
Set the output for both motors to 1500 ms.
Turn the screw until the wheel does not turn.
Your sketch will send 1700 ms for full speed forward
rotation, 1300 for full speed backward.
Any numbers between these values will give different
speeds.
Advantages of CR Servos
No H-Bridge!
We can have forward and reverse rotation without using
transistors
No flyback diode!
Voltage spike is dealt with by the motor itself.