When we talk about open source hardware, we often think about the Raspberry Pi and other community-backed single board computers running Linux. Yet all these communities were modeled on the success of the 14-year-old Arduino project, in which Linux has been only tangentially involved, and only over the past four years. The two platforms should grow closer, however, now that Arduino has extended its Arduino Create development environment to support Linux on x86 platforms.
With the new Linux support, “users are now able to program their Linux devices as if they were regular Arduinos,” says Arduino. Arduino Create works in concert with embedded Linux distributions – initially Ubuntu or Intel’s Wind River Pulsar Linux – to let developers load Arduino sketches to control lower level interfaces to sensors and other Internet of Things peripherals.
Arduino Create was unveiled as a private beta in May 2016, intended as a modern, web-based companion application – and perhaps and eventual replacement – for the desktop-based Arduino IDE. The software provides a browser plugin, letting developers upload sketches to any connected Arduino board from the browser. It features a web editor, as well as cloud-based sharing and collaboration tools.
Arduino Create enables program-to-program, and program-to-cloud communications via the MQTT protocol. This is implemented with a new open source Arduino Connector program.
UP Squared IoT Grove Development Kit
The Linux-ready version of Arduino Create is debuting on a version of Aaeon’s UP Squared (UP2) hacker SBC called the UP Squared IoT Grove Development Kit. In addition to the SBC, which runs Ubuntu 16.04 on an Intel Apollo Lake SoC, the kit includes Seeed’s Arduino compatible Grove Pi+ extension board, a display, and Grove sensors.
Arduino Create can also run on any system controlled by Ubuntu or Pulsar that uses 64-bit Intel Atom, Core, or Xeon processors. Arduino’s announcement points to tutorials for setting up Arduino Create on the Intel NUC, Dell Wyse, and Gigabyte GB-BXT mini-PCs.
Arduino’s announcement suggests that ARM could be the next target: “In the coming months, we plan to expand support for Linux–based IoT devices running on other hardware architectures,” says Arduino.
The version of Arduino Create available on the UP Squared kit combines Arduino programming libraries with a simplified installation process, code sharing, and cloud services. Developers can make system calls and run multiple sketches simultaneously. The software ships with examples for integrating Amazon Web Services (AWS) and Microsoft Azure.
The UP Squared kit version provides example code specifically designed for the kit and its Arduino-programmable Grove sensors and I/O peripherals. It includes libraries such as OpenCV, Intel’s Math Kernel Library (MKL), and Intel’s MRAA HAL library for low-speed I/O links. Developers can also export sketches as CMake projects that can bridge to more advanced tools like Intel System Studio 2018.
Next step in the Arduino Linux dance
The newly Linux friendly Arduino Create adds another wrinkle to the continuing evolution of Arduino/Linux integration. Because the Arduino IDE is PC-based, as opposed to an autonomous embedded RTOS such as FreeRTOS or ARM’s Mbed, Arduino is well positioned to act as a bridge between the application processor and microprocessor unit (MCU) realms.
The first Arduino board that also ran Linux – the Arduino Yún – arrived only four years ago. Arduino sketches running on an ATmega32u4 MCU control the Yún, but the software hands off to the OpenWRT Linux based Linino distro running on an Atheros wireless SoC when it needs to communicate with the outside world.
At the same time the Arduino/Linux hybrids were advancing, open hardware Linux projects were adding Arduino support. Out of the 98 community backed Linux hacker boards that appeared in our June 2017 survey, 15 offered standard or optional Arduino shield support. A few of these are official Arduino hybrids, but most are Linux-driven boards such as the pcDuino, Udoo, and Link-It SBCs.
Our survey showed increasing preference for Arduino-ready Linux SBCs just as several of these boards – the Intel Edison and Galileo – were being discontinued. Most of the Linux-enabled Arduinos boards, meanwhile, have emerged from the forked Arduino.org wing of the once feuding Arduino camps. Now that the groups have reunified, and Arduino.org’s Federico Musto has been ousted, the future of Linux-ready Arduino boards (as opposed to Arduino-compatible Linux boards) – is in doubt.
This has less to do with Arduino politics than with the advent of increasingly sophisticated Cortex-M MCUs and wireless chips such as Espressif’s open source ESP8266 and newer ESP32 SoCs, as well as the evolution of the Arduino IDE. The ESP8266, for example, stood in for Linino-on-Atheros on non-Linux, wireless-enabled Arduino offerings such as the Arduino STAR Otto and Arduino Primo.
More recently, Arduino has focused on its smaller, IoT-targeted MKR boards, which do not run Linux. The original MKR1000 offloads WiFi services to an Atmel ATSAMW25H18 WiFi module, and the new MKR WAN 1300 and MKR GSM 1400 use Murata (LoRa) and U-Blox (3G) modules, respectively in addition to their Arduino-compatible MCUs.
Arduino’s new philosophy appears to be that 1) Arduino should focus more on cloud connected IoT software than hardware, and 2) that the best path to Arduino/Linux integration is to run Arduino code under the umbrella of an embedded Linux OS rather than add a separate Linux subsystem to an Arduino board. This would seem to make sense since Linux is no longer needed on Arduino boards to do basic web-enabled networking. The hardware required to run Linux costs more, and Linux adds complexity, especially considering its weak integration with Arduino.
With Arduino Create, however, Linux developers can use Arduino to gain better control over sensors and motor control gizmos, and Arduino developers can piggyback their designs on platforms with more powerful processors and additional resources. The revised Arduino Create aims to bring Intel Linux developers gently into the world of Arduino while also opening up Linux boards to Arduino developers. This is a powerful combination that could prove even more significant if Arduino creates an ARM version of Arduino Create.