Everything you need to know about Non-volatile Microcontroller Embedded Memory!

It is common sense that when we have to be meticulous and look out for a variety of factors when choosing a microcontroller for our project. If we only pay attention to one part of the microcontroller, the other might not be compatible, or even worse, clash with the entire project! The devil’s in the details.

There is a list of factors to consider, but we’ll be focusing on only one today, memory! To be more exact, embedded non-volatile microcontroller memory. The comprehension is appropriate for the most part, but only when dealing with basic programs! When attempting to develop a more sophisticated application like TinyML, on the other hand, a better understanding of memory will go a long way toward maximizing the performance of our beloved microcontrollers.

In this article, we will be introducing and explaining the common types of embedded non-volatile memory!

  • What is embedded non-volatile memory?
  • Why you should know about the different types of memory?
  • What are the different types of embedded memory?
  • What to look out for when selecting memory?
  • Reliable and Versatile Microcontrollers Recommendations

What is embedded non-volatile memory?

Before we get into the details and all of the fun stuff, we got to know what exactly are we learning today. Embedded non-volatile memory is a small-sized chip found in microcontrollers, and other hardware, for the purpose of storing data. The data stored are for data encryption, programming, trimming, identification, coding, and redundancy purposes.

Source: Amazon

EMMC chips, a type of non-volatile memory chip

The word ‘embedded’ in embedded memory means that it is a memory on a chip soldered directly on the microcontroller. It is integrated, and generally have higher performance with a higher speed as compared to non-embedded memory. It is not as fast as a Solid-state drive, but still faster than a Hard disk drive!

The word ‘non-volatile’ means that the memory chip will still retain its data without electrical power. For instance, USB flash drives (thumb drives) are considered non-volatile storage devices as they retain their memory after being disconnected (losing electrical power). RAM (random access memory) on your PCs are volatile memory, meaning they lose their data without electrical power.

How non-volatile memory retain its data?

Electricity is one of the components required for storage devices to keep their memory. Non-volatile memory contains special transistors that have a small piece of conductive material in them surrounded by a layer of insulator called a “floating gate”. When the microcontroller is powered, a little bit of electricity tunnel through the insulation to the floating gate, where it gets trap by the surrounding insulation. The electricity is able to enter due to the high voltage but is unable to leave due to the low voltage. That is how non-volatile memory retains its data!

Why you should know about the different types of memory?

The main reason you should know about the different types of memory available is to ensure that the microcontroller you’ve selected has the type of memory that can perform the most efficiently for your project requirements!

When you purchase a microcontroller, you will almost definitely take the price into consideration. The price can be affected by the type of memory as well! Cheaper memory tends to have specifications that make them not as versatile for most projects. Unless your requirements can be fulfilled with a cheaper type of memory, you should always know the best microcontroller memory to purchase that works best for your project.

A memory chip main’s purpose is for storing data, but specifications such as its read and writing speed is important when you’re working on a complicated project utilising more complicated concepts such as machine learning on TinyML.

What are the different types of embedded non-volatile memory?

As of now, you’ve learned that embedded non-volatile memory is a chip soldered on a microcontroller that stores data and retains it even after losing power. 

Generally, microcontrollers have read-mostly memory (RMM). There are several kinds of RMM found in microcontrollers. We will go into the details, examples, and applications of the different types of memories now. 

Read-mostly Memory (RMM)

Read-mostly memory (RMM) is the type of memory found in all microcontrollers. RMM is usually treated like ROM (read-only memory). After the memory unit is manufactured, data contained in ROM cannot be electronically changed. 

RMM has a unique advantage as compared to ROM where its contents can be updated without having to remove them from the circuit. However, RMM devices can only be written under special circumstances.

The most common type of RMM found on microcontrollers are EEPROM. This is a form of non-volatile memory used to store device configuration parameters for embedded applications. 

EEPROM – Reads fast, writes slowly

