Beaglebone Black

From Glacsweb Wiki
Jump to: navigation, search

Ubuntu

Setup using instructions from http://www.armhf.com/index.php/boards/beaglebone-black/.

Boot off an uSD card by holding the user button when booting.

wget http://s3.armhf.com/debian/raring/bone/ubuntu-raring-13.04-armhf-3.8.13-bone20.img.xz
xz -cd ubuntu-raring-13.04-armhf-3.8.13-bone20.img.xz > /dev/mmcblk1

Port Muxing

http://www.youtube.com/watch?v=wui_wU1AeQc gives a good overview, most of the following is taken from there.

Device Tree overlays are used to dymanically modify the device tree system without requiring a reboot.

dtb Device Tree Blob

dts Device Tree Source

dtbo Device Tree Blob overlay


Useful aliases

export SLOTS=/sys/devices/bone_capemgr.9/slots
export PINS=/sys/kernel/debug/pinctrl/44e10800.pinmux/pins
cat $SLOTS

Tells you what capes are connected

cat $PINS

Details of the pins provided on the system, column 3 is the mode.

DO NOT install the compiler from ubuntu repos as of 07/2013 it doesn't work instead do the following as root

wget -c https://raw.github.com/RobertCNelson/tools/master/pkgs/dtc.sh
sh dtc.sh

This will install a correct version of the compiler. Adapted from[1]


Serial Ports

Is totally different to the old beagle bone. See http://www.armhf.com/index.php/beaglebone-black-serial-uart-device-tree-overlays-for-ubuntu-and-debian-wheezy-tty01-tty02-tty04-tty05-dtbo-files/

cd /lib/firmware
wget http://s3.armhf.com/boards/bbb/dt/ttyO1_armhf.com-00A0.dtbo
wget http://s3.armhf.com/boards/bbb/dt/ttyO2_armhf.com-00A0.dtbo
wget http://s3.armhf.com/boards/bbb/dt/ttyO4_armhf.com-00A0.dtbo
wget http://s3.armhf.com/boards/bbb/dt/ttyO5_armhf.com-00A0.dtbo

Then to apply (needed after each boot)

echo ttyO1_armhf.com > /sys/devices/bone_capemgr*/slots
echo ttyO2_armhf.com > /sys/devices/bone_capemgr*/slots
echo ttyO4_armhf.com > /sys/devices/bone_capemgr*/slots
echo ttyO5_armhf.com > /sys/devices/bone_capemgr*/slots

WARNING: ttyO5 shares pins with the HDMI overlay – both cannot be active at the same time

Sleeping?

we really need to try sleep/wake see http://e2e.ti.com/support/arm/sitara_arm/f/791/t/274073.aspx echo +60 > /sys/class/rtc/rtc0/wakealarm echo mem > /sys/power/state