Philips Semiconductors
AN10369
Philips ARM LPC microcontroller family
Fig 3. Waveforms
0xC1
4. I
2
C
In the above code examples for UART and SPI, interrupts have not been used but they
have been used for this example. I
2
C has been classified as an IRQ interrupt. LPC2106
is being used as a Master Transmitter and a Philips port expander PCF8574 is used as a
slave device. Waveforms are shown to help the user to understand the communication
better. VPB Divider value is at its reset settings and hence the peripheral clock is one
fourth of the system clock (10 MHz).
4.1 Calculation of Bit frequency
Bit Frequency = pclk/ (I
2
CSCLH + I
2
CSCLL)
Since the maximum speed the PCF8574 could interface to the LPC2106 is100 KHz
100KHz=
2.5MHz/(I
2
CSCLH + I
2
CSCLL)
Therefore
I
2
CSCLH + I
2
CSCLL=25
We select
I
2
CSCLH=13
&
I
2
CSCLL=12
© Koninklijke Philips Electronics N.V. 2005. All rights reserved.
Application note
Rev. 01 — 06 April 2005
8 of 17