EEPROM can be erased and rewritten through the application of higher than normal electrical voltage, while still connected to the microcontroller. Unlike flash memory, EEPROM can only be written one byte at a time!

Source: Digi-Key

EEPROM is generally used to store system configuration parameters instead of files as the process of erasing and rewriting an EEPROM is not ideal for it to be used as a storage device. It also has a low data size.

EEPROM has a number of advantages that make it a popular option for embedded device developers:

  • Physically small footprint
  • comparatively low-cost
  • Bit rates usually range from 100 to 1000 kilobits per second (Kbits/s).
  • Standardized electrical interface
  • I2C and SPI interfaces are usually supported.

Despite its widespread use, EEPROM has a number of drawbacks:

  • 1,000,000 erase/write cycles are usually the maximum.
  • 500 nanosecond writing intervals (ns)
  • Writing a cell can be a tedious process
  • 10 years or more of data protection (recently 100 years or more is more common)
  • High operating temperatures and radiation susceptibility

EEPROMs are used in smart cards, remote keyless systems, and other electronic devices to store relatively small quantities of data by allowing individual bytes to be deleted and reprogrammed. 

Flash Memory – The type of memory that you already know about!

Flash memory, also called flash storage, is a nonvolatile memory that erases data in blocks and rewrites it at the byte level. Flash is technically an EEPROM, but it has some unique properties that make it useful in situations where the volume of data being processed is high and not written often.

Source: RS Components

As the heading suggests, flash memory is the most common type of memory that you probably associate “memory” with! For instance, USB flash drives (thumb drives) and SD cards are both external flash storage devices!

When it comes to microcontrollers, the type of flash memory used is normally eMMc.

Source: How-to-Geek

eMMC (Embedded MultiMediaCard) is the most common internal flash storage for microcontrollers. It is known for its tiny form factors and low price that makes it a popular choice in smartphones, cameras, laptops, tablets and microcontrollers!

Being a flash memory, eMMC has the same property as common external flash memory devices like SD cards! This is because they are both under the same category, MMC. Here’s a little known fact: SD cards are also known as memory card, which is a short form of MultiMediaCard (MMC). The slots on devices where SD card can be inserted are therefore called MMC slot!

This also means that embedded MMC (eMMC) are technically SD cards soldered directly onto the microcontrollers!

eMMC vs. SD Cards

As mentioned, SD Cards are external flash memory while eMMC is internal flash memory. If we were to compare them, we would be comparing internal and external flash memory.

The electrical interfaces of SD cards and eMMC systems are identical. That is, they share the same common pins for connecting devices to a microcontroller, despite the fact that they are packaged differently. They also have similar data sizes. The following are some of the distinctions between eMMC and SD cards:

  • eMMC is not removable, therefore not portable unlike SD cards
  • eMMC is more robust and less likely to have physical corruption, guaranteeing a longer lifespan.
  • Since eMMC are soldered directly on the microcontroller, it is not limited by the MMC slots speed, which means faster speed for eMMC.
  • SD cards are cheaper as compared to eMMC.

If you don’t need to delete the memory, eMMC is a better option, but it depends on the end-use.

Note: Not all memory are created equal even though they are from the same category. It would be wise to be meticulous in the details of the memory when choosing one.

Ferroelectric RAM (FRAM) – The lesser-known upgrade to EEPROM

EEPROMs are suitable for a wide range of applications, but for applications requiring high durability, such as those in the automotive, medical, or space systems industries, developers should opt for a more robust memory solution, such as FRAM.

Source: Wikipedia

FRAM is a non-volatile memory as well, but with a different design. FRAM is similar in construction to DRAM but uses a ferroelectric layer to achieve its non-volatility, hence its name Ferroelectric RAM. FRAM is considered a type of random-access memory (RAM) but with a non-volatile nature. It has data sizes similar to EEPROM.

FRAM has several advantages over flash and EEPROM which includes

  • Lower power usage,
  • Greater read/write endurance
  • Faster write performance

