“In the current frenzy of connecting everything from blenders to toothbrushes to the cloud, the IoT space is being dominated by low-cost integrated 32-bit microcontroller RF modules that provide small form factor solutions for a small number of sensor inputs.
“
Microchip Technology Inc.
Senior Application Engineering Technology Consultant Bob Martin
In the current frenzy of connecting everything from blenders to toothbrushes to the cloud, the IoT space is being dominated by low-cost integrated 32-bit microcontroller RF modules that provide small form factor solutions for a small number of sensor inputs.
The communication stacks of Wi-Fi®, NB IoT and Bluetooth® are well suited for the 32-bit realm, while increasing computing power to secure RF channels. However, as the number of sensor channels increases or the power consumption required for more remote locations increases the complexity of the system design, adding an additional 8-bit MCU as follows can add value, as shown in Figure 1:
True 5V IO support and sensor aggregation
The industrial environment is still dominated by the 5V power supply ecosystem. Although there are 32-bit MCUs that fully support 5V voltage, most integrated 32-bit MCUs/RFs are devices that only support the 3.3V power supply domain. In the 5V power domain, allowing a more efficient 8-bit MCU via GPIO to connect directly to 5V power sensors, switch contacts, and actuators without adding multiple level shifters or adjusting analog Voltage inputs to meet 3.3V voltage requirements.
Now, just level shift/adjust the communication channel between the 8-bit MCU and the 32-bit MCU/RF module. In some cases where the 32-bit MCU module has a 5V tolerant input, level shifting may not be required at all, perhaps just some series resistive isolation. For situations where galvanic isolation is also required, additional cost savings can be achieved by reducing the number of dedicated ICs required to protect the RF portion of the system.
Remote installations often require greater fault tolerance, which may result in the use of multiple sensors or actuator controls to mitigate the effects of field failures. Redundant sensor interface connections mean more input/output pin assignments ON pin-limited 32-bit MCU/RF modules. 8-bit MCUs tend to offer a huge interface pin density, allowing some intelligent fault tolerance to be added to the sensor array on the front end. It does not require machine learning algorithms to determine if one of the three temperature sensors is malfunctioning. These types of decisions can be made locally with faster incident response.
Industrial Sensor Integration © xiaoliangge – stock.adobe.com
Figure 1 – 8-bit/32-bit system partition
system partition
Using an external 8-bit MCU to interface with most sensors makes it easy to quickly plug a known working analog/digital front end into different RF module back ends. An integrated 32-bit MCU/RF module usually comes with a large number of example applications that demonstrate that connecting to the cloud is a breeze, regardless of the vendor. How to interface with sensors or actuators other than standard I2C or SPI buses may not be clearly stated in the application examples. Validated known sensor/control front ends with consistent and well-defined interfaces also allow for greater flexibility in selecting the appropriate RF module by minimizing the migration process. Once the new physical layer on the new RF module supports the protocol layer between the two MCUs, the integration of the new system is almost complete. The development effort can now focus on the proper implementation of the new RF channel.
Loosely coupled systems with fault-tolerant hot-swappable interfaces are a beneficial feature in industrial or remote environment settings. Sometimes whole system swaps are unavoidable, but the ideal is to minimize overall changes to known reliable systems. This loose coupling also enables trusted, known RF platforms to support extended system requirements without having to start from scratch. Keep what you trust and improve what you lack.
System Partitions and Architecture © myboys.me – stock.adobe.com
Smart Power Management
Unfortunately, the move to smaller IC gate technology requires a trade-off between speed and quiescent current leakage. Gate oxide thicknesses in new process nodes are about to reach optimal thicknesses in atoms rather than nanometers. The 8-bit MCU space is dominated by larger process technologies that enable better static leak rates. Since optimal low-power management techniques are by definition simultaneous power cuts, adding intelligent low-power management devices can improve low-power operation. Some 8-bit MCU devices run on a standard 32.768 kHz crystal that leaks current on the 32-bit RF module. This approach now adds a precise time-based power management system, as well as the ability to charge and monitor battery health. 32-bit RF modules (especially Wi-Fi based units) can have active currents in the hundreds of milliamps. If the battery pack is about to run out, it may not be able to maintain the startup and delivery current required to connect to the network.
8-bit MCU-based power management systems can now wake up the main RF module using a special wake-up command that reduces the current demand required to keep the RF module online with optimal phase sequence. This particular wake-up use case can now use reduced TX power to eventually establish a connection to the network. The 8-bit MCU power management system can periodically monitor peak startup current and voltage sag and submit these data on every wake-up cycle. Appropriate cloud machine learning engines can leverage this data to better analyze battery systems and predict failures.
Low Power Remote Applications © aquatarkus – stock.adobe.com
Programming Model/MCU Complexity
The programming difficulty of 32-bit MCU/RF modules has decreased significantly over the past few years. Some of these modules offer Arduino-based support, which definitely helps speed up development, but when it comes to more customer sensors, power management, or other peripheral interfaces, programming becomes more difficult. The Arduino support code is huge, but in many cases incomplete, and there are still some trust issues in the professional world. In addition, IC vendors themselves provide support, but at the end of the day, the additional complexity of integrating 32-bit RF modules at the bare metal layer cannot be avoided. All 32-bit based control registers seem to be too big for some control bits or status bits, although this does happen when moving to 32-bit, at the moment not all of them are able to use peripherals like 0x23AA123C Visually pick out the wrong bit in the control value.
The 8-bit MCU programming model presents common interfaces in 8-bit blocks, sometimes extended to 16 bits for timer registers. In addition to being able to debug bit fields more easily, peripheral sets on 8-bit MCUs tend to be easier to understand because they don’t need to involve or provide more complex power reduction or bus interface synchronization features. The clock tree in 8-bit MCUs is also easier to understand, and even if a PLL is provided in the clock tree, the operation is simpler. However, that’s what using an 8-bit MCU companion device is all about, providing a low-power, low-cost, smart, but not IoT-ready device that handles all the background, power management, and tedious tasks.
Microchip provides several examples of 8-bit MCU devices, including the PIC18-Q41 family and the AVR DB family. Both families offer extensive analog functionality, including on-chip op amps and multilevel voltage GPIOs, reducing the need for additional external analog components and level shifters.
While the number of multicore 32-bit MCU/RF modules available is increasing, adding an 8-bit MCU is still a viable option when designing robust low-power edge nodes in an IoT environment. They provide power and sensor management in a small package, so they still play an important role in the 32-bit IoT space.