ECE597 icassp 2010 Lab 2 The Boot Sequence

In the first lab you saw the BeagleBoard from a users point of view. In this lab we'll take a look at what's going on inside.

Connecting to the Beagle's serial port
If your Beagle is still running do this to shut it down.

Alternative Serial Program: Putty
With either method, you should be able to hit enter and see .---.                                          '---'---'--'--'--.  |---'  '-'-'-'-'                -'  |                '---'
 * |    | __  |  ---'| '--.|  .-'|     |     |
 * |    | __  |  ---'| '--.|  .-'|     |     |
 * |    | __  |  ---'| '--.|  .-'|     |     |

The Angstrom Distribution beagleboard ttyS2

Angstrom 2009.X-stable beagleboard ttyS2

beagleboard login: root root@beagleboard:~# Login as root.

Shutting Down and Rebooting on U-Boot
root@beagleboard:~# shutdown -r now As your Beagle reboots you will see: Texas Instruments X-Loader 1.4.2 (Feb 19 2009 - 12:01:24) Reading boot sector Loading u-boot.bin from mmc Which is then followed by U-Boot 2009.11-rc1 (Jan 08 2010 - 21:19:52) OMAP3530-GP ES3.1, CPU-OPP2 L3-165MHz OMAP3 Beagle board + LPDDR/NAND I2C:  ready DRAM: 256 MB NAND:  256 MiB In:   serial Out:  serial Err:  serial Board revision C4 Die ID #5444000400000000040365fa1400e007 Hit any key to stop autoboot: 0 OMAP3 beagleboard.org # Hit a key before it goes on to boot Linux. What has happened so far is:
 * 1) When power is first applied the Beagle jumps to a boot loader in the OMAPs ROM.
 * 2) This bootloader finds the SD card run runs a file called MLO.
 * 3) MLO is X-Loader with a couple things added.  The first bit of output above is from X-Loader.
 * 4) X-Loader looks and finds u-boot.bin and starts running it.

Das U-Boot is universal boot loader that is used on many embedded systems. You can find more information at http://www.denx.de/wiki/U-Boot. You can list the commands it understands: U-Boot source code is available is highly configurable, therefore the command list can be expanded or reduced to fit your application. Try: OMAP3 beagleboard.org # bdi arch_number = 0x0000060A env_t      = 0x00000000 boot_params = 0x80000100 DRAM bank  = 0x00000000 -> start   = 0x80000000 -> size    = 0x08000000 DRAM bank  = 0x00000001 -> start   = 0x88000000 -> size    = 0x08000000 baudrate   = 115200 bps This gives you some information about the board. It appears we have some RAM starting at.

Booting Linux
Here's what happens when you boot Linux: OMAP3 beagleboard.org # print bootcmd bootcmd=mmc init;fatload mmc 0 80300000 uImage;bootm 80300000 OMAP3 beagleboard.org # print bootargs bootargs=console=ttyS2,115200n8 console=tty0 root=/dev/mmcblk0p2 rw rootfstype=t Enter boot and Linux will start: OMAP3 beagleboard.org # boot mmc1 is available reading uImage

2996196 bytes read Image Name:  Angstrom/2.6.29/beagleboard Image Type:  ARM Linux Kernel Image (uncompressed) Data Size:   2996132 Bytes =  2.9 MB   Load Address: 80008000 Entry Point: 80008000 Verifying Checksum ... OK  Loading Kernel Image ... OK OK
 * 1) Booting kernel from Legacy Image at 80300000 ...

Starting kernel ...

Uncompressing Linux............................................................. [   0.000000] Linux version 2.6.29-omap1 (koen@dominion) (gcc version 4.3.3 (G9 [   0.000000] CPU: ARMv7 Processor [411fc083] revision 3 (ARMv7), cr=10c5387f ... [94371.964385] eth0: link up, 100Mbps, full-duplex, lpa 0xC5E1 [94372.195861] eth0: link up, 100Mbps, full-duplex, lpa 0xC5E1

.---.                                          '---'---'--'--'--.  |---'  '-'-'-'-'                -'  |                '---'
 * |    | __  |  ---'| '--.|  .-'|     |     |
 * |    | __  |  ---'| '--.|  .-'|     |     |
 * |    | __  |  ---'| '--.|  .-'|     |     |

The Angstrom Distribution beagleboard ttyS2

Angstrom 2009.X-stable beagleboard ttyS2

beagleboard login:

Homework
There are many options that can be passed to the kernel at boot time. One of the most common ones is to set the display resolution. Check http://elinux.org/BeagleBoardFAQ#Display_resolutions_.231 for details.