2011-01-28 18:31:35     No U-boot prompt after bfin-uclinux-ldr

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

2011-01-28 18:31:35     No U-boot prompt after bfin-uclinux-ldr

Nathan Manning (UNITED STATES)

Message: 97739   

 

Hello,

 

I am new to blackfin and uClinux and am trying to get everything up and running on my BF526 ez-board. I'm following the walk through as close as possible and I believe I have a working precompiled toolchain and u-boot.ldr file. When I try to load the file over the UART however I get the following:

 

 

 

bfin-linux-uclibc-ldr -l /home/nathan/Desktop/u-boot-bf526-ezbrd-2010R1-RC2/u-boot-bf526-ezbrd-uart-2010R1-RC2.ldr /dev/ttyUSB1 && kermit -l /dev/ttyUSB1 -b 57600 -C connect

Loading LDR /home/nathan/Desktop/u-boot-bf526-ezbrd-2010R1-RC2/u-boot-bf526-ezbrd-uart-2010R1-RC2.ldr ... OK!

Removing stale lock '//var/lock/LCK..ttyUSB1'

Opening /dev/ttyUSB1 ... OK!

Configuring terminal I/O ... OK!

Trying to send autobaud ... OK!

Trying to read autobaud ... OK!

Checking autobaud ... OK!

Autobaud result: 115200bps 29.491mhz (header:0xBF DLL:0x10 DLH:0x00 fin:0x00)

Sending blocks of DXE 1 ... OK!         

You may want to run minicom or kermit now

Quick tip: run 'ldr <ldr> <tty> && minicom'

Connecting to /dev/ttyUSB1, speed 57600

Escape character: Ctrl-\ (ASCII 28, FS): enabled

Type the escape character followed by C to get back,

or followed by ? to see other options.

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

 

 

 

 

Followed by a whole lot of nothing. I have gotten it to boot through to the "bfin>" prompt, but only once. I can't seem to repeat the process at all. Any help would be appreciated. One difference I noticed between the walk through and my own screen is that I only send DXE 1 not DXE 1 and 2 as the screenshots show. Is this to be expected?

 

 

 

Regards,

 

Nathan

 

PS It should also be noted that I'm using a pl2303 serial to USB converter.

QuoteReplyEditDelete

 

 

2011-01-29 00:45:47     Re: No U-boot prompt after bfin-uclinux-ldr

Mike Frysinger (UNITED STATES)

Message: 97742   

 

this is a u-boot question rather than "open hardware", so i've moved it to the right forum

 

try loading at a lower baudrate like 57600 and see if it transfers any better.  there is no error checking done on the contents of the LDR so any bit errors there will go unnoticed.

QuoteReplyEditDelete

 

 

2011-01-29 17:11:20     Re: No U-boot prompt after bfin-uclinux-ldr

Nathan Manning (UNITED STATES)

Message: 97759   

 

I'm not sure how to set the baud lower since it gets autonegotiated at the beginning of the transmission. "bfin-linux-uclibc-ldr" doesn't seem to have any arguments for setting baud.

 

I was able to use the -s option on my .ldr file and see that it only contains 12 blocks so maybe I should try a different precompiled .ldr file? I don't know if it'll help but I've attached the file if anyone can tell by looking.

 

 

 

Nathan

 

u-boot-bf526-ezbrd-uart-2010R1-RC2.ldr

QuoteReplyEditDelete

 

 

2011-01-29 18:54:31     Re: No U-boot prompt after bfin-uclinux-ldr

Mike Frysinger (UNITED STATES)

Message: 97760   

 

sure it does:

$ bfin-uclinux-ldr -l --help | grep baud

  -b, --baud            <baud>          * Set baud rate (default 115200)

QuoteReplyEditDelete

 

 

2011-01-29 20:06:41     Re: No U-boot prompt after bfin-uclinux-ldr

Nathan Manning (UNITED STATES)

Message: 97761   

 

Ok, not sure how I missed that, but thanks! That seems to work great...sort of.

 

 

 

