PCA9685 LED Registers

cancel
Showing results for 
Search instead for 
Did you mean: 

PCA9685 LED Registers

80 Views
Contributor I

All:

I am going to state an assumption - please tell me if I am correct.

ZeroMaxPWM
LEDn_ON_L0x000x000x00
LEDn_ON_H0x000x10 0x00
LEDn_OFF_L0x000xFF0xWM
LEDn_OFF_H0x10 0x0F0x0P

1. If I want zero output, I need to set bit 4 in the LEDn_OFF_H. All other contents of these 4 registers are ignored by PCA chip.

2. If I want max output, I need to set bit 4 in the LEDn_ON_H. Again, all other contents are ignored by PCA chip.

3. A valid PWM is greater than 0 and less than 0xFFF (12-bit max number). 

Regards,

Todd Anderson

Tags (1)
0 Kudos
1 Reply

32 Views
Contributor I

The PCA9685 datasheet states under heading "7.3.4 ALL_LED_ON and ALL_LED_OFF control" the following: "The LEDn_ON and LEDnOFF counts can vary from 0 to 4095. The LEDn_ON and LEDn_OFF count registers should never be programmed with the same values."

As an experiment, we set LEDn_ON to 0 and LEDn_OFF to 0, and the result was 0 output, the same as setting bit4 of the LEDn_OFF_H register. So, it is almost as if the Full Off bit is not required. 

However, to get full on, bit4 of the LEDn_ON_H register does need to be set to get full output. Otherwise, you get 1 cycle of off condition for "FFF".

0 Kudos