Additionally, the output frequency of all 16 channels can be programmed from 24Hz to 1526Hz. Intended for controlling the brightness of multiple LEDs, the programmability of its PWM outputs means that it can also be configured for producing PWM signals compatible with driving standard servos. This module has been designed with this purpose in mind with 16 sets of headers that allow for any servo with a standard header to be directly plugged into the module. A screw terminal block provides a means of powering the attached servos from an external 5V PSU and so the number of servos you can drive from your microcontroller and so is not limited by the microcontrollerās power supply. For Arduino users, with this module and our exclusive Arduino library (HCPCA9685) you can directly control up to 16 servos from your Arduino with only a few commands.
The module also includes an I2C header with 10K pullup resistors and so only requires two data pins (SDA & SCL) to control the module. Solderable pads on the module provide a means of changing the default I2C address (0x40) to one of 62 options, meaning more than one module can be connected to the same I2C bus.
A wide operating range of 2.3V to 5.5V allows the module to be powered from a range of power supplies and when powered from a 3.3V supply is safe to interface to a Raspberry Pi or 3.3V or any other non-5V tolerant microcontrollers.
PLEASE NOTE:Ā The PWM output pins on this module are capable of sinking a maximum of 25mA or sourcing a maximum of 10mA. Do not attempt to drive high-current devices such as motors, bulbs, etc, directly from these pins as you will risk damaging the module. For servos, power is provided externally via the terminal header and only a small amount of current is drawn by the servo from each PWM pin.
Features:
- Operating power supply voltage range of 2.3 V to 5.5 V with 5.5 V tolerant inputs
- 16 LED drivers. Each output is programmable at: Off / On / Off
- 1 MHz Fast-mode Plus compatible I2C-bus interface with 30 mA high drive capability on SDA output for driving high capacitive buses
- 4096-step (12-bit) linear programmable PWM output varying from fully off (default) to maximum brightness
- Output frequency (all PWM output) typically varies from 24 Hz to 1526 Hz
- 16 totem pole outputs (sink 25 mA and source 10 mA at 5 V) with software programmable open-drain LED outputs selection (default at totem pole). No input function.
- 4 software-programmable I2C-bus addresses (one LED All Call address and three LED Sub Call addresses) allow groups of devices to be addressed at the same time in any combination (for example, one register used for āAll Callā so that all the PCA9685s on the I2C-bus can be addressed at the same time and the second register used for three different addresses so that 1ā3 of all devices on the bus can be addressed at the same time in a group). The software enables and disable these I2C-bus address.
- 25 MHz typical internal oscillator requires no external components
- External 50 MHz (max.) clock input
- Internal power-on reset
- Noise filter on SDA/SCL inputs
- Edge rate control on outputs
- No output glitches on power-up
- Supports hot insertion
- Low standby current
Pin Out
Power Pins
- GNDĀ ā This is the power and signal ground pin, which must be connected
- VCCĀ ā This is theĀ logicĀ power pin, connect this to the logic level you want to use for the PCA9685 output, should be 3 ā 5V max! Itās also used for the 10K pullups on SCL/SDA so unless you have your own pullups, have it match the microcontrollerās logic level too!
- V+Ā ā This is anĀ optionalĀ power pin that will supply distributed power to the servos. If you are not using for servos you can leave disconnected. It is not used at all by the chip. You can also inject power from the 2-pin terminal block at the top of the board. You should provide 5-6VDC if you are using servos. If you have to, you can go higher to 12VDC, but if you mess up and connect VCC to V+ you could damage your board!
Control Pins
- SCLĀ ā I2C clock pin, connect to your microcontroller I2C clock line. Can use 3V or 5V logic, and has a weak pullup toĀ VCC
- SDAĀ ā I2C data pin, connect to your microcontroller I2C data line. Can use 3V or 5V logic, and has a weak pullup toĀ VCC
- OEĀ ā Output enabled. Can be used to quickly disable all outputs. When this pin isĀ lowĀ all pins areĀ enabled. When the pin isĀ highĀ the outputs areĀ disabled. Pulled low by default so itās an optional pin!
Output Ports
There are 16 output ports. Each port has 3 pins: V+, GND, and the PWM output. Each PWM runs completely independentlyĀ butĀ they must all have the same PWM frequency. That is, for LEDs, you probably want 1.0 KHz but servos need 60 Hz ā so you cannot use half for LEDs @ 1.0 KHz and half @ 60 Hz.
Theyāre set up for servos but you can use them for LEDs! The maximum current per pin is 25mA.
There are 220 ohm resistors in series with all PWM Pins and the output logic is the same asĀ VCCĀ so keep that in mind if using LEDs.