[U-Boot-Users] how to use 'eeprom read' command

Jerry Van Baren gerald.vanbaren at smiths-aerospace.com
Mon Sep 24 20:01:04 CEST 2007


Sachin Rane, Alphion Communications wrote:
> Hi,
> 
> I want to read boot eeprom using u-boot.
> Can you tell me which 'addr' I need to pass to the 'eeprom read' command?
> 
> --------------------------------------------------------------------------
> => help eeprom
> eeprom read  devaddr addr off cnt
> eeprom write devaddr addr off cnt
>        - read/write `cnt' bytes from `devaddr` EEPROM at offset `off'
> 
> --------------------------------------------------------------------------
> 
> I want to access boot eprom which is at 'devaddr' 0x54 and offset '0' to 
> '10'.
> 
> But I am not clear what ro pass for the 'addr' argument.
> 
> Regards,
> Sachin Rane

IIRC, "addr" is the memory (RAM) address that you read the eeprom data 
into or is the source tow rite the eeprom data out.  To read your i2c 
device 0x54, you would do something like:
   eeprom read 54 0 0 10
and then would be able to see the 16 bytes of data with the md command:
   md 0

Hope I'm not lying,
gvb




More information about the U-Boot mailing list