A bit of this, a bit of that
This board, however, with its six cores has quite a lot of resources to manage, and sits somewhere between the two. Although it can be programmed via the Arduino IDE, it runs a stripped-down UNIX-compatible operating system called NuttX. If you program the Spresense using the Arduino IDE, you may never know that there’s this OS behind the scenes managing things, as it works just as any other Arduino-compatible board does. However, you can delve right down into its internals using the Spresense SDK. You can even connect to the UNIX shell-like command-line interface over a serial connection, and interact with the board this way.
Development via the Spresense SDK officially requires Linux; however, we were able to get it working on Windows 10 using the Windows Subsystem for Linux. It’s not a particularly straightforward process, though, and probably not worth it for casual users. It does, however, let you unlock more performance due to the multi-core architecture.
Although the Spresense has six cores, only one will run your application. The remaining five can be used to run specific, additional tasks. Sony provides some code for running audio code on these cores from within your Arduino sketches. You can find more details of these at: hsmag.cc/luPaPI.
Sony supplies a set of Arduino libraries to help you get the best out of this board in a few areas, as well as audio. The DNNRT library allows you to use deep neural networks (DNN) created using the Neural Network Console – a training tool that lets you configure and train your neural networks on your main computer before transferring this trained brain to your Spresense. While this isn’t completely straightforward, it doesn’t require a lot of programming skill, just the knowledge of how to configure a network.
The module has built-in satellite positioning that uses GPS, GLONASS, and QZSS satellite positioning systems. We found that the antenna wasn’t particularly sensitive and failed to get a fix inside at a location our phone could get a fix at. That said, you’re unlikely to be relying on satellite positioning inside.
The base board includes a camera connector, and Sony has released an official camera module. By microcontroller standards, this camera – at 5 megapixels – is really high resolution. While you might be used to cameras with far more pixels on your phone or Raspberry Pi, these cameras are rarely compatible with microcontrollers and the high data rate needed to operate such a camera. When combined with the AI capabilities on this board, this has the potential to add some really powerful vision capabilities to your makes.
While the Spresense is a very capable board, it’s not a beginner board – its unusual hardware means that it works a bit differently to most microcontrollers. The libraries that unlock the power of this board are well-documented and do make it reasonably straightforward to use this particular hardware, but it is a bit different from other Arduino-compatible boards.
There are a few oddly disparate areas where the Spresense can really stand out. The ability to play or record sound in the background – without taking up processing time on the main CPU – could be a huge boon. The hi-res camera can be really useful, as can the AI capabilities. Looking at these, they read like a set of scenarios more suited to small Linux-capable computers, such as the Raspberry Pi, than microcontrollers. Perhaps this isn’t surprising, since the Spresense runs a UNIX-like OS – though one that much more stripped down than Linux.
The Spresense is more powerful than most microcontrollers (particularly when the extra cores are taken into consideration), yet it boots in under a second and runs real-time code, so can be used for precise hardware control. While it’s not for every project, the particular capabilities of the Spresense make it an excellent addition to the arsenal of hardware available to makers.
Sony From £49.19 https://developer.sony.com/develop/spresense/
An unusual microcontroller with great potential for AI and vision projects.