IOTA
$0.29561 17.79%

OpenEmbedded: IOTA CClient and a Raspberry Pi

Building the image

Let’s get our hands dirty. Follow the next steps to build a image core-image-base to the Raspberry Pi.

Prepare your host for yocto development. Refer to Yocto’s official documentation for more details on setting up.

Assuming you are using Ubuntu (16.04 or 18.04):

$ sudo apt-get install gawk wget git-core diffstat unzip texinfo gcc-multilib build-essential chrpath socat cpio python python3 python3-pip python3-pexpect xz-utils debianutils iputils-ping python3-git python3-jinja2 libegl1-mesa libsdl1.2-dev xterm

2. Clone poky. We are going to use the warrior branch of the Yocto Releases:

$ mkdir ${HOME}/yocto$ cd ${HOME}/yocto$ git clone git://git.yoctoproject.org/poky -b warrior

3. Clone the other OE layers (warrior branch for meta-openembedded and meta-raspberry pi, tutorial-rpi for meta-iota):

$ git clone https://github.com/openembedded/meta-openembedded -b warrior$ git clone https://github.com/agherzan/meta-raspberrypi -b warrior$ git clone http://github.com/bernardoaraujor/meta-iota -b tutorial-rpi

4. Start the build environment:

$ source poky/oe-init-build-env

5. Inform BitBake about our layers by adding them to conf/bblayers.conf:

...BBLAYERS ?= " \ ${HOME}/yocto/poky/meta \ ${HOME}/yocto/poky/meta-poky \ ${HOME}/yocto/poky/meta-yocto-bsp \ ${HOME}/yocto/meta-openembedded/meta-oe \ ${HOME}/yocto/meta-openembedded/meta-networking \ ${HOME}/yocto/meta-openembedded/meta-python \ ${HOME}/yocto/meta-raspberrypi \ ${HOME}/yocto/meta-iota \ "

6. Add the following lines to the bottom of conf/local.conf:

IMAGE_INSTALL_append = " c-iota-workshop"

The line above will make sure that the c-iota-workshop package is included in the image.

Raspberry Pi 0, 1, 2 and CM will have UART console enabled by default. RaspberryPi 0 WiFi and 3 do not, so for those versions you need to add the following line to conf/local.conf:

ENABLE_UART = "1"

If your RPi has WiFi and you want to take advan...

Continue on medium.com
Recent news
No posts found