A Beginner’s Guide to Selecting a Microcontroller
13
2017
There are thousands of microcontrollers to choose from, so it can often feel like an uphill challenge when trying to select the right MCU for your application. You should never rush into purchasing a microcontroller, because they are a major part of a device’s performance, so make an educated decision; the best way to start is for an engineer to ask themselves key questions, so that they purchase the best based device based on performance and cost.
![]() |
Image source |
What hardware interfaces will I require?
Before you buy a microcontroller, it is essential you identify the external interface a microcontroller will be required to support. For example, when choosing communication interfaces, you must consider peripherals such as USB, I2C, UART and SPI. You may also need to amplify the program space if you need to support a USB or Ethernet. You must also write a list of any other interfaces you will support, such as digital input and outputs, PWMs and analog to digital inputs.
What are my processing needs?
A software’s architecture should also dictate the type of microcontroller you select. For example, you must identify if you will have heavy or light processing requirements, because this will determine whether you select a MCU with a high or low megahertz. Ask yourself how long each task will take to run each time, so you can assess the computing power.
What architecture will I need?
As soon as you have identified the external interfaces and the software architecture, you must identify the microcontroller architecture. One of the biggest mistakes you can make is selecting architecture that allows your application to run successfully at present, but fails to offer enough space for future features. So, while 8-bit architecture might seem like an ideal choice right now, it could be a wise move to give yourself a little extra space with 16-bit or 32-bit ARM core.
Many suppliers have a search facility that enables you to refine your search, such as Microchip’s PIC map. You can also telephone a supplier to discuss your requirements so they can point you in the right direction, because they will have extensive MCU experience. In addition, you could ask for more information on additional functions the supplier can integrate into the MCU in the future, which will help you identify whether they can fulfil your long-term requests.
How much memory will I need?
Program space should be at the top of your list when selecting a microcontroller, because you will not want to come close to finishing a design to discover you have ran out of flash or RAM. You should therefore aim to select too much over too little. Speak to an engineer to discuss how much RAM or flash you will require for the device. By increasing the memory size, you can request additional features, such as LCD controllers, timers and I/O engines, plus more.
It is worth noting that flash memory can sometimes be slower in comparison to core memory. It is therefore vital an engineer looks for MCUs that offer matching flash performance and core performance.
How many pins will I require for the device?
The amount of pins will be determined by the various devices you will need to connect to a microcontroller. The two basic pin types are:
- Digital input/output (I/O)
- Analog input/output (I/O)
Other pin types you may require include power and ground (GND) and transmit/receive (Tx/Rx).
Beginners should therefore consider opting for a microcontroller with one pin for each of the following functions:
- One digital pin for each digital sensor One analog pin for each analog sensor One digital pin for transmitting data One digital pin for receiving data One digital for each motor
However, it is important to note that some microcontrollers may not include an analog I/O pin, which means you may be required to purchase an external analog to digital converter.
Do I need to buy a starter board?
Most suppliers will provide both a microprocessor and its corresponding starter board, which will often include an easy power connection, power regulation and various connections.
How long do I have to wait for the parts?
Once you have filtered your way through the MCUs to find the perfect part, you need to identify how long you must wait for the parts. For example, you might require the parts in a matter of weeks, but the product will not be available for several months. You should therefore identify how long it will take to receive the items so you can perform to a deadline.
How much will MCUs cost?
In recent years, the pricing structure for microcontrollers has shrunken, so only a few cents may separate an 8 bit, 16 bit and 32 bit MCU.