In this section of the series on choosing the best technology for your needs, we’ll go over the types of options available for processing.
Unless the function of a circuit is very simple, it will probably include some kind of processor: a microcontroller that is a small embedded computer and forms the brains of the operation.
The major advantage of using micro-controllers is their incredible flexibility: updating the firmware—the code that controls how the processor behaves—can transform a device into a completely different machine without any changes to the hardware.
Micro-controllers come in a bewildering array of sizes and capabilities. But there are three main approaches to using one within your project:
- including a dedicated micro-controller in a custom circuit;
- using the SoC of a required peripheral to run your own firmware; or
- using a pre-built development platform.
Dedicated MCU
The most general and flexible approach is to have a chip dedicated to the task of using the peripheral components and orchestrating everything to handle the business of your device. A dedicated microcontroller (MCU) decouples the firmware from the selected components so, for example, you could keep the microcontroller and switch your communications from wi-fi to bluetooth without any major changes to the rest of your circuit’s layout. In these cases, our preferred platforms are either:
- Atmel AVR Mega family. At the heart of most Arduino devices, these chips are ubiquitous and fast, and can support the Arduino SDK even when included as stand-alone components in a custom circuit. These are easy to program and there are many open source libraries to use and build on for this chip.
- Atmel AVR XMEGAs. These are similar to the Mega processors, described above, and have all their advantages. In addition, the xmegas generally cost less, use less power, run faster and provide more input and output pins—these are often a great choice.
- ARM Cortex. Speeeeeeed. On top of being very fast, these chips allow for access to lots of memory, so they’re great when you’ve got serious crunching to do.
Evidently there are lots of other choices, like the ATTiny chips when what you need is minimal footprint and ultimate power savings at the lowest price and many other options, here. Go over the three steps to a great product, and we’ll be able to figure out what the best fit would be.
Leveraging a SoC
The second approach is useful in cases where you need some type of peripheral, say a bluetooth module or a wi-fi connection, and select a part that is built around a SoC (system on a chip).
In many cases, you can reduce part count and cost for your system by creating firmware that will run directly on that component. Additionally, you can often gain the advantages of lowered cost and complexity while retaining much of the flexibility of using a dedicated micro-controller, by using standard languages (C/C++) and/or SDKs (such as the Arduino SDK). There’s more information on this in the “selecting communications” section, where various modules that include both support for a specific communication protocol and have a SoC that you can use for your own purposes, on board, are discussed.
Development Platform
The final choice involves using a pre-built platform. These are usually most useful for development and proof of concept projects, because they are designed to be flexible and general purpose—thus they are usually larger, more expensive and often more power hungry than you’d want in a production design. Still, to get off the ground quickly, there’s nothing simpler than hooking up to an Arduino or a similar solution. Finally, a notable exception to the previous statement are systems like the Raspberry Pi Zero and Next Thing CHIP, that give you all the processing power of a desktop in form factor and at prices that let you leave them embedded in your product.
Now that we’ve covered the most important communications and processing options, other aspects of interest include sensors, user interface and fabrication methods.