The Direct Answer: Sizing a Servo with Arduino for Your Load
To successfully run a servo with Arduino, you must size the motor's stall torque to at least 1.5 times your calculated static load torque, power it from a dedicated 5V-6V supply (never the Arduino's onboard 5V pin), and drive it using a 50Hz PWM signal. For 80% of hobbyist robotic arm and pan-tilt projects requiring between 5 and 10 kg-cm of torque, the default, concrete pick is the TowerPro MG996R (approx. $6 to $9). It features metal gears, handles up to 6V, and provides 11 kg-cm of stall torque, giving you ample headroom for dynamic acceleration without stripping the internal potentiometer.
Sizing a motor is not about guessing; it is about calculating the moment of force. The fundamental rule of thumb for rotary actuators is: Torque = Force × Distance. Hobby servos rate their torque in kg-cm (kilogram-centimeters) or oz-in (ounce-inches). To convert a physical mass into the required torque, multiply the mass in kilograms by gravity (9.81 m/s²) and the distance from the pivot in meters to get Newton-meters (Nm), then divide by 0.098 to get kg-cm.
Worked Load Example
Suppose you are building a camera pan-tilt mechanism. The camera weighs 300g (0.3 kg), and its center of mass sits 12 cm (0.12 m) from the servo's output shaft.
- Calculate Force: 0.3 kg × 9.81 m/s² = 2.94 N.
- Calculate Static Torque: 2.94 N × 0.12 m = 0.353 Nm.
- Convert to kg-cm: 0.353 Nm / 0.09806 = 3.6 kg-cm.
- Apply Dynamic Safety Margin: Static holding torque is not enough. Accelerating the load and overcoming gear friction requires a 50% margin. 3.6 kg-cm × 1.5 = 5.4 kg-cm minimum required.
A micro servo like the SG90 (1.8 kg-cm) will instantly strip its plastic gears here. The MG996R (11 kg-cm) will handle it effortlessly.
Servo vs. Stepper vs. DC: Which Motor Fits Your Load Profile?
A common mistake on the workbench is treating steppers and servos as interchangeable. They are fundamentally different architectures with distinct torque curves and control demands. A servo with Arduino relies on closed-loop internal feedback, while steppers and DC motors require external drivers and open-loop (or external encoder) control.
| Motor Type | Torque Curve & Zero-Speed Behavior | Control Needs & Driver | Typical Cost |
|---|---|---|---|
| Hobby Servo | High torque at zero speed. Internal closed-loop (potentiometer). Holds position actively. | 50Hz PWM signal (1-2ms pulse). No external driver needed; internal H-bridge. | $2 - $25 |
| Stepper Motor | High holding torque at zero speed. Open-loop. Moves in discrete steps (e.g., 1.8°). | Step/Dir pulses. Demands external chopper driver (A4988, TMC2209) and higher voltage (12V-24V). | $12 - $40+ |
| Brushed DC | Near-zero torque at zero speed. Requires a gearbox to multiply torque for positioning. | Requires H-bridge (L298N, DRV8833) for direction/speed. Needs external encoder for positioning. | $3 - $15 |
The Verdict: Choose a servo when you need precise angular positioning (typically 0° to 180°) under 25 kg-cm of torque without writing complex acceleration profiles. Choose a stepper when you need continuous rotation with high holding torque and exact step counting (like a 3D printer extruder). Choose a DC motor with a gearbox when you need continuous, high-speed rotation (like drive wheels) and don't care about exact angular holding.
Wiring, Terminals, and Power Delivery
Hobby servos use a standard 3-pin JR/Futaba connector. Identifying the terminals correctly is critical to avoid frying the Arduino's ATmega328P microcontroller.
| Wire Color | Terminal Function | Arduino / Power Connection |
|---|---|---|
| Brown or Black | GND (Ground) | Must connect to BOTH the external power supply GND and Arduino GND. |
| Red | VCC (Power) | External 5V to 6V power supply (BEC or buck converter). Never Arduino 5V pin. |
| Orange, White, or Yellow | PWM Signal | Arduino PWM-capable pin (e.g., D9, D10, D11 on Uno). |
If you power the servo from a separate 5V buck converter but forget to wire the buck converter's GND to the Arduino's GND, the PWM signal will have no reference voltage. The servo will jitter wildly, hum, or ignore commands entirely. Always bond the grounds.
The Arduino Servo library handles the 50Hz timing requirements automatically. However, hardware timers on the AVR architecture are limited. On an Arduino Uno, using the Servo library disables PWM functionality on pins 9 and 10. If you need those pins for analogWrite() (like dimming an LED), move your servo to pin 6 or 11.
The Decision Tree: Picking the Exact Servo Model
Stop guessing which servo to buy. Use this decision matrix based on your calculated load torque to select the exact part number. This eliminates the trial-and-error of ordering underpowered micro servos for heavy loads.
| Calculated Load Torque (with margin) | Required Gear Type | Concrete Pick (Part Number) | Specs & Price |
|---|---|---|---|
| < 1.5 kg-cm | Plastic | TowerPro SG90 | 1.8 kg-cm, 9g, ~$2.50 |
| 1.5 to 10 kg-cm | Metal | TowerPro MG996R (Default) | 11 kg-cm, 55g, ~$7.00 |
| 10 to 25 kg-cm | Heavy Metal | FeeTech FS5106B or DS3218 | 20-25 kg-cm, 6V, ~$18.00 |
| Continuous Rotation needed | Plastic/Metal | FS90R (Micro) or MG996R Continuous | Speed controlled, no position feedback, ~$4-$8 |
Default Recommendation: If your math puts you anywhere in the 3 to 8 kg-cm range, buy the MG996R. It is the industry workhorse. The metal gears prevent the catastrophic tooth-stripping common in the SG90 when a robotic arm hits a mechanical limit, and its internal motor can handle the higher current spikes of dynamic movement. For high-precision, zero-jitter applications (like camera gimbals), upgrade to a digital servo like the Pololu digital servos, which use higher internal PWM frequencies to hold position tighter, albeit at the cost of higher current draw.
Failure Signatures: Diagnosing Hum, Overheat, and Stall
When a servo with Arduino misbehaves, the physical symptoms tell you exactly what is failing in the electrical or mechanical domain. Do not just swap the motor; diagnose the signature.
1. The "Hum" or Jitter Signature
Symptom: The servo vibrates rapidly back and forth by a few degrees while holding a position, accompanied by an audible humming noise.
Cause: PWM signal noise, inadequate power supply filtering, or a worn internal potentiometer.
Fix: Solder a 470µF electrolytic capacitor across the VCC and GND wires of the servo to filter voltage ripple. If the jitter persists on only one specific servo, the internal carbon-track potentiometer is worn; replace the unit. In code, if the servo is not actively moving, call servo.detach() to stop sending the PWM pulse and eliminate idle hum entirely.
2. The Overheat Signature
Symptom: The servo casing becomes too hot to touch after a few minutes, and it may emit a faint melting plastic smell.
Cause: Continuous stall. The Arduino is commanding a position (e.g., 180°) that is physically blocked by a mechanical hard-stop at 175°. The internal H-bridge dumps maximum stall current (up to 2.5A on an MG996R) into the motor trying to reach an unreachable target.
Fix: Never rely solely on software limits. Install physical mechanical end-stops in your CAD design or chassis. In your Arduino sketch, map your input values to stay 5° away from the servo's absolute physical limits (e.g., map to 5° - 175° instead of 0° - 180°).
3. The Stall / Brownout Signature
Symptom: The servo starts to move, but midway through the sweep, the Arduino's onboard 'L' LED flickers, the serial monitor disconnects, and the system reboots.
Cause: Voltage brownout. The servo's starting inrush current pulls the shared 5V rail down below the ATmega328P's brownout detection threshold (typically around 2.7V to 4.3V), triggering a hardware reset.
Fix: This is the hallmark of powering a servo directly from the Arduino's 5V pin. Move the servo VCC to a dedicated 5V 3A buck converter (like an LM2596 module) fed from a 12V wall adapter or battery pack. Ensure the common ground is maintained.






