How to choose your on-board memory? What are the different types of memory?

Introduction

There are many types of memory for operating a system. The memory is used to save all the programs
contents, operating system.
That’s mean all the data you need to make an embedded system operational.

Why are there different types of memory?

The purpose of a memory is to save information and communicate them when it’s necessary.
Nevertheless, you have some on-board memories which commmunicates quicker than others, but they also cost more.
Furthermore, you have some memory which erase themselves when the embedded system ahs been turn off.
Therefore it is necessary to choose the right type of memory in function of it’s using.

What is the measure unity of a memory?

An on-board memory is mesuring in Byte. 1 byte = 8 bits

The different types of on-board memories

a)  RAM (Random access Memory)

This memory is very known because it is used in the computers. Furthermore it is a key element in the speed of a computer.
In the RAM memory you can copy a program, which will increase the speed of his execution.

Therefore, more the embedded system has a lot of RAM, more this one can copy a lot of program quickly.
Nevertheless, the RAM is a volatile memory, that’s mean that when the embedde system is turn off, the memory is erased.

Therefore we can’t save data like in a hard drive to save a program for example.
Finally, the RAM memory is expensive, therefore can’t have in as large quantities as flash memory.

b)  Flash Memory

The memory flash is as necessary as the ram memory. it corresponds to the hard drive of your computer. It is used
to save all the programs and the operationnal system of your computer or embedded system, because it’s not a volatile memory.
It’s not an expensive memory, therefore it can be used in a large quantity.

The flash memory is a non volatile memory that’s mean that the data will stay saved after turning off your computer or embedde system. Nevertheless, the flash memory is slow
comapred to the RAM, that why in a computer, you have always memory flash and RAM to have a compromise and
having the quickest computer possible with reasonable cost.

c)   EEPROM (Electrically-erasable programmable read-only memory)

The EEPROM is a different memory than the flash memory because you can read it and not write it.
This memory has to be program in advance and the data on it can’t be modified, in constrast of the RAM and the flash memory.
The EEPROM is not volatile, that mean when the embedded system is turned off the data are still saved.

Finally it’s not an expensive memory, therefore it can be used in a large quantity.

Table with the different types of on-board memories

 DescriptionVolatileRequired/OptionalSpeedTypical size
Price
RAMMemory which store variablesVolatile (=loss of information
after turn off the embedded system)
 RequiredQuickfew Bytes to few Kilo-BytesExpensive
Flash Memory
Program Memory ( where the program is saved)
No volatile (= the data is still here after turning off the embedded system)RequiredSlowsome kilo-Bytes to a few Mega-BytesCheap
EEPROMParameters Memory (= parameters can change over time)No volatileOptionalSlowsome Bytes to some Kilo-BytesCheap

Conclusion

In conclusion, we have seen that there are different type of memory in an embedded system.
All theses memories are complementary, that mean you will need to choose more than one memory to build your system.