Page 182 - Build Your Own Quadcopter_ Power Up Your Designs with the Parallax Elev-8
P. 182

chapter 7






                                                            Servo Motors and


                                                       Extending the Servo



                                                                  Control System






                        Introduction

                             In this chapter, I will show you what makes up a standard R/C servo motor, as well as how
                             to control one. I have already provided a considerable amount of information in the three
                             previous chapters on how pulse signals are used to control servos. Now it is time to reveal
                             the inner workings of a servo motor so that you will understand how and why it operates as
                             it does and be aware of its limitations and constraints when you are using it. This “reveal”
                             will focus on how a specific pulse width translates into a specific servo-motor motion.
                                I will also discuss how a standard servo motor can be converted into a continuous rotation
                             (CR) servo motor. CR motors operate a bit differently than standard ones do. The CR motor
                             has the pulse width that directly controls the continuous angular speed or rotation instead
                             of providing a limited angular motion as the standard servo motor does. CR servo motors
                             are often used as replacements for conventional motors in which low torque requirements
                             exist, such as for powering small R/C cars or boats. I always use CR servos to power my
                             robotic projects, and they seem to function quite nicely.
                                The next section describes how I built a system to measure the pulse widths for up to
                             three of the R/C channels. I will also show you how to display the results on a 4 × 20 LCD
                             character display. This system uses the Parallax Board of Education (BOE) and can be made
                             totally portable by powering it all from a standard 9-V battery. My discussion of the software
                             includes  quite  a  bit  of  information  regarding  pointers  and  indirection,  which  are  often  a
                             source of confusion for beginning programmers. Also, in the software, I point out how a Spin
                             program measures pulse width in a way that has not been previously shown in this book.
                                This chapter concludes with a discussion on two ways to extend the standard servo-
                             control system to accomplish functions that enhance the Elev-8 platform. The first one
                             controls the onboard LED lighting strips mounted on the bottom of the Elev-8 booms. The
                             second one controls a tilting mechanism for a remote-controlled, first-person viewer (FPV),
                             which can be attached to the bottom of the Elev-8. The actual FPV will be described in a later
                             chapter. Now, I want to focus on only the servo-control aspect of this system.

                        Exploring a Standard R/C Analog Servo Motor

                             Figure 7.1 is a partially transparent view of the inner workings of a standard R/C servo
                             motor. I would like to point out five components in this figure:

                                                                                                  161
   177   178   179   180   181   182   183   184   185   186   187