The I2C specification says the addressed target device responds to the 7 or 10 bit target address. And the data transfer is always in 8 bits. Then, does it mean all the I2C target devices just provide one byte data? If I want to access for example 4 32-bit registers using I2C, and if my target device has the target address for example 0x34, how can I read/write the registers? The specification doesn't clearly mention about this.
I2C Target Address – What Does It Mean and Can We Address Individual Registers?
i2c
Related Topic
- I2C Address – How to Display I2C Address in Hex
- Electrical – I2C Master communication with a Ten bit slave
- Electronic – what is an “Adressable” I2c device, and what does it mean
- Electrical – AVR Can Write I2C, but Fails to Read (Fails to Write Register Address)
- Electrical – Single master I2C with multiple target devices
- Electronic – How to setup STM32 as I2C slave device
- I2C Data Frame ACK Bit Always High – Troubleshooting Read Issues
Best Answer
The specification only defines how to talk to a device, reading and writing bytes to it.
The specification does not define what the bytes mean. It is up to your chips to define the protocol at byte level.
Some chips don't have any registers so they have just single data byte.
Some chips don't have any registers but you send command packets to it and read response packets.
Some chips have registers. Some chips have 8-bit register addresses so they use one byte of index, some chips have 16-bit register addresses so they use two bytes of index.
And depending on chip, the registers may be 8, 16, 24 or 32 bits long.
So how to use a specific chip is in the chip data sheet, not in I2C specifications.