world leader in high performance signal processing
Trace: » loading

Initially Loading U-Boot

Flash memory on your development platform should come preloaded with a working U‑Boot. However, if you are either:

  • creating a new platform
  • have accidentally erased U-Boot
  • have created a bad U-Boot that does not boot and now have a bricked board
  • are unlucky and your platform did not come with U-Boot

You can bootstrap the board from your development system in a few different ways. Here we will document the two most common methods:

If your board has U-Boot up and running, you're reading the wrong document! U-Boot can update itself! Please read the upgrading document instead.

Programming Flash via JTAG

Before you can try programming U-Boot into the flash, you need to know what file to program. Please consult the binaries page for more information.

So you need to load an initial version of U-Boot onto the flash. There are currently a couple JTAG solutions known to work (there may be more!). Visit the JTAG page for more information.


You should be able to avoid picking a specific cable driver by letting urjtag discover the devices for you. Simply run:

jtag> cable probe

If an appropriate device is attached, then it should be found and selected automatically.

IGLOO Parallel Port JTAG

The IGLOO connects to the Blackfin board's JTAG via the parallel port on the development system. Once a JTAG connection is established, the appropriate U-Boot file can be loaded into flash memory.

Make sure you have the required software for flashing installed on your system. You can also consult the gdbproxy debugging page for information on installing gdbproxy.

Interactive Mode

Launch the jtag tool as root (or make sure your account has appropriate permissions to access the parallel port):

$ sudo jtag

Then run the commands (tweak according to your platforms/needs):

jtag> cable parallel 0x378 WIGGLER
jtag> detect
jtag> initbus bf533_stamp
jtag> detectflash 0x20000000
jtag> endian little
jtag> flashmem 0x20000000 /path/to/your/u-boot/file
jtag> instruction BYPASS
jtag> shift ir
jtag> quit

Batch Mode

If you pass one or more files to jtag, it will enter batch mode. In the batch mode, it will read and run instructions from the files passed to it as the arguments. It will be useful if you have to flash many boards.


The JTAG Blue is a different parallel port cable. Be sure to make the wiring modifications specified. Run same commands as the IGLOO JTAG, but start off with:

jtag> cable parallel 0x378 DLC5

Loading Via JTAG to Memory

You can also use JTAG to initialize the processor, load U-Boot into the external memory, and then start executing it from there. With U-Boot running on the processor, you can then update your flash/storage devices by using U-Boot itself. This process is documented in the debugging document.

Boot Via The UART

This feature is not available on all Blackfin variants, see boot mode availability.

Once you've verified your Blackfin processor supports this mode and you've hooked up to the correct UART (some Blackfins have multiple UARTs and not all are bootable), we can begin.

First you will need a U-Boot LDR which can boot over the UART. Precompiled U-Boot images are available already for some boards. Look for the LDR file with UART in its name for your board. If there is no precompiled image for your board available, you will have to make your own. Consult the porting document for how to change the boot mode for UART booting.

Next, you will most likely need to change the boot mode setting on your board so that the processor knows to load the LDR over the UART upon reset. Since this step is board specific, please consult the boards page. Once the boot mode is changed, you should hit the reset button a few times to make sure the processor is executing the Boot ROM.

Now we move on to the fun part. There are two utilities available for transmitting the LDR over your development system's serial port to the Blackfin processor:

  • ldr-utils - LDR utilities which will work on POSIX complaint operating systems (like Linux)
  • LdrViewer - Windows LDR viewer and loader

This will load U-Boot into external memory only, so once U-Boot is running on the board, you will need to program U-Boot into flash. Keep in mind that the U-Boot binary you used to boot over the UART will not work as you will need a different one that is configured for booting out of flash. See the upgrading page for more information.


The LDR Utils package is part of the Blackfin toolchain (on all hosts - including Windows™). Simply feed it the LDR to load, the serial device to load over, and then run a terminal program to connect to the board.

If this fails, try consulting the troubleshooting section.

Loading over the UART

The ldr-utils can be used to load applications over the UART (for those parts which support it over the BootROM).

$ bfin-uclinux-ldr -l /tftpboot/u-boot.ldr /dev/ttyUSB0 && kermit -l /dev/ttyUSB0 -b 57600 -C connect
Loading LDR /tftpboot/u-boot.ldr ... OK!
Opening /dev/ttyUSB0 ... OK!
Configuring terminal I/O ... OK!
Trying to send autobaud ... OK!
Trying to read autobaud ... OK!
Checking autobaud ... OK!
Autobaud result: 115200bps 49.766mhz (header:0xBF DLL:0x1B DLH:0x00 fin:0x00)
Sending blocks of DXE 1 ... [1/2] [2/2] OK!
Sending blocks of DXE 2 ... [1/6] [2/6] [3/6] [4/6] [5/6] [6/6] OK!
You may want to run minicom or kermit now
Quick tip: run 'ldrviewer <ldr> <tty> && minicom'
Connecting to /dev/ttyUSB0, 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.
bfin> version
U-Boot-1.1.3-ADI (Sep 28 2006 - 16:16:44)

 > bfin-uclinux-ldr -l /tftpboot/u-boot.ldr /COM1
Loading LDR /tftpboot/u-boot.ldr ... OK!
Opening /COM1 ... OK!
Configuring terminal I/O ... OK!
Trying to send autobaud ... OK!
Trying to read autobaud ... OK!
Checking autobaud ... OK!
Autobaud result: 115200bps 49.766mhz (header:0xBF DLL:0x1B DLH:0x00 fin:0x00)
Sending blocks of DXE 1 ... [1/2] [2/2] OK!
Sending blocks of DXE 2 ... [1/6] [2/6] [3/6] [4/6] [5/6] [6/6] OK!
You may want to run minicom or kermit now

Now, run your favorite Windows terminal program.


  1. You'll need to install the LdrViewer program.
  2. Setup the terminal program on your Windows machine.
  3. Connect a serial cable from the target board (the Blackfin) to your PC host.
  4. Make sure the terminal program is not actually connected to the serial port, but waiting for you to tell it to connect. The disconnect button should be greyed out.

  5. Run the LdrViewer application.
  6. Open the U-Boot LDR file by selecting in the menu ToolsUART Boot….
  7. Select the right COM port and set the baud rate to 115200 baud.
  8. Press the Test Port button.

  9. Push the Reset button on the board to force it into a sane state.
  10. Press [AutoBaud] button, before you send the LDR file, make sure you get the same result as the following picture.

  11. Press [Send DXE] button to send the file which is already opened, after all of bytes transferred, you can get the feedback from the target.

  12. Now close LdrViewer, open the terminal and connect to the serial port, you can see the u-boot has already started up successfully. Hit enter a few times to get a prompt.


If the load fails at the Trying to read autobaud or Checking autobaud steps, this boils down to a communication problem with the Blackfin board. Some things that people commonly make mistakes with:

  • specifying the incorrect tty device on the host (/dev/ttyS0 or /dev/ttyUSB0 or …)
  • a different host terminal program is open that is using the tty device (minicom or kermit or …)
  • you are connected to the incorrect UART on the Blackfin (some Blackfin's can boot from multiple UARTs, others from only one - check the datasheet)
  • make sure the boot mode is set properly
  • make sure your board's switch and jumper settings are correct
  • hit reset a few times so that you are sure the Boot ROM is waiting to read the UART
  • your serial cable is the incorrect type
  • if you're using a USBRS232 converter, make sure it isn't a cheap/crappy one (many of the cheap ones cannot transfer at higher bauds, even 57600+, without random transmission errors) as the Boot ROM cannot tolerate even one bit error

A low level test to see if the blackfin can communicate with the host PC is:

  1. start up your favorite communications application, pointing it to the same serial port as you where using for the ldr utils:
    rgetz@pinky:~> kermit -l /dev/ttyUSB0 -C connect
    Connecting to /dev/ttyUSB0, 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.
  2. hit the reset button on the Blackfin
  3. press the space bar in the serial port session a few times
  4. the Blackfin should respond with one or two unprintable bytes (the exact bytes displayed might differ based on your setup)

If you get back something every time you hit a key (and aren't resetting the processor), your connection is probably in loop back mode. Check your cable and the UART jumpers/switches on the board as mentioned above.

If the Blackfin responds just once per reboot, then things should be OK. If you don't see any output, check the above listed issues.

ensure that you close your terminal program that you were using for testing before trying to run the bfin-*-ldr util again.

Visual DSP++ ADI ICE

Using VisualDSP++ is not supported by anyone on this site - if you have questions - you need to go to the place that you got your copy of VisualDSP++ from. this information is provided as a service - if it doesn't work for you - let us know, and we will remove it.

The VDSP Flash Programmer expects files to be in the hex format by default, but it can be told to program a binary file as well. For information on how to convert to the hex format, see the binaries page for more information.

First launch Visual DSP on your Windows system and connect to the board with your ICE. Now, launch the Flash Programmer utility by going to the Tools menu and selecting Flash Programmer.

Select the driver that is appropriate for your board and the flash and load it.

In the files section, select the U-Boot file that you're going to program. Make sure the format radio buttons match that of the file you've selected. Ensure that the radio button “Erase all” is selected. Then click on the Load File button. The bar at the bottom of the screen should start to fill up showing the status of the process. When this is done you should be able to reset your board and see the U-Boot start up screen on your terminal program.

The BF533 STAMP board does not have its own flash driver in VDSP. Use the one for the BF537 EZKIT as they have the same type of flash.