2008-10-16 02:59:58     uImage download to flashROM

Document created by Aaronwu Employee on Aug 8, 2013
Version 1Show Document
  • View in full screen mode

2008-10-16 02:59:58     uImage download to flashROM

Thomson Kim (KOREA, REPUBLIC OF)

Message: 63752   

 

Dear All.

 

 

 

I have success the downloading the uImage using the Hyperterminal to BF533 Stamp board.

 

after that,

 

I type the bootm command, it can boot and work well

 

however, after power reset(it's means....electrical power), cannot boot.

 

maybe....I download it to RAM (not ROM), so uImage maybe removed....

 

So, How can I download uImage file to ROM ?

 

Is there any method ?

TranslateQuoteReplyEditDelete

 

 

2008-10-16 03:29:23     Re: uImage download to flashROM

Daniele Pagani (ITALY)

Message: 63756   

 

Dear Kim,

 

yes, when you download the uImage, you put it on the ram, so, if you reset the board, you loose the image.

 

In order to store the image into ROM, please read this:

 

http://docs.blackfin.uclinux.org/doku.php?id=uclinux-dist:release-notes:2006r2

 

anyway, you can find instructions for your release (now I've this link, but you can find also for the last release).

 

The method is simple:

 

1) copy image to ram

 

2) see your flash configuration (from u-boot, you don't need to start operative system; command flinfo)

 

3) erase the sector that you need

 

4) copy from ram to rom

 

Anyway, some suggestion:

 

1) please, you need to see the size of the image; it needs to be ok for your rom

 

Best regards,

 

Daniele.

TranslateQuoteReplyEditDelete

 

 

2008-10-16 05:02:40     Re: uImage download to flashROM

Thomson Kim (KOREA, REPUBLIC OF)

Message: 63773   

 

Dear Daniele.

 

Thank you for kind help.

 

according to your advice,

 

I find the some command in doc.(http://docs.blackfin.uclinux.org/doku.php?id=uclinux-dist:release-notes:2006r2)

 

so, I type it in the bootloader env.

 

however, there is some doubtful messege.

 

Please, see the below ( I try it 2 times)

 

=======================================

 

bfin> cp.b 0x1000000 0x20040000 $3.5MB

Zero length ???

bfin> cp.b 0x1000000 0x20040000 $3630019

Zero length ???

 

=======================================

 

anyway, after do it, it still same action.

 

Could you help me ?

 

 

 

Thanks & BRs

 

Thomson.

 

 

TranslateQuoteReplyEditDelete

 

 

2008-10-16 05:34:57     Re: uImage download to flashROM

Daniele Pagani (ITALY)

Message: 63776   

 

Dear Thomson,

 

please, you need to type exactly $(filesize) and you don't need to replace $(filesize) with a value.

 

So, in my situation, I type:

 

cp.b 0x1000000 0x20040000 $(filesize)

 

and not

 

cp.b 0x1000000 0x20040000 $3.5M (or something similar).

 

I think that this one could be your problem.

 

Best regards,

 

Daniele.

TranslateQuoteReplyEditDelete

 

 

2008-10-16 05:58:18     Re: uImage download to flashROM

Thomson Kim (KOREA, REPUBLIC OF)

Message: 63781   

 

Dear Diniele

 

I'm very very thank you for kind help.

 

The belows are command & resopnse on the terninal

 

(The red marked word is type by me, another is response)

 

Sorry, I don't understand.

 

Please, see the belows & let me know.

 

 

 

Thanks & BRs

 

Thomson.

 

-------------------------------------------------------------------------------------------------------------------------------

 

bfin> protect off all

Un-Protect Flash Bank # 1

bfin> erase 0x20040000 0x203EFFFF

 

........................................................... done

Erased 59 sectors

bfin> cp.b 0x1000000 0x20040000 3629955 Bytes

Usage:

cp      - memory copy

 

bfin> cp.b 0x1000000 0x20040000 3629955Bytes

Copy to Flash... Outside available Flash

bfin> setenv bootcmd bootm 0x20040000

bfin> save

Saving Environment to Flash...

Un-Protected 1 sectors

Erasing Flash...

. done

Erased 1 sectors

Writing to Flash... done

Protected 1 sectors

bfin> reset

 

 

U-Boot 1.1.6-svn1273 (ADI-2008R1.5) (Jul 21 2008 - 00:31:11)

 

CPU:   ADSP bf533-0.3 (Detected Rev: 0.3)

Board: ADI BF533 Stamp board

       Support: http://blackfin.uclinux.org/

Clock: VCO: 398 MHz, Core: 398 MHz, System: 79 MHz

RAM:   128 MB

Flash:  4 MB

In:    serial

Out:   serial

Err:   serial

Net:   SMC91111 at 0x20300300

MAC:   00:E0:22:FE:06:38

Hit any key to stop autoboot:  0

## Booting image at 20040000 ...

Bad Magic Number

bfin>

 

-------------------------------------------------------------------------------------------------------------------------------

 

 

TranslateQuoteReplyEditDelete

 

 

2008-10-16 07:30:34     Re: uImage download to flashROM

Daniele Pagani (ITALY)

Message: 63785   

 

Dear Thomson,

 

my typical situation:

 

bfin> tftp 0x1000000 uImage.initramfs

 

that is, from u-boot I donwload by tftp the uImage of kernel

 

bfin> flinfo

 

so I can see my configuration, to see (RO) sector

 

bfin> erase 0x20040000 0x203ERRRR

 

so I erase sector from first address to last address

 

bfin> cp.b 0x1000000 0x20040000 $(filesize)

 

then, u-boot copy and write data from ram to rom

 

This is what I do. When I transfer by tftp I think that $(filesize) is the value of the variable that is automatically loaded.

 

Best regards,

 

Daniele.

TranslateQuoteReplyEditDelete

 

 

2008-10-16 07:40:59     Re: uImage download to flashROM

Thomson Kim (KOREA, REPUBLIC OF)

Message: 63786   

 

Dear Daniele

 

I'm very very thank you for kind help.

 

I could do it. thanks ~~!!

 

but, it little bit different method.

 

when I use the $(filesize), always cannot do it.

 

& alos,  I use the real file size, it also cannot.

 

so, I try to change filesize to hexadecimal.

 

& then It can boot well.

 

Very Very thanks for your help & corncer about it.

 

However, I need to try more about direct download to ROM & decrease the download time.

 

As I known, there are several method for downloading.(so, I find it & try it)

 

 

 

Thanks & BRs

 

Thomson.

 

P.S-

 

I'm very glad to know you~

TranslateQuoteReplyEditDelete

 

 

2008-10-16 07:41:52     Re: uImage download to flashROM

Thomson Kim (KOREA, REPUBLIC OF)

Message: 63787   

 

Dear Daniele

 

I'm very very thank you for kind help.

 

I could do it. thanks ~~!!

 

but, it's a little bit different method.

 

when I use the $(filesize), always cannot do it.

 

& alos,  I use the real file size, it also cannot.

 

so, I try to change filesize to hexadecimal.

 

& then It can boot well.

 

Very Very thanks for your help & corncer about it.

 

However, I need to try more about direct download to ROM & decrease the download time.

 

As I known, there are several method for downloading.(so, I find it & try it)

 

 

 

Thanks & BRs

 

Thomson.

 

P.S-

 

I'm very glad to know you~

 

---

Attachments

    Outcomes