Hi. I am working on a project and I need to interface a EEPROM to store some data. I tried using I2C drivers from the ncs but it appears that the APIs support only 8 bit addresses as shown below.
Write API:
/** * @brief Write multiple bytes to an internal address of an I2C device. * * This is equivalent to: * * i2c_burst_write(spec->bus, spec->addr, start_addr, buf, num_bytes); * * @param spec I2C specification from devicetree. * @param start_addr Internal address to which the data is being written. * @param buf Memory pool from which the data is transferred. * @param num_bytes Number of bytes being written. * * @return a value from i2c_burst_write() */ static inline int i2c_burst_write_dt(const struct i2c_dt_spec *spec, uint8_t start_addr, const uint8_t *buf, uint32_t num_bytes);
Read API:
/** * @brief Read multiple bytes from an internal address of an I2C device. * * This is equivalent to: * * i2c_burst_read(spec->bus, spec->addr, start_addr, buf, num_bytes); * * @param spec I2C specification from devicetree. * @param start_addr Internal address from which the data is being read. * @param buf Memory pool that stores the retrieved data. * @param num_bytes Number of bytes to read. * * @return a value from i2c_burst_read() */ static inline int i2c_burst_read_dt(const struct i2c_dt_spec *spec, uint8_t start_addr, uint8_t *buf, uint32_t num_bytes);
So, is there any other alternative for this which I can use to access the EEPROM as 8 bits are not enough to access all the addresses. This driver is more suitable for sensors I believe.