iota.py

Also known as PyOTA, iota.py is is the official Python library for the IOTA Core. It implements both the official API, as well as newly-proposed functionality (such as signing, bundles, utilities and conversion).

PyOTA is compatible with Python 3.7, 3.6, 3.5 and 2.7.

In terms of integration into meta-iota, the biggest challenge for this library was the fact that many Python dependencies were not provided by the standard OpenEmbedded or Poky distributions. As a workaround, I had to write a few extra recipes, namely:

I also borrowed a few recipes from meta-jupyter. This is not the cleanest approach. However, since we don’t do anything related to Jupyter notebooks or IPython, this is better than setting a layer dependency. I made sure to mention the original layer on all recipe headers.

All these extra recipes can be found at meta-iota/meta-tangle/recipes-python/.

Although PyOTA does support Python 2.7, the Python community has officially declared Discontinuation of 2.7 from 01/01/2020. So I decided to only support PyOTA for Python 3 on meta-iota.

The recipe for PyOTA is meta-iota/meta-tangle/recipes-iota/iota.py/python3-pyota_2.1.0.bb. Its behavior is relatively simple, only inheriting pypi + setuptools and setting runtime dependencies for other required Python Packages.

Since a library doesn’t really do anything by itself, I made sure to include a recipe with usage examples based on the python-iota-workshop repository. You can find the recipe at meta-iota/meta-tangle/recipes-iota/iota.py/python-iota-workshop_git.bb. Its behavior is also pretty simple, the most crucial part being the declaration of the appropriate Python Packages as runtime dependencies, namely python3-pyota , python3-zmq , and python3-core .

It’s important to note that PyOTA’s C extension and Local PoW features are currently not enabled in the recipe.

iota.go

This is the official Go client library, which allows you to do the following:

Create transactions

Read transactions

Sign transactions

Generate addresses

My initial idea for integrating iota.go into meta-iota was to follow the same approach I used for CClient, MAM and PyOTA. In other words, I wanted to have one BitBake recipe for the library itself (iota.go), followed by a recipe based on the go-iota-workshop examples.

I started this approach by following ITNEXT’s (really well written) guide Getting Go onto Internet of Things. I quickly realized I would have to follow the approach described in the article section “Multi-package Recipes”, where I would manually list each iota.go dependency repository in SRC_URI , followed by a SRCREV_* setting the commit/version/tag for each dependency.

So that’s what I did. The iota.go recipe can be found at meta-iota/meta-tangle/recipes-iota/iota.go/iota.go_1.0.0.bb, while the example recipe can be found at meta-iota/meta-tangle/recipes-iota/iota.go/go-iota-workshop_git.bb.

This simple example worked fine, but I quickly ran into problems when I started integrating Hornet. The problem with this initial approach is how BitBake processes the Golang compiler environment internally. If an application recipe sets a dependency that the library (iota.go) also depends on, but with different versions, the Golang environment doesn’t know how to handle both. The only way to handle this problem is by not having a separate recipe for the iota.go API, which means iota.go_1.0.0.bb is not really needed. This will be clearer in the next section, where I describe the Hornet BitBake recipe.

Hornet

Hornet is a lightweight alternative to IOTA’s fullnode software IRI, written in the Go Programming Language. Since Go compiles to native binaries, and is designed for concurrency and simplicity, the skilled Hornet development team was able to achieve a really good performance when compared to the Java-based IRI implementation.

This performance improvement makes Hornet a good candidate for Embedded Systems, with a few restrictions:

the board needs at least 1GB of RAM to run a Hornet node.

without a Linux OS, there will not be a Go runtime environment.

As described in the previous section, I was not able to use the iota.go_1.0.0.bb recipe for Hornet, because of conflicting versions between dependencies of the API and the application itself. Instead, I had to do the cumbersome task of manually listing every single dependency in the SRC_URI field of the recipe, and setting SRCREV_* with the commit/version/tag for each dependency.

You can find this (huge) dependency list at meta-iota/meta-tangle/recipes-iota/hornet/hornet_0.3.0.inc. The .inc dependency means it is included by a .bb recipe).

The BitBake recipe meta-iota/meta-tangle/recipes-iota/hornet/hornet_0.3.0.bb does a few things, namely:

BitBaked Hornet has been tested on Raspberry Pis 3 and 4 by myself and by the IOTA Community, without any major issues reported so far.

honeycombOS

honeycombOS is an Embedded Linux Distribution tailored for IOTA nodes, clients and Tangle related tools. It is mainly based on Poky, which is the reference distribution of the Yocto Project.

honeycombOS was introduced with the article ꙮ honeycombOS 🍯 the IOTA Embedded Linux Distribution.

I believe honeycomOS is my biggest contribution to the IOTA Community so far. That is because it avoids all unnecessary bloatware shipped with popular distributions (e.g.: DietPi, Armbian and Raspbian) that have no use for IOTA nodes. All CPU power is saved for Tangle related computations.

For the moment, there’s no Graphical User Interface (GUI), and everything needs to be done via terminal. I do however have a few ideas for writing a lightweight GUI in the future, in order to improve UI/UX and lower the technical barrier for the average user.

The distribution is created with a few recipes and configuration files hosted under meta-iota/meta-honeycomb/.

The idea behind the name honeycombOS is to create synergy with the projects named Bee, Hornet and GoShimmer. If the nodes are the insects making honey, then their home is the Operating System.

honeycombOS brand

I created a brand for honeycombOS, which received some very helpful tips from Sabri Goldberg. It follows a similar dot pattern to the IOTA logo, but forming hexagon shapes representing a honeycomb.

Acknowledgements

As this is my final report for the project, I would like to demonstrate my special gratitude to: