an operating system for connected microcontrollers
by Sergey Lyubka
for Dublin IoT & BigData meetup
What is an IoT
Connecting a computer to a thing
Grabbing data from a thing and reporting to the Internet
Controlling a thing via Internet
What a computer could be?
A workstation like this laptop!
Big
Eats a lot of power
Expensive: ~ 1k EUR
A single board computer
Smaller
Eats less power
Cheaper: ~30 EUR
A microcontroller
Very smal
Low power
Very cheap: ~3 EUR
Software development process
Using a well known OS like Linux
Many established, polished software frameworks
System requirements
What is the minimum RAM a Linux system requires?
What is the disk/RAM usage of a minimal node.js application?
What is the RAM usage of a single mutual-TLS connection?
Some rough numbers
Node.js (*)
Disk
RAM
11M
7.6M
RPI3
Flash
RAM
(depends)
1G
RAM
50K
TLS connection (*)
ESP8266
an MCU costs < 1 EURÂ
a dev board costs < 3 EUR
RAM available to the application: 50k
Forget about prototyping with JS and mutual TLS?
No
(demo)
Mongoose OS
Targets commercial connected products
License: dual, GPLv2 and commercial
Provides functionality that is usually required by the commercial product: provisioning, OTA updates, remote management, cloud connectivity, security, Arduino compatibility, etc
Uses underlying native SDK - for example, ESP-IDF on ESP32
The environment is C/C++
A restricted JavaScript engine exists to allow scripting