I2C errors on LPC11U68 using LPCOpen I2C ROM driver (ERR_I2C_GENERAL_FAILURE)

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

I2C errors on LPC11U68 using LPCOpen I2C ROM driver (ERR_I2C_GENERAL_FAILURE)

Jump to solution
1,179 Views
d_m_
Contributor II

Hi,

I am working on a LPC11U68 (custom PCB design) and I have some errors when using the I2C interface. In particular, I obtain ERR_I2C_GENERAL_FAILURE (0x00060007) for some calls to ‘i2c_master_tx_rx_poll’ and ‘i2c_master_transmit_poll’ functions of the I2C ROM driver. The errors are not frequent (about 1 every minute with approximatively 1200 I2C transactions per minutes) and occur with no particular timing. Although, these errors are managed with a “check and retry” procedure, I am worried about the type of error: ERR_I2C_GENERAL_FAILURE.

Does someone know in which case such an error is raised by the ROM driver? Maybe some hints to identify the origin of the error (hardware or software).

Hardware setup:

  • Custom PCB design with all I2C slaves connected with PCB traces (no connector or external wire on I2C bus),
  • LPC11U68 as I2C master on I2C0,
  • 4 I2C slaves on I2C0 (all with different addresses),
  • Other interfaces used: USB VCOM and UART.

Firmware setup:

  • I2C configuration based on LPCOpen example “periph_i2c_rom_polling” (reusing function “setupI2CMaster”),
  • Simple tx/rx operations on I2C in polling mode.

Thanks.

David.

Labels (2)
0 Kudos
1 Solution
868 Views
soledad
NXP Employee
NXP Employee

Hi,

ERR_I2C_GENERAL_FAILURE means there is a failure detected on I2C bus. Please check the pull-up resistor in the I2C pins.

Remember that the number of ICs that can be connected to the same bus is limited only by a maximum bus capacitance of 400 pF, so please check the capacitive load.

 

Please check the AN11249 application note, this appnote details how to use the I2C ROM driver in master

and slave mode.

https://www.element14.com/community/servlet/JiveServlet/downloadBody/52504-102-1-266616/NXP.Applicat...

 

I hope this helps,


Have a great day,
Soledad

-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------

View solution in original post

2 Replies
869 Views
soledad
NXP Employee
NXP Employee

Hi,

ERR_I2C_GENERAL_FAILURE means there is a failure detected on I2C bus. Please check the pull-up resistor in the I2C pins.

Remember that the number of ICs that can be connected to the same bus is limited only by a maximum bus capacitance of 400 pF, so please check the capacitive load.

 

Please check the AN11249 application note, this appnote details how to use the I2C ROM driver in master

and slave mode.

https://www.element14.com/community/servlet/JiveServlet/downloadBody/52504-102-1-266616/NXP.Applicat...

 

I hope this helps,


Have a great day,
Soledad

-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------

868 Views
d_m_
Contributor II

Thanks for the detailed answer.

As I already checked I2C pins config, I will check hardware and also I2C protocol for peripherals.

Best,

David

0 Kudos