Chapter 10: Using Python to Control Servo Motors
Servo motors can make precise and repeatable motions. Motion such as this is vital for moving sensors, controlling robot legs or arms, and moving them to a known position. Its uses are so engineers can predict robot behavior, so a robot can repeat things in automation, or so code can move limbs to accurately respond to what their sensors are instructing them. Raspberry Pi or add-on boards can control them. In this chapter, we will use these motors to build a pan and tilt mechanism—a head to position a sensor.
In this chapter, we will cover the following topics:
- What are servo motors?
- Positioning a servo motor with the Raspberry Pi
- Adding a pan and tilt mechanism
- Creating pan and tilt code