FPGAs, SoCs, Microcontrollers— A Quick Rundown of IoT Devices

Written by sharonlin | Published 2018/12/26
Tech Story Tags: tech | internet-of-things | embedded-systems | microcontrollers | fpga

TLDRvia the TL;DR App

If you’re new to the world of IoT, chances are you’ve heard a number of terms and acronyms thrown around and wondered about their differences or whether you should purchase a Raspberry Pi or an ODROID.

That main reason I became curious about how interchangeably these boards were being used was because some of the main intro to embedded systems labs at MIT (6.08, 6.111, 6.115) teach programming microcontrollers, PSoCs, and FPGAs.

I first started hearing about the different types of boards around 2012, around the time Arduino and Raspberry Pi were becoming popular. I’ve mostly used microcontroller development boards due to their ease of integration into smaller projects (usually small IoT devices won’t require high computing power or peripherals like RAM).

Another thing that I didn’t realize at first was that the terms referred to the integrated circuits (ICs), and that a development board had to be built around the IC to make them useable or to interface external components.

Microcontroller (MCU)

Atmel ATMEGA32U4-AU AVR Microcontroller from Tindie

A small computer on a single integrated circuit. They are generally less complicated that SoCs (a SoC can have a microcontroller as one of its components). They contain at least one CPU (processor core), memory (RAM, flash, ROM), and programmable I/O peripherals. They are designed for embedded applications, as opposed to microprocessors used in personal computers or other chips used for more general purpose applications.

Many IoT devices that are automatically controlled (using some form of a feedback controls system) use microcontrollers. Their main advantage is that they reduce the size and cost of a similar system using separate microprocessors/memory/input/output devices.

They can be used for data collection, sensing, actuating physical devices, and low-energy applications, among other uses. Some common microcontrollers at the Atmel AT89, MSP430 from Texas Instrument, and ESP32/ESP8266.

You can usually find development boards that include a microcontroller (such as the Arduino Uno, Intel Galileo, TI Launchpad, or BeagleBone Black), thus removing the necessity of designing a PCB for the microcontroller.

Microprocessor

Intel Core i7 microprocessor

A microprocessor is a device that incorporates the functions of a CPU on a single IC (or a few). It is a clock-driven, register-based digital integrated circuit that accepts binary data as input, processes it according to an instruction set stored in its memory, and provides output.

Different instrument sets determine the different architectures of microprocessors (AMD x86 and x86–64, PowerPC, ARM). More common architectures today are generally 32-bit or 64-bit, with some reduced instruction set computing (RISC) microprocessors that — as expected — have reduced instruction sets.

There are other devices that are multi-core (Intel Xeon processors, AMD Phenom II). Historically, AMD and Intel are known as the companies with the fastest CPUs with their dual-core and quad-core CPUs.

Nowadays, CPUs are almost all implemented on microprocessors, causing the two terms to be practically interchangeable.

When comparing the microprocessors in laptops, you generally consider the number of cores, the clock speed, the cache size (like RAM, but the memory is stored on the CPU itself so it’s faster), and other aspects like hyperthreading (running multiple threads simultaneously from a single CPU, which is something you can do nowadays) or dynamically increasing clock speed when the need arises.

System on a Chip (SoC)

AMD Am286ZX/LX, SoC based on Intel 80286 (from Wikipedia)

An integrated circuit with all the components of a computer, including a CPU, memory, I/O ports, and secondary storage. They consume less power and take up less space than a multi-chip design, and are common in embedded systems. Compared to the motherboard-based architecture, the CPU, graphics, hard-disk, USB-connectivity, ROM/RAM, and memory interfaces are all integrated (a motherboard would connect all of the components separately or as expansion cards).

SoCs are usually built around a microcontroller, built around a microprocessor (found in mobile phones), designed for a specific application, or designed as a programmable SoC with some reprogrammable aspects, similar to FPGAs. Compared to microcontrollers, SoCs usually have far more pins and more systems integration of different peripherals.

Note that system-on-a-chip can refer to many things on the market, and it generally refers to a single chip that does everything that used to take up multiple chips (some still require peripheral such as RAM or flash, so the name may be misleading).

Some common ones are the Cypress Semiconductor Programmable System on a Chip (PSoC) and Altera System on a Programmable Chip (SOPC). On that topic, PSoC solely refers to the family of microcontroller-integrated SoCs produced by Cypress Semiconductor, although there are other programmable SoCs that exist.

This StackExchange thread has some useful knowledge on current conventions within SoCs.

Field-programmable gate array (FPGA)

Xilinx Spartan FPGA from Wikipedia

