[U-Boot-Users] multiple i2c controllers
Wolfgang Denk
wd at denx.de
Thu Sep 2 23:20:54 CEST 2004
Dear Andy,
in message <2acbd3e404090213583c7c9e6 at mail.gmail.com> you wrote:
> I've been looking into adding support for a system that has 2 i2c
> controllers accessible by the processor to u-boot. Has anyone done
> something like this? Does u-boot's current i2c infrastructure support
> the idea of two separate i2c busses?
No, this is not supported yet. But I think it should be possible to
add this in a compatible way.
For example, we could use a notation of "[bus:]chip" addresses so the
existing commands in the i2* family will continue to work on systems
with a single I2C bus, and on multi-bus systems you just add the bus
number to the device address separated by a colon. For example, to
address the device with chip address 0x50 on bus 1 you would type
"imd 1:50 ..."; omitting the bus specifier would access the default
I2C bus. For simplicity, we can define that this is the same as bus 0
always. If you have time to play around, you could add a default bus
environment variable.
This would also work for example with the eeprom command; we could use
the "bus:" extension in the offset part, like:
eeprom read 100000 1:400 100
What do you think?
Best regards,
Wolfgang Denk
--
Software Engineering: Embedded and Realtime Systems, Embedded Linux
Phone: (+49)-8142-4596-87 Fax: (+49)-8142-4596-88 Email: wd at denx.de
There is is no reason for any individual to have a computer in their
home. -- Ken Olsen (President of Digital Equipment Corporation),
Convention of the World Future Society, in Boston, 1977
More information about the U-Boot
mailing list