PCA9685 16-Channel Servo Driver with an Arduino Uno
An I2C board that drives 16 servos or LEDs with 12-bit PWM from two microcontroller pins, chainable to 62 boards on one bus.

On an Arduino Uno the PCA9685 runs from the 5V pin and sits on A4 and A5, and it frees the Uno from generating servo pulses itself: no Servo library, no lost timers. The servos take their own 5 V to 6 V supply on the board's V+ terminal, never the Uno's 5V.
Wiring the PCA9685 16-Channel Servo Driver to the Arduino Uno
Pin by pin.
| PCA9685 16-Channel Servo Driver | Arduino Uno |
|---|---|
| VCC | 5V |
| GND | GND |
| SDA | SDA |
| SCL | SCL |
What to know on the Arduino Uno
- The Uno's Servo library takes Timer1 and disables analogWrite() on D9 and D10. Driving servos through the PCA9685 instead leaves all six of the Uno's PWM pins free and adds 16 channels.Arduino Servo library reference; NXP PCA9685 datasheet Rev. 4, p. 1
- The chip accepts I2C up to 1 MHz, but the Uno runs its bus at 100 kHz by default and 400 kHz at most. One servo update is a few bytes, so even 16 servos update quickly at the Uno's default speed.NXP PCA9685 datasheet Rev. 4, pp. 1, 40; Microchip ATmega328P datasheet DS40002061B, TWI section
- VCC powers only the chip, about 6 mA typical, from the Uno's 5V. The servos' current goes through V+ from their own supply, with its GND shared with the Uno's.NXP PCA9685 datasheet Rev. 4, p. 38; Adafruit 16-Channel PWM/Servo Driver guide
- The board's pull-ups go to VCC, which on the Uno is 5 V, matching the Uno's I2C levels.Adafruit 16-Channel PWM/Servo Driver guide, Pinouts
PCA9685 16-Channel Servo Driver code for the Arduino Uno
Compiled for arduino:avr:uno on 2026-10-30.
// PCA9685 16-Channel Servo Driver on Arduino Uno: wiring and a free simulation at https://www.tinkered.ai/components/pca9685-servo-driver/arduino-uno
#include <Arduino.h>
#include <Wire.h>
#include <Adafruit_PWMServoDriver.h>
Adafruit_PWMServoDriver pwm = Adafruit_PWMServoDriver(0x40);
const uint16_t SERVO_MIN_US = 544;
const uint16_t SERVO_MAX_US = 2400; // 180 degrees
void servoAngle(uint8_t ch, int deg) {
pwm.writeMicroseconds(ch, map(constrain(deg, 0, 180), 0, 180, SERVO_MIN_US, SERVO_MAX_US));
}
void setup() {
Serial.begin(115200);
pwm.begin();
pwm.setOscillatorFrequency(25000000);
pwm.setPWMFreq(50); // servos: 50 Hz
pwm.setPWM(15, 0, 1024); // the LED on 15 at 25 % (1024 of 4096)
}
void loop() {
for (int deg = 0; deg <= 180; deg += 10) {
servoAngle(0, deg);
servoAngle(1, 180 - deg);
delay(100);
}
for (int deg = 180; deg >= 0; deg -= 10) {
servoAngle(0, deg);
servoAngle(1, 180 - deg);
delay(100);
}
}
PCA9685 16-Channel Servo Driver on the Arduino Uno: questions
Why use a PCA9685 instead of the Servo library on an Uno?
The Servo library uses Timer1 and disables PWM on D9 and D10. The PCA9685 generates all pulses itself over I2C, so the Uno keeps its timers and gains 16 channels.
Can the Arduino Uno's 5V power servos on the PCA9685?
Power only the chip's VCC from the Uno. The servos need their own 5 V to 6 V supply on the V+ terminal block, with its ground joined to the Uno's.
Which Uno pins does the PCA9685 use?
SDA on A4 and SCL on A5, at address 0x40 by default (NXP datasheet, p. 7). Other boards on the same bus need their address pads bridged.
Keep going
This guide as plain Markdown. /components/pca9685-servo-driver/arduino-uno.md