An FPGA is an integrated circuit that can be configured by a consumer after manufacture (“field-programmable”). Its configuration is specified using a hardware description language (HDL). They contain programmable logic blocks (like AND and XOR) and a hierarchy of reconfigurable interconnects that “wire together” the blocks.

These blocks can also contain memory elements (flip-flops, etc.) The biggest companies for delivering FPGAs include Altera and Xilinx.

Compared to microcontrollers, they are faster, parallelizable, and have more design flexibility (trading companies often hire FPGA programmers to program their trading strategies in order to beat out competing firms). They are generally more expensive and more difficult to use, but contain the same ICs, logic components, and programmability.

Common FPGAs are the Xilinx Spartan and Virtex Series and the Altera Stratix and Cyclone Series.

(More info at this StackExchange thread)

Complex Programmable Logic Device (CPLD)

An Altera MAX 7000-series CPLD with 2500 gates from Wikipedia

A programmable logic device that’s slightly less complex than an FPGA. It primarily consists of a macrocell with logic expressions and operations. It doesn’t require an external configuration ROM (needed by FPGAs) and has less internal state storage and layered logic than FPGAs. CPLDs have thousands to tens of thousands of logic gates, while FPGAs can have up to several millions.

They are primarily manufactured by Altera, Atmel, Cypress Semiconductor, Lattice Semiconductor, or Xilinx, and are programmed in VHDL, Verilog HDL, or Standard Test and Programming Language (JAM/STAPL).

Programmable Logic Device (PLD)

This is a more generic terms that refers to an electronic component used to build reconfigurable digital circuits — they differ from logic gates, which have a fixed function, as PLDs don’t have functions after being manufactured.

Different types of PLDs (in approximate order of complexity from least to most) include the programmable logic array (PLA), programmable array logic (PAL), generic array logic (GAL), complex programmable logic device (CPLD), field-programmable gate array (FPGA), and other variants. Some of the terms used to describe PLDs are trademarked by specific companies (PAL was owned by Monolithic Memories, Inc. (MMI) and currently held by Lattice Semiconductor, for example). Low-complexity devices are programmed in PALASM, ABEL, or CUPL, while higher-complexity devices are programmed in the higher level Verilog and VHDL languages.

Digital Signal Processor (DSP)

Texas Instruments DSP processor from Analog Devices

A specialized microprocessor optimized for digital signal processing. While other microprocessors may have general functionality for executing digital signal processing algorithms, they aren’t usually optimized for continuous processing in real-time.

DSPs usually have better power efficiency and are used in mobile phones or devices with power consumption constraints. The algorithms used require a large number of mathematical operations to be quickly performed (FIR filters, Fast Fourier transforms (FFTs), matrix operations). Instruction set architectures commonly used to increase parallelism in DSPs include SIMD, VLIW, and superscalar architecture.

Integrated Circuit (IC)

Erasable Programmable Read-Only Memory (EPROM) ICs from Wikipedia

A set of electronic circuits integrated into one small flat chip of semiconductor material (usually silicon). This results in a chip that is orders of magnitude smaller than a circuit that would have to be built by hand using separate electronic components. These chips are usually mass-produced, and are used in tons of electronics. ICs can be classified into analog, digital, and mixed signal ICs.

Digital integrated circuits can contain logic gates, flip-flops, multiplexors, and other circuits, and are usually produced as MCUs, DSPs, or microprocessors. The most advanced ICs are generally microprocessors (“cores”). They can also be classified as logic ICs, memory chips, interface ICs, power management ICs, and programmable devices.

Analog ICs can include sensors, power management devices, RF chips, and operational amplifiers (op-amps), which process continuous signals and perform functions such as amplification, active filtering, mixing, and demodulation. They ease the burden on circuit designers by providing an efficiently designed analog circuit that can be difficult to design from scratch.

Mixed-signal ICs can create functions such as analog-to-digital converters (ADC) or digital-to-analog converters (DAC), digital potentiometers, as well as clock/timing ICs.

Application Specific Integrated Circuit (ASIC)

Bitfury 55nm ASIC H-Board from Cryto Store

An integrated circuit customized for a particular use (as the name implies). For example, some ASICs are designed for digital voice recording or parallel computing. In Bitcoin (or altcoin) mining, ASICs can be designed to solve specific hashing algorithms.

Under some definitions, you can consider a GPU an ASIC, such as NVIDIA GPUs, which are meant for graphics computing. They perform better than CPUs in this specific task due to a compact design (less space and material used), power dissipation (battery life), and speed of computation. Usually the discourse between GPUs vs. ASICs is within the altcoin mining community, which usually discusses ASICs in the context of chips designed to solve a specific complex algorithm.

