Changes between Initial Version and Version 1 of Boards/Beagle Board

Oct 3, 2017, 4:08:44 AM (3 years ago)
Chris Johns

Initial page.


  • Boards/Beagle Board

    v1 v1  
     1= Beagle Board Support =
     3[[TOC(Boards/Beagle Board, depth=4)]]
     5The page details how to run RTEMS on a [http:// Beagle Board] family of boards. The Beagle Boards are supported by [ U-Boot] and [ U-Boot] can boot RTEMS. Please refer to the U-Boot documentation and the internet for documentation and example on using U-Boot.
     7This page provide details on updating a Beaglebone Black board. Please update and support for other Beagle Boards.
     9= Consoles =
     11RTEMS uses the console for a booting and as the primary interface. These are UARTs on the Beagle Boards. We recommend you have a working console and the default Linux images from the Beagle Board project use the UART consoles when booting and initialising.
     13== Beagleboard-MX Console ==
     15The Beagleboard-MX has a standard female DB9 RS-232 connector. You will need an RS-232 to USB converter.
     17== Beagle Bone Console ==
     19The Beaglebone Black supports the standard 6pin inline UART TTL connector. You can purchase a TTL to USB cable that plugs onto this header. Please refer to the board's user manual for the details of the cable and how to connect it.
     21= Boot Loader =
     23U-Boot is the boot loader for the Beagle Board family. The following is for each board in the family.
     25== Beaglebone Black ==
     27The Beaglebone Black has a TI Sitara AM3358BZCZ100 processor and it configured to boot from eMMC memory. The factory ships the board with U-Boot, Linux kernel, and a full file system in the eMMC memory. You need to update the eMMC image to latest for the best results.
     29To control the boot we need a recent U-Boot and a suitable `uEnv.txt` file on the SD card. The following procedure will create a suitable SD card image with a current U-Boot and `uEnv.txt` file.
     31To boot using TFTP the `uEnv.txt` contents is:
     36uenvcmd=echo Booting RTEMS BBB from net; set autoload no; dhcp; set serverip; set tftpdstp 55567; tftpboot bbb/rtems.img; bootm; reset;
     39The server IP address is the host machine running the `rtems-test` command.
     41=== Updating the eMMC ===
     43We recommend you upgrade this software to the latest found at At the time of writing this the latest 2G image is [ 2G Beaglebone Black Debian 9.1 2017-09-24]. Make sure you get a 2G image as this is the size of the eMMC on the a RevB Beaglebone Black. You need to use a 2G or great SD card.
     46$ xz -d bone-debian-9.1-lxqt-2gb-armhf-2017-09-24-2gb.img.xz
     47$ dd if=bone-debian-9.1-lxqt-2gb-armhf-2017-09-24-2gb.img of=/dev/da0 bs=1m
     481700+0 records in
     491700+0 records out
     501782579200 bytes transferred in 180.028664 secs (9901641 bytes/sec)
     53Place the SD card into the Beaglebone Black board and hold the Boot switch and turn the power on. The Boot switch is `S2` and is located at the same end of the board as the SD card, HDMI and USB master connectors. Hold the Boot button on until the leds all turn on. This takes a few seconds. If booting from the SD card the console will start showing something like:
     56U-Boot SPL 2017.09-00003-g11d92ba68a (Sep 21 2017 - 10:40:17)
     57Trying to boot from MMC1
     60U-Boot 2017.09-00003-g11d92ba68a (Sep 21 2017 - 10:40:17 -0500), Build: jenkins-github_Bootloader-Builder-602
     62CPU  : AM335X-GP rev 2.1
     63I2C:   ready
     64DRAM:  512 MiB
     65No match for driver 'omap_hsmmc'
     66No match for driver 'omap_hsmmc'
     67Some drivers were not found
     68Reset Source: Power-on reset has occurred.
     69MMC:   OMAP SD/MMC: 0, OMAP SD/MMC: 1
     70Using default environment
     72Board: BeagleBone Black
     75Once the system has booted you will have a Beagebone Black login:
     78Debian GNU/Linux 9 beaglebone ttyS0
     79 Debian Image 2017-09-24
     84default username:password is [debian:temppwd]
     86beaglebone login:
     89Login as the default user using the provided password and then change to the `/boot` directory and open as root using `sudo` the u-Boot's user environment file (`uEnv.txt`) to edit, in this case using `vi`:
     92debian@beaglebone:~$ cd /boot
     93debian@beaglebone:/boot$ sudo vi uEnv.txt
     96At the end of the file is the Generic eMMC Flasher support. Uncomment the line to have:
     99##enable Generic eMMC Flasher:
     100##make sure, these tools are installed: dosfstools rsync
     104Save the file and shutdown:
     107debian@beaglebone:/boot$ sudo shutdown -h now
     108[  529.915200] reboot: Power down
     111Remove the power from the board and again apply power while pressing the Boot switch as you did before. This time the console will show the eMMC quit flasher procedure:
     115==> Loaded
     120Writing bootloader to [/dev/mmcblk1]
     122==> Figuring out options for SPL U-Boot copy ...
     123===> Will use : count=1 seek=1 conv=notrunc bs=128k
     124==> Figuring out options for U-Boot copy ...
     125===> Will use : count=2 seek=1 conv=notrunc bs=384k
     126==> Copying SPL U-Boot with dd if=/opt/backup/uboot/MLO of=/dev/mmcblk1 count=1 seek=1 conv=notrunc bs=128k
     1280+1 records in
     1290+1 records out
     13075080 bytes (75 kB, 73 KiB) copied, 0.0239506 s, 3.1 MB/s
     132==> Copying U-Boot with dd if=/opt/backup/uboot/u-boot.img of=/dev/mmcblk1 count=2 seek=1 conv=notrunc bs=384k
     1341+1 records in
     1351+1 records out
     136397640 bytes (398 kB, 388 KiB) copied, 0.188179 s, 2.1 MB/s
     138Writing bootloader completed
     142Partitionning /dev/mmcblk1
     144sfdisk: [2.26.x or greater]
     145==> sfdisk parameters:
     146sfdisk: [sfdisk from util-linux 2.29.2]
     147sfdisk: [sfdisk --force /dev/mmcblk1]
     148sfdisk: [4M,,L,*]
     149==> Partitionning
     151Checking that no-one is using this disk right now ... OK
     153Disk /dev/mmcblk1: 1.8 GiB, 1920991232 bytes, 3751936 sectors
     154Units: sectors of 1 * 512 = 512 bytes
     155Sector size (logical/physical): 512 bytes / 512 bytes
     156I/O size (minimum/optimal): 512 bytes / 512 bytes
     158>>> Created a new DOS disklabel with disk identifier 0xb759f922.
     159/dev/mmcblk1p1: Created a new partition 1 of type 'Linux' and of size 1.8 GiB.
     160/dev/mmcblk1p2: Done.
     162New situation:
     164Device         Boot Start     End Sectors  Size Id Type
     165/dev/mmcblk1p1 *     8192 3751935 3743744  1.8G 8[   63.419843]  mmcblk1: p1
     1663 Linux
     168The partition table has been altered.
     169Calling ioctl() to re-read partition table.
     170Syncing disks.
     173==> Partitionning Completed
     174==> Generated Partitions:
     176Disk /dev/mmcblk1: 1.8 GiB, 1920991232 bytes, 3751936 sectors
     177Units: sectors of 1 * 512 = 512 bytes
     178Sector size (logical/physical): 512 bytes / 512 bytes
     179I/O size (minimum/optimal): 512 bytes / 512 bytes
     180Disklabel type: dos
     181Disk identifier: 0xb759f922
     183Device         Boot Start     End Sectors  Size Id Type
     184/dev/mmcblk1p1 *     8192 3751935 3743744  1.8G 83 Linux
     189Preparing future rootfs to receive files
     192==> Formatting rootfs with mkfs.ext4  -O ^metadata_csum,^64bit /dev/mmcblk1p1 -L rootfs
     195mke2fs 1.43.4 (31-Jan-2017)
     196Discarding device blocks: done                           
     197Creating filesystem with 467968 4k blocks and 117120 inodes
     198Filesystem UUID: 1aa2f1b9-7a7c-4dbc-9d36-c7e01ce19540
     199Superblock backups stored on blocks:
     200        32768, 98304, 163840, 229376, 294912
     202Allocating group tables: done                           
     203Writing inode tables: done                           
     204Creating journal (8192 blocks): done
     205Writing superblocks and filesystem accounting information: done
     208==> Formatting rootfs: /dev/mmcblk1p1 complete
     209==> Creating temporary rootfs directory (/tmp/rootfs)
     210==> Mounting /dev/mmcblk1p1 to /tmp/rootfs
     211[   77.717437] EXT4-fs (mmcblk1p1): mounted filesystem with ordered data mode. Opts: (null)
     216Copying: Current rootfs to /dev/mmcblk1p1
     218==> rsync: / -> /tmp/rootfs
     222The leds show activity. Once the procedure has finished remove the power and remove the SD card:
     225[  513.490441] reboot: Power down
     226[  513.493962] System will go to power_off state in approx. 1 second
     229Apply power and watch the board boot from the updated eMMC memory.