Home > Industry Insights >Servo
TECHNICAL SUPPORT

Product Support

Two Motors, One Servo, and Another Motor: How to Control and Power Them Effectively

Published 2026-04-12

In many DIY robotics and automation projects, you often need to combine multiple actuators: two standard DC motors, oneservomotor for precise angle control, and an additional motor (for example, a pump, a screw drive, or a second joint). This guide explains how to safely integrate these four devices into a single working system, covering power management, wiring, control logic, and troubleshooting with real‑world examples.

01Core Principle: Separate Power Supplies Are Mandatory

The most common failure when using two motors, oneservo, and another motor together ispower starvation. DC motors draw high startup currents (often 2–3 times their rated current), and aservocan demand sudden spikes when moving under load. If all four are fed from the same low‑current source, the voltage drops, causing the microcontroller to reset, the servo to jitter, or the motors to stall.

Example from a typical hobbyist project:A builder created a small grabbing robot with two wheel motors, a servo for lifting the arm, and an extra motor to open/close the gripper. Using a single 5V/2A USB power bank, the robot would stop moving as soon as the servo tried to lift. After separating the power – a 7.4V battery pack (with a voltage regulator) for the two wheel motors and the extra motor, and a dedicated 5V/3A UBEC for the servo and the microcontroller – the robot worked reliably.

02Recommended Power Architecture

To power “two motors + one servo + one motor” safely:

1. Two DC motors– Use a 6V to 12V battery (e.g., 2S Li‑ion or 6–8× AA cells) connected to adual H‑bridge motor driver. The driver should handle at least 2A per channel continuously.

2. The servo– Most standard servos require 5V (4.8–6V). Power it from aseparate 5V regulatorcapable of delivering at least 1.5–2A peak. Do not draw servo power from the microcontroller’s 5V pin.

3. The extra motor– If it is another DC motor (e.g., for a drill or fan), power it from thesame battery as the two motorsbut through a separate single‑channel H‑bridge or a relay module. If it is a stepper or brushless motor, use its dedicated driver.

4. Common ground– Connect the negative terminals of all power sources together. This ensures control signals have a reference point.

Component Recommended Voltage Peak Current (typical) Power Source
Two DC motors 7.4V (2S Li‑ion) 2–3A each (startup) Main battery + dual H‑bridge
One servo 5V 0.5–1.5A Separate 5V/3A UBEC
Extra DC motor 7.4V (same as main) 1–2A Main battery + single H‑bridge

03Control Wiring and Signal Connections

All four actuators receive control signals from a microcontroller (e.g., an Arduino‑compatible board, ESP32, or STM32). Use the following guidelines:

Two motors– Connect the two motor driver inputs to PWM‑capable pins for speed control. Use two pins for direction (IN1,IN2) and one PWM pin per motor (or use a library that handles both).

Servo– Connect its signal wire to any digital pin. Use the standard Servo library (or equivalent) to send 50Hz PWM pulses (1ms = 0°, 1.5ms = 90°, 2ms = 180°).

extra engine– Connect its driver’s input pins to two digital pins (for forward/stop/reverse) and optionally a PWM pin for speed.

Important:Add a100–470µF electrolytic capacitoracross the power rails of the servo and across the main battery terminals. This filters voltage spikes and prevents resets.

04Practical Code Structure (Pseudocode)

The control logic must sequence actions to avoid simultaneous high‑current draws. For example, when moving the two drive motors at full speed, do not command the servo to move abruptly at the same instant – wait 50–100ms.

// Pseudocode for a grab‑and‑lift robot
#include 
Servo armServo;
int motorLeftPWM = 5, motorLeftDir1 = 6, motorLeftDir2 = 7;
int motorRightPWM = 9, motorRightDir1 = 10, motorRightDir2 = 11;
int extraMotorPWM = 3, extraMotorDir1 = 2, extraMotorDir2 = 4;
void setup() {
  armServo.attach(8);
  // Set all pins as outputs
  armServo.write(90);  // neutral position
  delay(500);
}
void moveForward() {
  setMotor(motorLeftDir1, motorLeftDir2, HIGH, LOW);
  setMotor(motorRightDir1, motorRightDir2, HIGH, LOW);
  analogWrite(motorLeftPWM, 200);
  analogWrite(motorRightPWM, 200);
}
void liftAndGrab() {
  // Stop drive motors to reduce total current
  analogWrite(motorLeftPWM, 0);
  analogWrite(motorRightPWM, 0);
  delay(50);
  // Move servo slowly
  for (int pos = 90; pos 

05Common Problems and Proven Fixes

Problem Typical Cause Solution
Servo twitches when motors start Voltage drop from motor inrush Add large capacitor (1000µF) across main battery; use separate servo power
Microcontroller resets randomly Ground loops or insufficient servo power Tie all grounds together; feed servo from dedicated 5V regulator
Extra motor runs only one direction Missing PWM signal or driver miswiring Check that enable pin is high; use analogWrite for speed
Two motors do not turn at same speed Different internal resistance or wheel friction Calibrate each motor with analogWrite values (e.g., left=180, right=200 for straight line)

06Final Recommendations and Actionable Steps

Core conclusion repeated: Success with two motors, one servo, and another motor depends entirely on separate power for the servoandcommon grounding. Never rely on a single USB power supply for all four actuators.

Actionable steps to complete your project:

1. Measure the stall current of each motor and the servo (use a multimeter with peak hold or a current clamp).

2. Select batteries – main battery capacity ≥ (sum of motor currents × 1.5), servo battery ≥ 2A continuous.

3. Build and test one component at a time – first the two motors (drive forward/back), then the servo (sweep 0–180°), then the extra motor (on/off with load).

4. Add decoupling capacitors – 100–470µF near each driver, and a 1000µF low‑ESR capacitor across the main battery.

5. Write code that staggers high‑current actions – avoid moving all three motors + servo simultaneously.

6. Monitor temperature after 5 minutes of operation – if any driver exceeds 70°C, add a heatsink or reduce PWM duty cycle.

By following this guide, you will build a reliable system that integrates two DC motors, one servo, and an additional motor without crashes or erratic behavior. Always start with the power architecture, then verify each actuator independently before final assembly.

Update Time:2026-04-12

Powering The Future

Contact Kpower's product specialist to recommend suitable motor or gearbox for your product.

Mail to Kpower
Submit Inquiry
+86 0769 8399 3238
 
kpowerMap