The other end of the telescope: Intel’s Galileo developer board
Embedded Linux, meet Arduino - Chipzilla style
Posted in Personal Tech, 29th January 2014 14:29 GMT
Review Any notions that the Arduino platform is completely wedded to the Atmel ATmega family of microcontrollers have been shattered. The ARM-equipped Arduino Tre, which is based on Texas Instruments’ Sitara chip, is coming in the spring. And here, now is Intel’s Galileo, an Arduino board based on one of Chipzilla’s x86 processors, the 400MHz Quark X1000 system-on-a-chip.
Yet it’s no less an Arduino board than the de facto standard Arduino board, the ATmega328-based Uno R3. Perhaps more so, in fact, since it has on-board features that the Uno lacks and requires add-ons to accommodate: Ethernet connectivity, a mini PCI Express connector and a Micro SD slot, for instance.
Folk who’ve already played with an Arduino will be right at home with the Galileo. The 105 x 75mm board is programmed through the regular Arduino IDE, which Intel has tweaked to incorporate a suitable x86 compiler and USB driver.
Writing and uploading a Sketch - Arduino-speak for a resident program - is exactly the same whether you’re working with a Galileo or with the Uno or any other Arduino-compatible board, such as the Adafruit Trinket, the microcontroller board I use. Fire up the IDE on a Mac, a Linux box or a Windows PC, and you’re ready to write some simple “Hello World!” code and move on to more advanced projects.
Galileo is also home to the standard Arduino GPIO connections: 14 digital, six analogue and the eight power-related pins, all presented in four sets sets of female sockets positioned on the board so they’re ready to accept add-on Shields - what the Arduino world calls add-on cards - that have been designed for use with the Uno R3. The GPIO sockets are equally ready to grasp wires to and from your breadboard. The same pins here do PWM as do those on the Uno.
Intel’s current Shield compatibility list features 17 boards that are Galileo friendly, among them various GSM/GRPS/3G Shields for cellular connectivity, plus boards for Bluetooth, RFID, NFC, solar charging, and running servos and motors, so if you need such functionality for your project, you should be able to get a Shield that will work with Galileo.
On the underside, a full-size Mini PCIe slot
Why might a Shield not work with Galileo? Bugs or drivers, says Intel: hardware errata might cause problems, but some Shield drivers hard-code ATmega register IDs, which clearly aren’t going to easily translate to x86 equivalents. Intel is offering to help Shield driver writers fix this, so there’s scope for more Shields to become available over time. Galileo supports both 3.5V and 5V Shields, and there’s a jumper to connect or disconnect the GPIO VIN pin to the board’s 5V supply. Remove this jumper if the Shield needs more than 5V.
Galileo takes power from a bundled 5V transformer connected to a barrel socket on the board. Wait a few seconds for the board to prep itself - a light on board signals its readiness - and you can connect it to your computer using the one of its two micro USB ports.
The 5V, 2A feed is the only official way to power the board. “You must use the power supply or you will damage the board,” the firm warns, adding: “Always connect the 5V power before any other connection.” (Intel’s emphasis). There are certainly no power ports on the board for battery connections other than a pair of pins placed to allow you to connect a coin cell to keep the on-board hardware clock powered. But it shouldn’t be too hard to rig up four AAs in a suitable cradle to the barrel connector.
No need for a Shield: integrated Ethernet and, to the left, a UART port disguised as audio out
The Intel board is about twice the size of a Uno and slightly larger than a Raspberry Pi. You might see Galileo as Intel’s attempt to challenge Britain’s own board micro, which, like Galileo, runs Linux. Maybe it will oust the Pi from some embedded-type applications, but for most tasks you might set a Pi to, the Intel board isn’t suitable because it has no video or audio output off the board. You could avail yourself of a Mini PCIe card with an LVDS connector and hook up an LCD panel to it, but that’s going to increase the cost some.
Even then there’s no GPU worthy of the name in the SoC itself, and the Quark chip likewise doesn’t support Intel’s media-centric extensions to the x86 instruction set, specifically MMX and SSE. So a GUI-based OS is out of the question. If you want to make use of the board’s embedded Linux, you’ll be interacting with it through SSH or Telnet over a network connection and a terminal session.
Out of the box, Galileo has 100Mb/s Ethernet, and if you want Wi-Fi or 3G, you can add a card to the Mini PCIe socket on the underside of the board. The wireless card won’t operate with the on-board Linux firmware, but the Micro SD slot provides a home for a more capable embedded Linux distro with suitable Wi-Fi drivers installed and a place to install drivers for other types of Mini PCIe too. Intel provides such a ‘fatter’ Linux as a download.
The Micro SD slot can take a card with a ‘fatter’ version of Linux than the one embedded in the board
The Ethernet port replicates an Ethernet Shield, so you can run code that makes use of Arduino’s Ethernet library without modification. I used the WebClient sample code to grab a page off Google, and the only reason the Twitter client didn’t work is because of major changes made to the Twitter API since the Sketch was written.
The X400 system-on-a-chip has 512KB of on-board SRAM, and there’s a further 256MB of DRAM on the board, along with 8MB of Flash for the firmware and any Sketches you send over from the IDE. By comparison, the ATMega328 on the Uno R3 has 2KB of SRAM, 32KB of Flash and 1KB of EEPROM, so the Quark provides scope for far bigger Sketches than the Uno can, though of course the Linux firmware will grab some memory - not to mention CPU cycles - too.
The Arduino GPIO array is reproduced faithfully - with the exception of AREF support
That said, there is one advantage to running an OS rather than a simple resident program loader, as other Arduino’s use: access to applications and utilities. The Galileo IDE incorporates the
system() function, absent from OS-less Arduinos but which lets you to embed Linux command line strings into Arduino’s fundamental
loop() functions and other routines.
system("ls -la > /dev/ttyGS0");, system("python /home/pyJamas/pyJames.py > /home/pyJamas/filelist.txt"); and
system("ifconfig eth0 > /dev/ttyGS0"); send the command strings to the OS’ shell and route the responses back through to the IDE’s Serial Monitor - handy for quickly looking up a Galileo system values, such as its IP address, or to trigger applications and scripts. Again, to use this feature to the full, you’ll need the upgraded version of Linux that Intel supplies to run off a Micro SD card rather than the embedded distro.
Intel has extended the Uno’s standard feature set with a number of other extras: in addition to the already mentioned Ethernet, Mini PCIe and Micro SD hook-ups, there’s a second UART connector in the form of a 3.5mm mono audio jack - I’d have preferred pins; a JTAG (Joint Test Action Group) connector, which is a ten-pin interface that taps directly into the processor and is used in the embedded world for debugging machine code programs; and a second micro USB port for connecting USB peripherals - you’ll need an adaptor with a full-size female USB connector to make the most use of this.
The analogue inputs default to 10-bit resolution as per the Uno, but can be set to 12-bit resolution if you need it.
The Mini PCIe slot and card rest make a good stand for the board
There are downsides. Because the Quark chip doesn’t provide the same GPIO ports as the Uno R3’s ATMega328 microcontroller, it has to deliver them indirectly by way of an on-board I²C Port Expander, made by Cypress and which operates at the I²C standard clock rate of 100kHz but adds inevitable lag, so GPIO access takes 2ms and the read/write frequency is limited to 230 each second. That may not be a sufficient sampling rate for some sensor-based applications.
Separately, Intel warns against connecting the 7-12V power supplies that are common in the Arduino world.
And Galileo is a far more complex board than, say, the Uno, so it’s inevitably more expensive. Adafruit is selling it for $99 (£60), though you can find it on Amazon.com for $60 (£36). Here in the UK, Cool Components wants £66 for it - or will do when it gets some in stock; UK supply details are sketchy at present. The point is though, even where Galileo available, a Raspberry Pi is around half the price, and the Uno R3 cheaper still, though adding features like Ethernet will bring the overall cost closer to that of the Galileo.
If it Quarks like a duck...
You can do a heck of a lot with an £8 Adafruit Trinket, but then that’s the whole point of Arduino: open sourcing the hardware allows the one product to form the basis for an array of boards from which you select the one that’s appropriate to your needs. Galileo’s design and schematics are likewise available, so it’s entirely possible Intel or another firm will devise smaller, cheaper but less feature-packed Galileos.
Aside from cost, the other issue is power consumption. The air above a Sketch-running Quark chip gets noticeably warm, as it does above the Raspberry Pi’s SoC. It doesn’t need a heatsink, though Intel warns that it might if the ambient temperature gets above 50°C. Power draw is less of a concern if you’re running the board from the mains, and battery mileage will depend on what code you’re running and what add-ons you need.
One forum poster with a Galileo connected to a 900MHz radio module, for instance, noted that the “battery life of four AA batteries... was about three hours corresponding to about 350mA current draw on average, very high for an Arduino board”.
The Reg Verdict
Intel’s Galileo won’t be for every maker, but it’s nonetheless a capable board packed with functionality and Arduino compatibility. It’s no Raspberry Pi rival, rather a useful addition to the Arduino family for folk who need integrated Ethernet and the capabilities of a full embedded OS. ®