Big Things in Small Packages

The Pimoroni IO Expander, which uses a Nuvoton MS51 as its controller

My exposure to the Nuvoton MS51 microcontroller came about due to its use in a number of Pimoroni Breakout Garden products, initially their IO Expander board, which provides six PWM/digital and eight analog IO pins, programmed using a Python library on a Raspberry Pi using a single I²C connection. Very handy.

Part of this exploration has been mere curiosity about the MS51, which is essentially a 1980s-era technology still being used almost 40 years later. The Nuvoton MS51 is an MCS-51/8051-compatible microcontroller, using the same 8 bit architecture.

The bright red board shown at the top of the post is a bit misleading as it’s actually two boards: on the right is a USB linker board, which is used to connect to and program the MS51 microcontroller, which is on the left. These two boards can be cut apart and reconnected via the 10 pin connectors you can see in the middle. Many of the Nuvoton boards have made this even easier by perforating down the center so they can be easily broken apart. The MS51 processor itself is on the left side, that small surface mount black thing surrounded by pins labeled Nuvoton N79E85JALG, actually 4x6mm. On the IO Expander the MS51 processor is only about 3mm square. More on size below.

(~3x mag.)

Now, I’m quite happy with continuing to program my robot in Python and wouldn’t want to go back to either C/C+ or assembly language, the latter I last touched in about 1981. But in my conversations with the DPRG we’ve talked about distributed processing for robots, that is, using something like a Raspberry Pi as a main brain, distributing the sensor and control tasks to various sub-processors. In a recent conversation this was likened to an octopus, which apparently has about two-thirds of its 500 million neurons in its arms. The sensor boards are generally small — about the size of a postage stamp — but the sensors on these boards often themselves also have a built-in microcontroller, like the ST VL53L1X, a Time-of-Flight sensor that’s about 5×2.5mm.

Last year Pimoroni released a pair products that internally use the MS51, both RGB LED knob controllers, a RGB Encoder and RGB Potentiometer. Recently they even added another MS51 implementation, a tiny Super Dinky Blinky (an LED blinker), even providing a github link with instructions on how to hack/reprogram the device. So it’s clear Pimoroni have some engineers on staff who like the MS51 as a general-purpose microcontroller.

The Pimoroni RGB Encoder, also using an MS51

Back in October 2020 I sent a message into the Pimoroni online forum regarding the use of the Nuvoton MS51 microcontroller on their IO Expander Breakout Garden board, asking if they might help me figure out how to hack it.

Well, nobody answered so I checked out the Nuvoton website and found a plethora of development boards, using ARM Cortex M0, M4, M23 and 8051-compatible processors in “Tiny” and “Maker” (Arduino UNO style) form factors. There’s also a suite of development tools.

Pimoroni Super Dinky Blinky, another MS51 implementation

It looks like both their hardware and software is quite well-documented, with a lot of PDFs on site. Each board is provided with a hardware specifications and information on their Software Development Kit or SDK (e.g. the one for the board shown at the top of this post, the NuTiny-SDK-N79E715). The Taiwanese-English is pretty good, and their product line looks to be very extensive. Not a small company.

Some of the Tiny-style boards are truly tiny, and their Maker-style boards (e.g., NuMaker-PFM-M2351) look like nice Arduino replacements, e.g., 64MHz, operating voltage 1.6-3.6v, memory up to 512kb RAM/ 96kb SRAM. Lots of pins and an UNO-compatible USB link connector. Even an on-board Wifi module. Like Arduinos, the processors themselves are typically surface-mounted but are also available in DIPP packaging should someone want to experiment with one on a breadboard.

A Nuvoton NuMaker MS51 board, pin-compatible with Arduino shields. The USB linker board is on the right.

The ARM Cortex-based processors would be Arduino-like, whereas the 8051 boards (e.g., NuTiny-N76e616) use the MS51/8051, back-to-the-future of the 1980s. Everything looks to be about US$25.00.

Software Development on the MS51

The link to the list of Nuvoton development tools includes IDEs for all of its Cortex M0/M4/M23 and 8051 controller boards. This does actually include a customised version of the Eclipse IDE called NuEclipse, with distributions available for both Windows or Linux. It’s based on a rather old (2015) version of Eclipse “Mars” but seems functional.

I downloaded and installed NuEclipse for Linux, which seems to be Eclipse customised for C/C++ development, comes with a GCC OpenOCD installer, code support for the 60-odd boards Nuvoton sells, user manuals and some sample files.

