NRFX_TWIM_EVT_OVERRUN when reading 256 bytes from I2C device

Hi,

I am working on a project using the nrf52832 with Zephyr.

I have an EEPROM-like device on an I2C bus connected to my nrf52832. The communication with the I2C device works fine when I read a couple of bytes or write a couple of bytes.

For reading, I use the i2c_write_read function from zephyr, with a num_write of 2 and a write_buf containing my register (0x2008 as little endian).

When I read 255 Bytes it works fine.

When I want to read 256 Bytes I get an NRFX_TWIM_EVT_OVERRUN  event from the TWIM driver.

If I read 128 Bytes from 0x2008 and then 128 Bytes from 0x2008+128 it works fine.

Is there any reason why I should not be able to read more than 255 Bytes from an I2C device using TWIM driver ?

Regards

Related