FRAM has been tested to have more than 10 years of data retention rate at extreme temperatures. 

FRAM have much lower storage densities, with higher storage limitation. It is also a lesser-known technology with a higher price tag, making it less popular for most applications. Unless one demands better durability, Flash and EEPROM should suffice!

What to look out for when selecting memory?

We’ve gone through and talked about the different types of embedded non-volatile memory found in microcontrollers. How do you go about selecting the ideal type of memory for your project then?

Every project has its own unique circumstances. While selecting your type of memory, take into account the following according to the requirements of your project:

  • Space requirements for the microcontroller.
  • The lifetime expectancy of the memory device.
  • Environmental conditions of the microcontroller mounting location.

You should also create a list of the minimum, desired, and maximum bit rates required to run the application successfully. Select the type of memory interface that best matches the specified bit rate.

Note: Integrate a break-out board with the microcontroller development kit to test the selected memory chip to check for compatibility whenever possible!

Microcontroller Recommendations

In the worst-case scenario, you might not be able to find a microcontroller that is ideal for your application. Fortunately, Seeed has a number of microcontroller boards that will provide you with sufficient power and memory to complete the task!

Seeeduino XIAO

Seeeduino XIAO is the smallest Arduino board in the Seeeduino Family. Despite its small size, the Seeeduino XIAO is equipped with the powerful SAMD21 microchip and extensive hardware interfaces, coming in at an ultra-affordable price of under five dollars.

Product Features:

  • ARM Cortex-M0+ 32bit 48MHz microcontroller (SAMD21G18) with 256KB Flash, 32KB SRAM
  • Compatible with Arduino IDE & MicroPython
  • Easy Project Operation: Breadboard-friendly
  • Small Size: As small as a thumb(20×17.5mm) for wearable devices and small projects.
  • Multiple development interfaces: 11 digital/analog pins, 10 PWM Pins, 1 DAC output, 1 SWD Bonding pad interface, 1 I2C interface, 1 UART interface, 1 SPI interface.

Keen to learn more about the Seeeduino XIAO? Visit its product page on our Seeed Online Store now!

Wio Terminal

The Wio Terminal is a complete Arduino development platform based on the ATSAMD51, with wireless connectivity powered by Realtek RTL8720DN. An all-in-one microcontroller, it has an onboard 2.4” LCD Display, IMU, microphone, buzzer, microSD card slot, light sensor & infrared emitter. With a whopping 4MB of flash memory and 192KB of RAM, it’s a perfect candidate for memory intensive uses like TinyML!

Product Features:

  • Powerful MCU: Microchip ATSAMD51P19 with ARM Cortex-M4F core running at 120MHz
  • Reliable Wireless Connectivity: Equipped with Realtek RTL8720DN, dual-band 2.4GHz / 5GHz Wi-Fi (supported only by Arduino)
  • Highly Integrated Design: 2.4” LCD Screen, IMU and Compact Enclosure with built-in magnets & mounting holes
  • Raspberry Pi 40-pin Compatible GPIO
  • Compatible with over 300 plug&play Grove modules to explore with IoT
  • USB OTG Support
  • Support Arduino, CircuitPython, Micropython, ArduPy, AT Firmware, Visual Studio Code
  • TELEC Certified

If you’re interested to pick up a Wio Terminal, please visit its product page on the Seeed Online Store!

Summary

This concludes today’s article on everything you need to know about embedded non-volatile microcontrollers memory! This has been a simple introduction to the different kinds of memory available.

The main thing to take note of is to be meticulous when choosing your type of memory, or any components of a microcontroller to ensure that you have chosen the most compatible one for your requirements. Thank you!

Please follow and like us:

Calendar

May 2021
M T W T F S S
 12
3456789
10111213141516
17181920212223
24252627282930
31  
Wordpress Social Share Plugin powered by Ultimatelysocial