There are also three KEIL IDEs: one for US$395, one commercial, one free for the Cortex controllers, and two different IAR IDEs for the M0/M4/M23 and 8051 processors, resp. I downloaded the free version but it unfortunately won’t run on the only Windows machine I have available.

As I’m mostly interested in the 8051 I went to the IAR site, searched for the NuTiny-N76E885 board (which is currently on 90% discount for US$2.50!), then downloaded the IAR EW8051 Embedded Workbench IDE, available for either a free 30 day trial or a 4K code size-limited installation. When you first open the IDE you have a choice of registering online for the Evaluation Copy. It won’t operate until registered.

On starting the IAR IDE it looks a bit like an older, customised version of Eclipse, but basically functional. It doesn’t seem like there’s any way to connect it to the Pimoroni IO Expander that uses the Nuvoton MS51, so if I want to further investigate I’ll have to consider getting one of the Nuvoton controller boards.

I’ve also contacted their sales department to see about the price for purchase of the IAR IDE for a quantity of one. The installer included a “dongle driver” so I’m hoping they don’t use dongle-based license management (yuck). At least for the trial license there’s no dongle. If the commercial price of the KEIL IDE ($395) is any indication, the IAR one might be rather expensive. I hope to get a quote from their sales rep, otherwise I’ll be limited to 4K code files.

A Brief Review: Size Matters

I won’t pretend to be thorough here, as I don’t want to be unfair to Nuvoton. I received my order for the Nuvoton Tomato and NuMicro 8051 NuTiny boards. I also received a Nuvoton NuMaker-RTU-NUC980 Chili (on sale for US$14.50) which I may write about in the future.

This might have been a case where I hadn’t read the specifications very clearly, except there wasn’t anything specific on the product pages about size. One looks at photos online that don’t have a coin or a hand next to them for context and makes assumptions. My first impression on opening the packages is that the Nuvoton boards are hardly “tiny”. They seem overly large, with lots of empty space. Apparently the Nuvoton designers didn’t think size matters.

Clockwise from top left: Nuvoton Tomato, Raspberry Pi 3 B+, Itsy Bitsy M4 Express, Nuvoton 8051 NuTiny

The Nuvoton Tomato uses a single-core 32-bit ARM926EJ-S NUC976DK62Y microprocessor with a clock speed up to 300MHz. The ARM926EJ-S is circa-2001 technology, no longer under active development but still used in industry. By comparison, the circa-2016 Raspberry Pi 3 B+ has a much beefier four-core 64 bit ARM BCM2837B0 Cortex-A53 microprocessor running over four times faster at 1.4GHz. The Tomato is targeted at the Internet-of-Things (IoT) market, is a low-power device and has an embedded Linux OS which apparently has an optimised Java JVM. It also has the connectors to allow an Arduino shield to be plugged onto the top of it. Nice. It’s probably not fair to compare the Tomato and the Raspberry Pi. Apart from what’s on the boards, it’s impossible to ignore the fact that the Tomato is big at 67x120mm. But if I were thinking of building a Linux-based, Arduino-compatible robot using Arduino shields (like the Adafruit Motor/Stepper/Servo Shield), I’d certainly give it a whirl. It’s an interesting hybrid.

The bigger surprise was the 8051 “NuTiny”. Bad name really; it may be “Nu” but it’s by no means Tiny. The board is comprised of two parts: the 8051 processor board and a Nu-Link-Me (the Nu pun wears off quickly) board that’s used to connect and program the 8051 processor. But even with the Nu-Link-Me board broken off the 8051 board itself is still 35x52mm, compared with the Itsy Bitsy M4 Express at 18x36mm. If for convenience’ sake we leave the boards together the NuTiny is wider than a Raspberry Pi. Whereas the 8051 CPU chip is only 4x6mm (about half the size of the Itsy Bitsy’s ATSAMD51), the carrier board is over five times the size of the Itsy Bitsy, and doesn’t even come with any mounting holes, despite all that wasted PC board space. A bit of a shame, really. None of this hardly disqualifies it from use on a robot. And I am interested in playing with the 8051 processor, if doing so isn’t too inconvenient.


As I mentioned above, I have no plans to build a robot based upon one of these microcontrollers, though that’s perfectly feasible and indeed a pretty common approach. I’m mostly interested in distributing my robot’s tasks to sub-processors, with the Arduino compatibles (including Tiny, Trinket, Feather, Particle, Itsy Bitsy, etc.), the MS51-based Pimoroni IO Expander, and potentially any of the Nuvoton ARM Cortex or MSS51-based development boards are all suitable contendors for that purpose.

Leave a Reply

Your email address will not be published. Required fields are marked *