U Boot for Raspberry Pi 2 - Raspberry Pi Forums


hi everyone,

working on configuring rpi 2 hardware boot via u-boot , execute given user code in process. since new rpi, have been reading resources such -

1. http://elinux.org/rpi_u-boot
2. http://arrizza.org/wiki/index.php/rpi_u-boot

however, believe these have been written keeping in mind rpi 1, compared recent rpi 2 hardware. read post on u-boot fdt on pi 2 (viewtopic.php?f=29&t=108217), don't seem understand well.

here's have done far -

boot given kernel image/boot-loader on sdcard, took following steps in preparing sdcard -

1. format sdcard in fat32 partition called boot
----- used sdformatter program on mac os x machine this
----- running ubuntu 12.04 lts (using parallels desktop on mac os x); tried use conventional "dd program" in command line (http://elinux.org/rpi_easy_sd_card_setu ... mmand_line), failed format sdcard)
2. once sdcard correctly formatted, flash sdcard pre-built kernel images of raspbian/freebsd (for testing), used imagewriter program on ubuntu.
----- have been able setup rpi 2 hardware aforementioned images , observe user-login shell program on connected hdmi display.

prepare sd-card u-boot.bin binary, did step 1 , continued following various steps indicated on page - http://elinux.org/rpi_u-boot

prepared own u-boot.bin binaries using source code on stephen warren's repository (git://github.com/swarren/u-boot.git) provides support usb , networking. however, have failed observe u-boot prompt on hdmi display.

referred primary repository u-boot (git://git.denx.de/u-boot.git) master branch , appended following line in rpi-common.h (/include/configs) enable usb keyboard support -
#define config_usb_keyboard

compiled bootloader , build new set of binaries, failed observe character (that typed on keyboard) appear on u-boot prompt.
u-boot provides support stop auto-boot process entering keystroke 2s of initialisation. observed no character response key pressed on keyboard. currently, usb keyboard connected 1 of powered usb inputs on rpi 2 board.

here understanding of bootprocess rpi -

1. when raspberry pi first turned on, arm core off, , gpu core on. @ point sdram disabled.
gpu starts executing first stage bootloader, stored in rom on soc. first stage bootloader reads sd card, , loads second stage bootloader (bootcode.bin) l2 cache, , runs it.
2. bootcode.bin enables sdram, reads gpu firmware (start.elf)
3. start.elf reads config.txt, cmdline.txt , kernel7.img

configure board u-boot, downloaded firmware files following repository -
https://github.com/raspberrypi/firmware ... aster/boot

since rpi 2 hardware, copied following files sdcard -
1. bcm2709-rpi-2-b.dtb (device tree file gpu)
2. start.elf
3. bootcode.bin
4. fixup.dat
5. u-boot.bin
6. config.txt
7. cmdline.txt

unclear use of file [1,4,7]; great if elaborated on well. file 6 contains single line (kernel=u-boot.bin) tells elf file kernel image. understanding that, default in rpi 2, kernel7.img file refers default kernel image.

great if me understand boot process better , point have gone wrong. have been stuck on over 5 days now.

hi there,

i'm experimenting rpi2 , have had similar issues. here suggestions:
- use serial console usb cable (about $5 on amazon). can plug in cable laptop , connect rpi's serial console
- if don't feel waiting or buying usb cable, create "boot.scr.uimg" file. way first create file named "boot.scr". file contain u-boot commands set environment variables (bootargs) , commands load kernel , fdt file. using "mkimage" command can create "boot.scr.uimg" "boot.scr". bootload (u-boot.bin) file , use boot automatically. i'm using original noobs sd card , realized that, although kernel image , u-boot.bin on partition 5 (mmcblk0p5), "boot.scr.uimg" file needs on partition 1 (on sd card, it's recovery partition). source more specific details blog post https://blog.night-shade.org.uk/2015/05 ... yp-enabled. pay close attention root directive , partitions in fatload command (in case partitions different).

hope helps. cheers!


raspberrypi



Comments

Popular posts from this blog

opencv3, tbb and rasp pi 2 - Raspberry Pi Forums

small ethernet problem - Raspberry Pi Forums

Multithumb configuration params not working? - Joomla! Forum - community, help and support