| Electronics > Projects, Designs, and Technical Stuff |
| Servo motor interface |
| (1/2) > >> |
| akis:
Quick question, for a small project. There is a servo motor receiving input through a 3 pin connector. The motor seems to be able to turn 180 degrees. One wire must be ground, another must be 5V, and I am not sure about the third wire. Is it a linear voltage from 0 to 5 V ? I have only seen photos at this stage so cannot put my hands on it. It is a remote control like they use for model planes, a "receiver" unit with a lot of pins to connect to things like "flaps", "gear", "throttle" etc. The servo motor is connected to the receiver unit. |
| FenTiger:
Usually they're pulse width modulated. http://smartmicrocontroller.com/how-to-control-a-servo-using-pulse-width-modulation-pwm/ |
| akis:
OK, thanks I will look at the Arduino's built in PWM pins, I know there are some pins at 900Hz and some at 470Hz. If it is a single pulse we need I presume we need to toggle the output pins manually? There is also a servo library I need to take a look at. |
| FenTiger:
No, it's a repeating pulse train. I'd be surprised if you can't drive one from an Arduino PWM pin. Check the frequency, though - these servos want a repetition rate of about 50 Hz or so. |
| beanflying:
Without a picture or more info it is a bit hard? Sounds like you have a very typical model servo they are typically +- 60 degrees of travel from a nominal center point for a 1-2mS variable pulse with a center at 1.5mS. Depending on the servo you can drive them outside those limits and toward the 270-300 degree limit of the potentiometer that senses the position. However watch out for mechanical stops on the gear train lest you break something ;) The Arduino library you want is here https://www.arduino.cc/en/reference/servo if you want a simple option or even a 555 timer can be made work if you like http://hades.mech.northwestern.edu/index.php/555_Servo_Circuit or https://www.instructables.com/id/Drive-Servos-with-a-555-timer-IC/ |
| Navigation |
| Message Index |
| Next page |