Reading multiple bytes using I2C in U-Boot
问题 I am having a problem with the I2C driver for a Freescale p1022tw board. There is a command on U-Boot's console to read from an I2C device: i2c md chip address[.0, .1, .2] [# of objects] When I read 4 bytes from a device with id 0x60, at address 0x0, I get: tw=>i2c md 60 0 4 0000: 45 45 45 45 EEEE These values that it returned are wrong. I can get the right values if I read one byte at the time: tw=>i2c md 60 0 1 0000: 45 E tw=>i2c md 60 1 1 0001: 45 E tw=>i2c md 60 2 1 0002: 46 F tw=>i2c md