The Senic Hub: A Brief Technical Overview

We’ve been working on a brand new product that launches via Kickstarter on June 20th! We believe that the next evolution of smart home will be open-source. Here are a few key decisions we’ve made about how we want to build a more open system.

The Senic Hub is a Bluetooth Classic, Bluetooth Low Energy (BLE) and WiFi-enabled smart home hub that allows a user to connect to their smart devices (such as Sonos, Philips Hue etc). It also works together with N, our very own BLE controller for smart devices and significantly extends its usefulness by eliminating the need to having it connected to a smart phone or tablet.

We began building the Hub as a response to the amazing feedback of our first product Nuimo Control. You can read more about how we took this feedback and channeled it into the hub here. As we go into manufacturing the Hub, we wanted to do an overview of the technical decisions we have made while building the hub software for those interested in developing for the hub. Additionally, we hope that it might shed light on how companies can build their own smart home products open.

The Hub launches via crowdfunding on June 20th. It will work together with Nuimo Control, a BLE controller for smart devices.

The Senic Hub Prototype

Why Are We Building the Senic Hub?

The Senic Hub is the first major step in Senic’s vision to make technology that is not focused on ‘stickiness’ but on wellbeing for the human. At Senic, we see a big problem in companies creating apps and products that try to maximize the time that their users spent engaged with them. Instead we would like to promote wellbeing by creating connected devices, experiences, interfaces and systems that provide users with seamless technological experiences, without constantly demanding or even just encouraging their attention or focus.

Technical Overview of the Hub Software

When initially brainstorming how to build such a product we knew we would need to make it unobtrusive and easy to use but also easy to develop for and easy to keep up-to-date so we were confronted very early on with many important technical decisions. Some of these decisions were pretty clear or self-evident from the beginning, while others required a thorough understanding of both what our smart home users actually need but also what we are able to build with the fairly limited resources of a small startup. So before we dive into the details of how we ended up doing these things, we would like to take the time and outline our reasoning behind some of these decisions and key insights, requirements and learnings.

Hardware Platform: Nano Pi Neo

The Senic Hub is based on the NanoPi Neo platform, a powerful single-board computer equipped with an Allwinner H3 Quad-core 1.2GHz CPU and 512 MB DDR3 RAM.

The great thing about NanoPi Neo is that it’s better designed to be included in a product —than say, fruit-flavored boards such as the Raspberry Pi etc. which are explicitly targeted at hobbyists and students to experiment with.

NanoPi NEO

However, we found that satisfactory runtime stability, heat dissipation etc. were basically not achievable with those offerings.

We ship it with a high-speed memory card that stores the operating system, software stack and user data. More importantly, we extend it with carefully chosen high class WiFi and Bluetooth Low Energy / Bluetooth Classic dongles to provide the best possible wireless connectivity within the given physical restraints.

Operating System: Linux

For the Senic Hub, we wanted to use open-source components as much as possible, not just because we ourselves are avid users of and even contributors to Free and Open-Source Software. We also wouldn’t be able to stand behind a product that runs 24/7 in the homes and workplaces of our users and which contains proprietary code whose actual workings could not be verified by ourselves or third parties.

Note: During our evaluation phase we also considered using one of the many BSD flavors, specifically FreeBSD because it has a proven track record in the area of stability and security plus a long history of running on the tiniest of platforms long before the term “Internet of Things” was even coined. We did however find that while the H3 is pretty well supported, support for bluetooth is lagging behind and in the case of BLE currently non-existent and so we abandoned that approach.
Tux the Penguin, the mascot of Linux

This pretty much left us with Linux which offers a much broader support for such types of boards, most notably including BLE.

The NanoPi itself comes with various flavors of Linux, however, even the “light” versions weigh in with 400Mb and they all are geared toward end users who wish to use this platform as their personal development or experimentation field.

In the end we opted for building our own custom distribution using the well-established yocto project. This allows us to create a fine-tuned distribution without having to start from scratch and importantly we can still benefit from upstream mainline updates, be they security related, performance wise or new features.

Also, reducing the amount of code on the system as well as the number of running processes significantly reduces the attack surface for malware — we definitely want to do all we can to avoid the Senic Hub becoming part of the next botnet!

Programming Language: Python

Why did we decide that Python was the right programming language for the Hub? Actually, a better question might be: Why shouldn’t we use Python? If you take a deep dive into the open-source smart home world, you will find a number of do-it-yourself projects and Python is often the language of choice for these DIYers. This adoption of Python is primarily due to the sheer number of ready-made libraries and Python’s availability for many different operating systems.

In addition, Python is an easy to learn and extremely powerful and expressive as a programming language. The Python programming language is currently (as of June 2017) the fourth most popular programming language in the world. In the end it was important for us, to not just select a programming language that we were comfortable with but also for a significant amount of other people who then could contribute or simply hack the device or easily learn how to do so.

Home Controlling and Automation

Despite being a relatively new market, the smart home is already seeing tons of different connected devices such as speakers, light, switches, thermostats or electronic door locks from thousands of companies. The elephant in the room, though, is that each of these devices is using different communication channels and protocols. Keeping up with the sheer volume of new smart devices being launched is nearly impossible without a strong developer community.

The open source platform we use and build will have exactly that. It supports a massive number of devices that a large community of developers has contributed to and improved.

One of the reasons it can support such a large number is its extremely well thought-out modular structure. One of its core modules is a sophisticated event model and state machine that we can conveniently use for our own needs without having to re-invent the wheel.

Conclusion

Over the next weeks we will be making deep dives into each of these topics and many more as we continue to build up the software and community around the Senic Hub and launching the full documentation.

For questions, ideas or feedback please feel free to reach us at hi@senic.com.

For more information on our crowdfunding launch on June 20th, sign up here!

Would you like to read more content like this?
Subscribe to our newsletter below.
Thank you! Your submission has been received!
Oops! Something went wrong while submitting the form.

Further Reading

Made locally

Part 2/8: Time, People and Money - Exactly Why ‘Hardware is Hard’