* [U-Boot-Users] how to get result using eeprom cmd under u-boot 1.1
@ 2006-02-13 9:14 Xu, Jin
2006-02-13 9:32 ` Vladimir Gurevich
0 siblings, 1 reply; 3+ messages in thread
From: Xu, Jin @ 2006-02-13 9:14 UTC (permalink / raw)
To: u-boot
When I use " eeprom read 0 0 1 " cmd, It only display " EEPROM @0x0
read: addr 00000000 off 0000 count 1 ... done "
how can I get the value using the eeprom cmd ?
I am sure that the funtion which eeprom_read ( cmd_eeprom.c ) call
are right.
Thanks & Regards
Xu Jin
^ permalink raw reply [flat|nested] 3+ messages in thread
* [U-Boot-Users] how to get result using eeprom cmd under u-boot 1.1
2006-02-13 9:14 [U-Boot-Users] how to get result using eeprom cmd under u-boot 1.1 Xu, Jin
@ 2006-02-13 9:32 ` Vladimir Gurevich
0 siblings, 0 replies; 3+ messages in thread
From: Vladimir Gurevich @ 2006-02-13 9:32 UTC (permalink / raw)
To: u-boot
Hello Jin,
Xu, Jin (SDC) wrote:
> When I use " eeprom read 0 0 1 " cmd, It only display " EEPROM @0x0
> read: addr 00000000 off 0000 count 1 ... done "
>
The format of the "eeprom" command is (as I'm sure you already know):
eeprom {read,write} <addr> <offset> <count>
The <addr> argument is the MEMORY address and that's where the result of
the transaction will be placed.
Thus,
1) Using 0 as <addr> is a pretty risky idea to begin with: :)
2) The more proper usage will be:
eeprom read 0x100000 0 10
md.b 0x100000 10
And, of course, a quick look at the source code is worth thousand emails :)
Happy hacking,
Vladimir
^ permalink raw reply [flat|nested] 3+ messages in thread
* [U-Boot-Users] how to get result using eeprom cmd under u-boot 1.1
@ 2006-02-13 11:53 Xu, Jin
0 siblings, 0 replies; 3+ messages in thread
From: Xu, Jin @ 2006-02-13 11:53 UTC (permalink / raw)
To: u-boot
Hello Vladimir
I already done. Thanks for your help!
I'd like share my note here.
How to update eeprom under Uboot
====================================
1 Create a binary file to store eeprom content
-----------------------------------------------
0x200 bytes.
2 Confige uboot environment variable and A TFTP server
------------------------------------------------------
make sure we can download the eeprom content file via tftp
under the uboot shell.
exam: we put the eeprom content file in the tftp root.
3 Update eeprom
------------------------------------------------------
Every thing is OK, and we can do the real job under the
uboot shell now.
1st download the eeprom content file to uboot memory 0x140000:
=>tftp 0x140000 eeprom.bin
then we can check what in the memory:
=>md 0x140000
=>md 0x140100
now we can write to eeprom:
=>eeprom write 0x140000 0x0 0x200
at last we can check what has done:
=>read read 0x140300 0x0 0x200
=>md 0x140300
=>md 0x140400
Thanks & Regards
Xu Jin
-----Original Message-----
From: Vladimir Gurevich [mailto:vag at paulidav.org]
Sent: 2006?2?13? 17:32
To: Xu, Jin (SDC)
Cc: u-boot-users at lists.sourceforge.net
Subject: Re: [U-Boot-Users] how to get result using eeprom cmd under u-boot 1.1
Hello Jin,
Xu, Jin (SDC) wrote:
> When I use " eeprom read 0 0 1 " cmd, It only display " EEPROM @0x0
> read: addr 00000000 off 0000 count 1 ... done "
>
The format of the "eeprom" command is (as I'm sure you already know):
eeprom {read,write} <addr> <offset> <count>
The <addr> argument is the MEMORY address and that's where the result of the transaction will be placed.
Thus,
1) Using 0 as <addr> is a pretty risky idea to begin with: :)
2) The more proper usage will be:
eeprom read 0x100000 0 10
md.b 0x100000 10
And, of course, a quick look at the source code is worth thousand emails :)
Happy hacking,
Vladimir
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2006-02-13 11:53 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2006-02-13 9:14 [U-Boot-Users] how to get result using eeprom cmd under u-boot 1.1 Xu, Jin
2006-02-13 9:32 ` Vladimir Gurevich
-- strict thread matches above, loose matches on Subject: below --
2006-02-13 11:53 Xu, Jin
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox