How to flash the RidgeRun's u-boot in a new board
Introduction (UNDER CONSTRUCTION)
The latest Stable Release of the RidgeRun SDK called 2011Q2 comes with a new installer system that give to the user a high flexibility and a huge variety of installation modes such as SD, NAND and JFFS2. However in order to achieve this features a new u-boot system must be placed in the board so it will support the features available.
Since a new board comes with the factory's default u-boot, it is necessary to flash the RidgeRun's u-boot in the board before continue using the SDK, but how can we install an image into the board using the RidgeRun's SDK if the board doesn't have the RidgeRun's u-boot installed?
Now we are going to explain how to flash the RidgeRun's u-boot for the following boards:
- LeopardBoard DM365
- TI DM365 EVM
- OMAP35x TOBI
Flashing the u-boot into a LeopardBoard DM365
In order to flash the RidgeRun's SDK into a LeopardBoard DM365 you need to follow the next steps:
1. Create or download a pre-built SD card image for LeopardBoard DM365.
You can create a SD card image following the steps listed in How to boot a board from a SD card or if you prefer you can download any of the pre-built SD card images available in LeopardBoard DM365 pre-built images. You need to be registered in order to get access into the link provided.
2. Once you have the image recorded into a SD card the next step is to boot the board from SD card as is also described in How to boot a board from a SD card.
3. When the board is booting, stop it in the u-boot's count down as is shown below.
U-Boot 2010.12-rc2 (Jun 20 2011 - 09:33:44) Cores: ARM 297 MHz DDR: 243 MHz I2C: ready DRAM: 128 MiB NAND: 256 MiB MMC: davinci: 0, davinci: 1 Net: Ethernet PHY: GENERIC @ 0x00 DaVinci-EMAC Hit any key to stop autoboot: 0 DM365 LEOPARD #
4. Exit from your minicom/termnet session.
5. Set the Attached board on communication port option in the configuration window (make config).
-> Installer Configuration -> Firmware deployment mode (<choice> [=y]) -> Attached board on communication port
6. Build your SDK.
7. Once your SDK has been built, install the new bootloader into the board by running the following command:
You will see a terminal output such as the shown below:
$ make installbootloader Ridgerun Linux SDK Board configuration: Leopard Board DM365 Multi-core machine, using 3 out of 6 cores for building Installation system of uboot images over TFTP for host 10.251.101.4 Be sure u-boot is running on 10.251.101.56:3001 and no process (like termnet) is using it Press return to continue... Performing handshake with u-boot... Trying to identify NAND block size... detected 0x20000 Trying to identify NAND Page size... detected 2048 Loading upgrade bootloader... Uboot <= setenv bootcmd Uboot <= saveenv Configuring the network... Uboot <= setenv autoload no Uboot <= dhcp Uboot <= setenv serverip 10.251.101.4 Uboot <= setenv autostart no cp -f /home/mmadrigal/devdirs/DM365LEO-Stable/images/bootloader /srv/tftp/bootloader.mmadrigal.DM365LEO-Stable.leopard Uboot <= tftp 0x82000000 bootloader.mmadrigal.DM365LEO-Stable.leopard Running upgrade bootloader... Uboot <= icache off Uboot => go 0x82000000 Performing handshake with u-boot... Restoring previous bootcmd value Uboot <= setenv bootcmd nboot 0x82000000 0 0x400000 Uboot <= saveenv Building UBL image for flash... Building U-boot image for flash... Loading UBL Configuring the network... Uboot <= setenv autoload no Uboot <= dhcp Uboot <= setenv serverip 10.251.101.4 Uboot <= setenv autostart no cp -f /home/mmadrigal/devdirs/DM365LEO-Stable/images/ubl_nand.nandbin /srv/tftp/ubl_nand.nandbin.mmadrigal.DM365LEO-Stable.leopard Uboot <= tftp 0x82000000 ubl_nand.nandbin.mmadrigal.DM365LEO-Stable.leopard Erasing UBL flash space... Uboot <= nand erase 0x20000 0x20000 Uboot <= nand write.ubl 0x82000000 0x20000 0x20000 Loading U-Boot Configuring the network... Uboot <= setenv autoload no Uboot <= dhcp Uboot <= setenv serverip 10.251.101.4 Uboot <= setenv autostart no cp -f /home/mmadrigal/devdirs/DM365LEO-Stable/images/bootloader.nandbin /srv/tftp/bootloader.nandbin.mmadrigal.DM365LEO-Stable.leopard Uboot <= tftp 0x82000000 bootloader.nandbin.mmadrigal.DM365LEO-Stable.leopard Erasing U-Boot flash space... Uboot <= nand erase 0x320000 0x60000 Uboot <= nand write.ubl 0x82000000 0x320000 0x60000 Restarting u-boot Performing handshake with u-boot... Installation completed
8. Once the process has finished turn off the board and turn off the dip switch 2 in the board so you will be able to boot from NAND using the new RidgeRun's u-boot.