2009-11-02 16:17:07     Problems running U-Boot from flash (BF518F EZBOARD)

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

2009-11-02 16:17:07     Problems running U-Boot from flash (BF518F EZBOARD)

Moritz von Buttlar (GERMANY)

Message: 81998   

 

Hi,

 

I'm having trouble to install U-Boot in the Flash. I downloaded the U-Boot source code from the svn repository, did a

 

make bf518f-ezbrd_config   

 

make

 

uploaded u-boot.bin  to RAM (using the serial line and loady), and tried to copy it into the parallel flash memory.

 

 

 

 

 

bfin>protect off all

Un-Protect Flash Bank # 1

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

bfin> erase 0x20000000 0x200fffff

 

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

Erased 23 sectors

 

bfin> print

bootargs=root=/dev/mtdblock0 rw clkin_hz=25000000 earlyprintk=serial,uart0,57600 console=ttyBF0,57600

bootcmd=run ramboot

bootdelay=5

baudrate=57600

loads_echo=1

ipaddr=192.168.0.15

serverip=192.168.0.2

autoload=no

rootpath=/romfs

gatewayip=192.168.0.1

netmask=255.255.255.0

hostname=bf518f-ezbrd

loadaddr=0x1000000

ubootfile=u-boot.ldr

update=tftp $(loadaddr) $(ubootfile);protect off 0x20000000 +$(filesize);erase 0x20000000 +$(filesize);cp.b $(loadaddr) 0x20000000 $(filesize)

addip=set bootargs $(bootargs) ip=$(ipaddr):$(serverip):$(gatewayip):$(netmask):$(hostname):eth0:off

ramfile=uImage

ramargs=set bootargs root=/dev/mtdblock0 rw clkin_hz=25000000 earlyprintk=serial,uart0,57600 console=ttyBF0,57600

ramboot=tftp $(loadaddr) $(ramfile);run ramargs;run addip;bootm

nfsfile=vmImage

nfsargs=set bootargs root=/dev/nfs rw nfsroot=$(serverip):$(rootpath),tcp,nfsvers=3

nfsboot=tftp $(loadaddr) $(nfsfile);run nfsargs;run addip;bootm

flashboot=bootm 0x20100000

ethaddr=22:ba:94:cf:dd:38

ethact=Blackfin EMAC

stdin=serial

stdout=serial

stderr=serial

filesize=28554

 

Environment size: 1068/8188 bytes

bfin> go 0x1000000

## Starting application at 0x01000000 ...

 

 

U-Boot 2009.08-svn2065 (ADI-2009R2-pre) (Nov 02 2009 - 21:15:35)

 

CPU:   ADSP bf518-0.0 (Detected Rev: 0.0) (parallel flash boot)

Board: ADI BF518F EZ-Board board

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

Clock: VCO: 400 MHz, Core: 400 MHz, System: 80 MHz

RAM:   64 MB

Flash:  4 MB

*** Warning - bad CRC, using default environment

 

In:    serial

Out:   serial

Err:   serial

Warning: Generating 'random' MAC address

Net:   Blackfin EMAC

Hit any key to stop autoboot:  0

 

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

Copy to Flash... done

 

 

go 0x1000000 starts U-Boot, but it gives a CRC error:

 

Then I changed the boot mode to 1 and hit reset. Nothing happens (on the serial port).  What's going wrong ?

 

 

 

Is there a precompiled version I could use ? I downloaded  u-boot-bf518f-ezbrd-2009R1-rc3.tar.bz2 but I'm still confused about the meaning of the different image files inside. Which one should I use ? u-boot-bf518f-ezbrd-para-2009R1-rc3.ldr ? What would be the commands to get it into the flash ?

 

 

 

 

 

Moritz

QuoteReplyEditDelete

 

 

2009-11-02 16:29:26     Re: Problems running U-Boot from flash (BF518F EZBOARD)

Mike Frysinger (UNITED STATES)

Message: 81999   

 

filesize gets changed every time you load a file, so its value after a 'go' is useless compared to what you loaded via loady before

 

do the entire update cycle without executing the new u-boot

QuoteReplyEditDelete

 

 

2009-11-03 04:42:18     Re: Problems running U-Boot from flash (BF518F EZBOARD)

Moritz von Buttlar (GERMANY)

Message: 82032   

 

Hi Mike and everybody else,

 

I'm still having problems to boot from parallel flash. I tried it with the right order like suggested.

 

Here's the log file of my last attempt:

 

 

 

bfin> loady                                                                 |

## Ready for binary (ymodem) download to 0x01000000 at 57600 bps...

Cmode, 1244(SOH)/0(STX)/0(CAN) packets, 5 retries                           +

## Total Size      = 0x00026cb0 = 158896 Bytes

bfin> protect off all                                      |

Un-Protect Flash Bank # 1

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

bfin> erase 0x20000000 0x200fffff

 

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

Erased 23 sectors

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

Copy to Flash... done

bfin> go 0x20000000

## Starting application at 0x20000000 ...

 

 

U-Boot 2009.06-svn1974 (ADI-2009R2-pre) (Nov 03 2009 - 09:50:25)

 

CPU:   ADSP bf518-0.0 (Detected Rev: 0.0) (parallel flash boot)

Board: ADI BF518F EZ-Board board

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

Clock: VCO: 400 MHz, Core: 400 MHz, System: 80 MHz

RAM:   64 MB

Flash:  4 MB

*** Warning - bad CRC, using default environment

 

In:    serial

Out:   serial

Err:   serial

Warning: Generating 'random' MAC address

Net:   Blackfin EMAC

MAC:   6e:52:3c:77:44:42

Hit any key to stop autoboot:  0

bfin> reset

 

 

 

 

The bootloader starts with the "go 0x20000000" command but doesn't show anything at the serial port  after a reset  (boot mode is 1). I tried it with 57600 and 115200 baud.

 

Maybe the address 0x20000000 is wrong or there's some jumper set wrong ?

 

I recompiled u-boot.bin using an older version (rev 1974) from the subversion repository, which should be the same as the latest released version. It still doesn't work. Is there a known  working version of u-boot.bin available for the BF518F EZBOARD ?

 

My board has BOM Rev. 1.3, Serial number 586832. Anything else to watch out for ? Should I try booting from the serial Flash or MMC instead ?

 

 

 

Moritz

QuoteReplyEditDelete

 

 

2009-11-03 04:53:21     Re: Problems running U-Boot from flash (BF518F EZBOARD)

Mike Frysinger (UNITED STATES)

Message: 82033   

 

you're using the wrong file for your boot mode.  please read the documentation:

https://docs.blackfin.uclinux.org/doku.php?id=bootloaders:u-boot:compiling#binaries

 

QuoteReplyEditDelete

 

 

2009-11-03 05:15:43     Re: Problems running U-Boot from flash (BF518F EZBOARD)

Moritz von Buttlar (GERMANY)

Message: 82034   

 

Thank you very much, Mike. It's working now. I got confused about the "bypass mode" and "boot from 8 or 16-bit external flash memory" mode which is supported by the BF518F EZBOARD and requires ldr files.

 

 

 

Moritz

Attachments

    Outcomes