LPC845

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

LPC845

1,435 Views
UNIS
Contributor I

Hi all,

I want to use I2c protocol on LPC845 controller, on my board i have (PIO0_26 used as SDA ) & (PIO0_27 used as SCL ) to interface with OLED. i am using polling method

When i imported the driver example (PIO0_10 & PIO0_11) are configured as SLC and SDA line, so after i change that configuration according my schematics it is not working, neither is any message printed on terminal nor any changes on OLED.

Below is my c file attached.
could you guys help me as i started recently working on NXP controllers

0 Kudos
Reply
1 Reply

1,416 Views
xiangjun_rong
NXP TechSupport
NXP TechSupport

Hi,

I have checked your code, it appears that the code about the PIO0_26/27 pins configuration, SWM pin routing, I2C1 init is correct.

Pls check if the OD bit is 1 for PIO0_26/27

xiangjun_rong_0-1711682260235.png

Secondly, pls connect a pull-up resistor on the PIO0_26/27, as you know that the I2C pins must be open drain.

If you still have issue, pls connect a scope to the PIO0_26/27 and check if there is waveform.

Hope it can help you

BR

XiangJun Rong

 

0 Kudos
Reply