in nRF54L15 getting I2C error code as -5, unable to communicate with I2C peripheral.

Hi Team,

Below function returns error code as -5 and unable to write and read data from I2C peripheral.

err = i2c_write_read(i2c_devaddrwrite_datawrite_sizeread_dataread_size);
#define  EIO 5    /* I/O error */
Can you please provide your inputs to resolve this I2C issue.
Regards,
Sravan Rikka
  • Hi Rikka,

    Did you already solve your issue?

    How does your overlay file look? I had the same error and solved it by modifying my overlay file from

    compatible = "nordic,nrf-twi";

    to

    compatible = "nordic,nrf-twim";

    and that did it. The issue seems to be the “nordic, nrf-twi.”

    &i2c0 {
        compatible = "nordic,nrf-twim";

    Kind regards, Dani 

Related