When I load the precompiled u-boot-bf526-ezbrd-uart-2010R1-RC2.ldr it boots through and I get a prompt. The problem is, if I do the same exact thing with the one I compiled (simply u-boot.ldr) it doesn't work. I noticed the one I compile has 14 blocks and the precompiled one only has those 12.

 

Any ideas what I could be doing wrong here?

 

 

 

N

QuoteReplyEditDelete

 

 

2011-01-29 20:10:38     Re: No U-boot prompt after bfin-uclinux-ldr

Mike Frysinger (UNITED STATES)

Message: 97762   

 

did you change the config to specify uart boot ?

QuoteReplyEditDelete

 

 

2011-01-29 21:41:31     Re: No U-boot prompt after bfin-uclinux-ldr

Nathan Manning (UNITED STATES)

Message: 97763   

 

When I compiled u-boot I just used the default bf526-ezbrd_config. Is there a pre-existing config to load over the UART? Either way I guess that doesn't matter since I have the precompiled one running. That's good enough for me. The problem I'm having now is after booting and sending my u-boot.bin, I get the following.

 

bfin> go 0x01000000

## Starting application at 0x01000000 ...

 

U-Boot 2010.12-00000-g9deab9c (ADI-2011R1-pre) (Jan 28 2011 - 14:44:59)

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

Board: ADI BF526 EZ-Board board

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

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

RAM:   64 MiB

Flash: 4 MiB

Flash protect timeout at address 20004000 data 1520ff01

Flash protect error at address 20004000

*** Warning - bad CRC, using default environment

In:    serial

Out:   serial

Err:   serial

KGDB:  [on serial] ready

Warning: Generating 'random' MAC address

Net:   bfin_mac

Hit any key to stop autoboot:  0

 

I ran 'protect off all' in the prebuilt u-boot that loaded by bfin-uclinux-ldr before sending the file so I'm not sure why there are protection timeouts. If I run 'protect off all' in my u-boot that kermit sends over (i.e. after typing go 0x0100000) I get the following instead, which isn't any better:

 

bfin> protect off all

Un-Protect Flash Bank # 1

...................Flash unprotect timeout at address 200c0000 data 1520ff00

Flash unprotect error at address 200c0000

Command Sequence Error.

Block locked.

Vpp Low Error.

.Flash unprotect timeout at address 200d0000 data 1520ff00

Flash unprotect error at address 200d0000

Command Sequence Error.

Block locked.

Vpp Low Error.

 

Which one should I be running it in do you know?? If I ignore the practice rung and do the following

 

protect off all

 

loadb (followed by sending the file)

 

erase 0x20000000 0x200fffff

 

cp.b 0x1000000 0x20000000 $(filesize)

 

cmp.b 0x1000000 0x20000000 $(filesize)

 

I get no errors, so I change SW1 to boot from parallel flash but get nothing coming through in my kermit (bricked board)! Thanks for all the help by the way. Great discussion board!

 

N

QuoteReplyEditDelete

 

 

2011-01-29 21:59:54     Re: No U-boot prompt after bfin-uclinux-ldr

Nathan Manning (UNITED STATES)

Message: 97764   

 

UPDATE:

 

If I change SW1 to position 3 (for spi flash) it boots just fine!...except that I still have to deal with "ERROR: can't get kernel image!" as expected at this point. The problem is I can't really tell if it's booting my u-boot or some factory programmed one. The reason I care at all is because I'd like to be able to take a board from brick -> linux reliably. This is what it tells me when I run 'version'.

 

U-Boot 2009.11-svn2228 (ADI-2010R1-pre) (Jan 29 2010 - 10:51:37)

 

The date looks right, but is that the binary that gets loaded by the bfin-uclinux-ldr -l command or the one resulting from these commands?:

 

 

 

protect off all

 

loadb (followed by sending the file)

 

erase 0x20000000 0x200fffff

 

cp.b 0x1000000 0x20000000 $(filesize)

 

cmp.b 0x1000000 0x20000000 $(filesize)

 

When everything is said and done which boot mode should I be using to automatically boot through to my linux?

 

 

 

N

QuoteReplyEditDelete

 

 

