beaglebone black, rtems,

Getting started with RTEMS on Beaglebone black - part I

Vijay K. Banerjee (thelunatic) Vijay K. Banerjee (thelunatic) May 01, 2019 · 2 mins read
Getting started with RTEMS on Beaglebone black - part I
Share this

This is the very first post on the blog and what better way to begin a blog than a getting started post.

Firstly we’ll walk through the process of building the RTEMS using RTEMS Source Builder to build the toolchain for arm and then build the beagleboneblack bsp.

There’s a sequence of commands that we’ll be following and also discuss the command optins that we used.

Building arm toolchain using RSB

1
2
3
mkdir -p $HOME/development
cd $HOME/development
git clone git://git.rtems.org/rtems-source-builder.git rsb

The above commands create a development directory and clone the rsb repo. Then we’ll move on to building the toolchain.

1
2
cd $HOME/development/rsb/rtems
../source-builder/sb-set-builder --prefix=$HOME/development/5 5/rtems-arm

The output will be something like this …

1
2
3
4
5
6
7
8
9
10
11
RTEMS Source Builder - Set Builder, 5 (98588a55961a)
Build Set: 5/rtems-arm
...
config: tools/rtems-gcc-7.4.0-newlib-3e24fbf6f.cfg
package: arm-rtems5-gcc-7.4.0-newlib-3e24fbf6f-x86_64-freebsd12.0-1
building: arm-rtems5-gcc-7.4.0-newlib-3e24fbf6f-x86_64-freebsd12.0-1
sizes: arm-rtems5-gcc-7.4.0-newlib-3e24fbf6f-x86_64-freebsd12.0-1: 4.651GB (installed: 879.191MB)
cleaning: arm-rtems5-gcc-7.4.0-newlib-3e24fbf6f-x86_64-freebsd12.0-1
....
Build Sizes: usage: 5.618GB total: 1.105GB (sources: 141.559MB, patches: 185.823KB, installed 989.908MB)
Build Set: Time 0:22:02.262039

Building The beagleboneblack BSP

To build the Board Support Package for beagleboneblack, we’ll first bootstrap the rtems and then configure and make the beagleboneblack.

1
2
3
4
mkdir -p $HOME/development/kernel
cd $HOME/development/kernel
git clone git://git.rtems.org/rtems.git
cd rtems

Now we have cloned the rtems source, we can move on to bootstraping the rtems source, but before that we must set the PATH to include the RTEMS bin directory, to ensure that the right tools are used during the build process.

1
2
export PATH=$HOME/development/5:$PATH
./bootstrap -c && $HOME/development/rsb/source-builder/sb-bootstrap

Then …

1
2
3
4
5
6
7
8
9
cd $HOME/development/kernel
mkdir beagleboneblack
cd beagleboneblack
../rtems/configure --prefix=$HOME/development/5 \
--target=arm-rtems5 \
--enable-rtemsbsp=beagleboneblack \
--enable-tests \
--enable-posix \
--disable-networking

After a while of processing, this will build the Board support package.

That was the end of the first part, in the next part we’ll discuss how to get an sd card image of an rtems exe file, and run it in the BBB. Thank you for stopping by and don’t forget to comment if you have any kind of questions related to the post.