Philips Semiconductors
4-bit I2C LED driver with programmable blink rates
Programming example
The following example will show how to set LED0 and LED1 off. It
will then set LED2 to blink at 1 Hz, 50% duty cycle. LED3 will be set
to blink at 4 Hz, 25% duty cycle. PCA9553/01 is used in this
example.
Table 1.
Start
PCA9553 address
PSC0 subaddress + auto-increment
Set prescaler PSC0 to achieve a period of 1 second:
Blink
period
+
1
+
PSC0 )
44
1
PSC0 = 43
Set PWM0 duty cycle to 50%:
256
– PWM0
256
+
0.5
PWM0 = 128
Set prescaler PWM1 to achieve a period of
0.25 seconds:
Blink
period
+
0.25
+
PSC1 )
44
1
PSC1 = 10
Set PWM1 output duty cycle to 25%:
256
– PWM1
256
+
0.25
PWM1 = 192
Set LED0 on, LED1 off, LED2 set to blink at PSC0,
PWM0, LED3 set to blink at PCS1, PWM1
Stop
I2C-bus
S
C4h
11h
2Bh
80h
0Ah
C0h
E4h
P
Product data sheet
PCA9553
2004 Oct 01
10