2011-01-30 00:16:39     Re: No U-boot prompt after bfin-uclinux-ldr

Mike Frysinger (UNITED STATES)

Message: 97768   

 

there are no sep configs for boot modes.  you must edit the config file and select it yourself.

 

those warnings on bf526-ezbrd are known at this point.  they dont affect burning of u-boot into the start of flash though.

QuoteReplyEditDelete

 

 

2011-01-30 00:17:21     Re: No U-boot prompt after bfin-uclinux-ldr

Mike Frysinger (UNITED STATES)

Message: 97769   

 

loading over the uart only puts u-boot into external memory.  it in no way touches the flash.

QuoteReplyEditDelete

 

 

2011-01-30 13:30:28     Re: No U-boot prompt after bfin-uclinux-ldr

Nathan Manning (UNITED STATES)

Message: 97778   

 

Ok, well I guess I can just assume that it's my version then, despite what it says about locked blocks. As you have seen on the other forum I have put this issue to rest and moved on to the kernel. See you over there.

 

 

 

Thanks again for all the help.

 

 

 

Nathan

QuoteReplyEditDelete

 

 

2011-01-30 17:09:01     Re: No U-boot prompt after bfin-uclinux-ldr

Nathan Manning (UNITED STATES)

Message: 97788   

 

I'm sorry, but I just can't put this to rest yet. I just realized the date on the working spi u-boot was 2010 not 2011. That means it's not my code and was probably working the whole time, and I really need to be able to take a board from brick to working linux.

 

Current status is that I can boot the prebuilt uart.ldr version of u-boot using the ldr-uitls. That part is great. With that I can load any number of u-boot files into 0x01000000. If I choose to load u-boot.bin that I compiled from source and then run 'go 0x01000000' I see the following as expected.

 

## Starting application at 0x01000000 ...

U-Boot 2010.06 (ADI-2010R1-RC2) (Jan 30 2011 - 13:59:08)

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

Board: ADI BF526 EZ-Board board

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

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

RAM:   64 MiB

Flash: 4 MiB

*** Warning - bad CRC, using default environment

In:    serial

Out:   serial

Err:   serial

KGDB:  [on serial] ready

Warning: Generating 'random' MAC address

Net:   bfin_mac

Hit any key to stop autoboot:  0

bfin_mac: link down, check cable

Wrong Image Format for bootm command

ERROR: can't get kernel image! (As expected since I haven't loaded an kernel image yet)

 

The problem is if I copy the contents at 0x01000000 into 0x20000000 and then move SW1 to boot from parallel flash I get nothing. Perhaps I don't have the first stage u-boot in place? Can you tell me what address that should be at and how to load it?

 

 

 

Nathan

QuoteReplyEditDelete

 

 

2011-01-30 18:08:08     Re: No U-boot prompt after bfin-uclinux-ldr

Mike Frysinger (UNITED STATES)

Message: 97789   

 

please review the documentation:

http://docs.blackfin.uclinux.org/doku.php?id=bootloaders:u-boot:booting_methods#boot_rom_booting_u-boot

 

a .bin in flash wont work

QuoteReplyEditDelete

 

 

2011-01-30 19:25:23     Re: No U-boot prompt after bfin-uclinux-ldr

Nathan Manning (UNITED STATES)

Message: 97790   

 

Ok I can live with that. Now I can load either and see this when I choose the parallel flash.

 

U-Boot 2010.06 (ADI-2010R1-RC2) (Oct 20 2010 - 04:37:34)

 

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

 

That makes sense that it would boot just fine from RAM under a test run, but not from flash upon reset. I can't find much documentation about running in Bypass Boot ROM (for a .bin @ 0x20000000), but since this works with .ldr files I guess I don't need to.

 

 

 

Thanks again.

 

N

QuoteReplyEditDelete

 

 

2011-01-30 19:27:54     Re: No U-boot prompt after bfin-uclinux-ldr

Nathan Manning (UNITED STATES)

Message: 97791   

 

Turns out bf52x doesn't support Bypass Boot ROM. Wish I had seen that earlier.

Attachments

    Outcomes