Application-specific standard products (ASSPs) are between ASICs and industry-standard circuits. While ASICs combine a collection of functions designed for a single customer, ASSPs are used as off-the-shelf components. Their uses include USB interface chips, controller chips for a PC, and a chip for a modem.

Electronic design automation (EDA)

A simple PCB designed in EAGLE

A category of software tools for designing electronic systems for integrated circuits (ICs) or printed circuit boards (PCBs). The tools create a design flow for chip designers to create entire semiconductor chips with billions of components.

Their simulation software includes transistor, logic, behavior, hardware emulation, and field solvers. For design, they usually inplement schematic capture, layout, and logic synthesis. Analysis includes formal verification to prevent deadlock, equivalence checking, static time analysis for worst-case scenarios, physival verification to prevent physical defects and to check for physical manufacturability, and clock domain crossing verification (like linting) to check for issues in clock domains.

Major companies producing EDAs are Altium (Altium Designer), Cadence Design Systems (Verilog, OrCAD), Autodesk (EAGLE), National Instruments (Multisim), and WestDev (Pulsonix). There is also KiCAD, an open-source EDA software, as well as many web-based EDA tools, some of which are web-based versions of the aforementioned EDAs.

In terms of some of the differentiations between commonly purchased development boards, knowing the difference in the hardware makes purchasing a board a lot easier. If you’re just starting out, you usually don’t care too much about specifics, and you’ll want a board that’s easy to interface with pin-outs that make sense for whatever project you’re building (you’ll also want systems compatibility with whatever peripherals may be relevant to you).

ODROID

ODROID C-2 from Wikipedia

A series of single-board computers capable of running Android and Linux distributions (the name comes from “open” + “Android”). The hardware features a SoC with a ARM CPU and an on-chip GPU. SD cards are used to store the operating system, and the outputs include USB 2.0, USB 3.0, HDMI, and a 3.5 mm jack. There are also lower-level output pins with general-purpose input/output (GPIO) pins supporting common protocols such as I2C. There are also some models with an 8P8C Ethernet port and an eMMC port.

Common models are the ODROID-C1, ODROID-C2, and the ODROID-XU4.

Raspberry Pi

Raspberry Pi Zero from Wikipedia

A series of single-board computers developed for the purpose of teaching basic computer science in schools. The models all featured a Broadcom SoC, with an ARM CPU and an on-chip GPU. SD cards are used to store the operating system, and the outputs include USB ports, HDMI ports, a 3.4 mm jack for audio, and lower-level GPIO pins supporting I2C and other protocols. There are also some models with an 8P8C Ethernet port and an eMMC port.

Common models are the Model A, Model B, and Zero.

Arduino

Arduino Uno from Wikipedia

An open-source hardware and software company and user community that produces single-board microcontrollers and microcontroller kits. Their hardware contains an Atmel 8-bit AVR microcontroller with flash memor and a single or double row of pins that can connect to add-on modules (“shields”) and can be addressable via a I2C serial bus.

Most models are pre-programmed with a boot loader for uploading programs to the on-chip flash memory. Some of the I/O pins can produce pulse-width modulated signals and receive analog inputs.

Common boards are the Arduino Pro, Arduino Mega, and Arduino Yun.

As it turns out, there isn’t a ton of standardization in terms of how IoT systems are built and maintained — at least not universally. There are certainly standards that have been set over the past few decades with regards to the protocols and operating systems used that are optimized for smaller devices, but there’s enough variability that how you choose to build your system is dependent on what you value — CPU efficiency, memory, cost, etc.

As for the devices themselves, there’s a reason why Arduino is so popular — it takes away all of the mess of having to choose a processor and figuring out layouts for a board and figuring out the programming environment and presents everything neatly packaged such that a 9-year-old child can program an Arduino to turn on an LED.

Sticking with the familiar environment that Arduino presents removes a lot of headache, but it doesn’t allow you to explore the greater possibilities of integrating devices that aren’t in the Arduino ecosystem — which is very much a possibility.

Sites like Digi-Key (and to varying degrees SparkFun, Adafruit, and Tindie) have a huge array of embedded devices and integrated circuits (ICs) far beyond the scope of Arduino. I’d recommend checking out similar sites if you’re working on a larger scope project.

If you liked this post and want to hear more about my thoughts on hardware, computer science, or even life as a university student, feel free to follow me or find me elsewhere online!

Twitter @sharontlin

Facebook @sharonlinnyc

GitHub @sharon-lin


Published by HackerNoon on 2018/12/26