Skip to product information
1 of 4





Regular price Rs. 1,889.00
Regular price Sale price Rs. 1,889.00
Sale Sold out
Tax included.

Out of stock

EEPROM2 click is aimed towards industrial and commercial applications, which require secure and reliable data storage. It can be used for any kind of temporary or permanent data storage for various embedded electronic devices, simple data logging, storing various working parameters of a module or device, sensitive data retention in case of a power cycle, and other similar applications where reliable EEPROM memory is needed.


The EEPROM module used on the EEPROM2 click is the M95M02, an SPI serial EEPROM from STMicroelectronics, with the memory cell density of 2 megabits (Mbit). The EEPROM density is expressed in bits, so exactly 2,097,152 bits are organized in units or words of 8 bits, which gives 262,144 bytes of data memory. Furthermore, the EEPROM is organized in memory pages. One page holds 256 bytes and there are 1024 pages (1024 pages x 256 bytes = 262,144 bytes total). Having insight into how the memory cells are organized, is important for Write and Erase operations. The SPI pins are routed to the mikroBUS™ so the communication is easy and straightforward. The M95M02 IC supports clock frequency up to 5MHz.

This Click board™ uses the SPI communication protocol. To ensure reliable data transaction and to avoid accidental write to the memory array, the device employs certain protection mechanisms. When the M95M02 IC is powered up and when the power supply voltage reaches a certain threshold, the device will reset itself, setting up the internal logic in a known state. In addition, before writing any data to the IC which modifies registers or the array itself, the WEL bit must be set. This bit is cleared after or during every memory modification instruction. Therefore every memory modification instruction must be prefixed with the Write Enable instruction that sets this bit. This mechanism ensures that only the intended write instruction will be executed.

Communication with the device is initiated by the host MCU, which drives the chip select pin (#S on the schematic) to a LOW logic level. This pin is routed to the mikroBUS™ CS pin. The next byte of information can be either command or data. Usually, the first byte is the instruction (command) followed by the memory address. Depending on the command that has been sent, either the memory is written to, or read from the specific memory address. Memory address on this device is 18 bit (0x00000 to 0x3FFFF) and therefore it is sent by 3 bytes.

There are several instruction codes, which can be sent after the CS pin being driven to a LOW logic level. These include Write Enable and Disable, Write and Read from memory array, Read and Write to Status register, and so on. For a full list of commands, please refer to the datasheet of the M95M02 IC.

When using the Write to array instruction, it is possible to write up to 256 bytes in one write cycle. The internal address pointer is increased with each received byte. If attempting to write more than 256 bytes of data, a rollover will happen, writing the data from the beginning of the page. This is due to page organization of the memory array; only one full page can be written within a single write cycle.

The M95M02 includes a write protection of the specific parts or the whole memory array. The write protection consists of two bits in the Status Register (B0, B1), and the SRWD bit. The Status Register Write instruction can be used to set or reset these bits. B0 and B1 bits control the write-protect status of the memory array (from one quarter to full memory array protection). While the SRWD bit of the Status Register is set to 1, it is not possible to change the B0 and B1 bits. These bits are non-volatile and their state is retained between the power cycles.

One of the key features of the M95M02 IC is the Error Correction Code logic (ECC), which allows error correction by utilizing six additional bits, internally assigned to a group of four bytes. This protection scheme is capable of correcting some types of bit errors, staying transparent to the end user. The bit comparison and error correction are done internally.

Another feature of the M95M02 IC is an identification memory page, 256 bytes long. This page can be used to store an ID or other sensitive data, and once written, it can be permanently locked. The IC supports a set of instructions, used to perform the write, read and lock operation over this memory page.

EEPROM2 click offers a selection between 3.3V and 5V operation, with the onboard SMD jumper, labeled as PWR SEL. This allows both 3.3V and 5V MCUs to be interfaced with this Click board™.


Applications EEPROM 2 click is an excellent choice for storing initialization and configuration data of your device
On-board modules ST’s M95M02-DR DIP-8 socket EEPROM chip with 256 KB of memory
Key Features 256 KB of memory. Write speed within 10 ms (byte/page)
Interface SPI
Compatibility mikroBUS
Click board size S (28.6 x 25.4 mm)
Input Voltage 3.3V or 5V


This table shows how the pinout on EEPROM2 click corresponds to the pinout on the mikroBUS™ socket (the latter shown in the two middle columns).

Notes Pin Mikrobus logo.png Pin Notes
Chip Select CS 3 CS RX 14 NC
SPI Clock SCK 4 SCK TX 13 NC
Power Supply +3V3 7 3.3V 5V 10 +5V Power Supply
Ground GND 8 GND GND 9 GND Ground


Label Name Default Description
JP1 PWR.SEL. Left Logic voltage level selection: left position 3V3, right position 5V
LD1 PWR Power indication LED


We provide a library for EEPROM2 click on our Libstock page, as well as a demo application (example), developed using MikroElektronika compilers and mikroSDK. The provided click library is mikroSDK standard compliant. The demo application can run on all the main MikroElektronika development boards.

Library Description

This library provides generic functions enough to have complete control over the EEPROM 2 click.

Key functions:

  • void eeprom2_writeBytes(uint32_t memoryAddress, uint8_t *value, uint8_t count) - Writes the function to EEPROM.
  • void eeprom2_readBytes(uint32_t memoryAddress, uint8_t *value, uint8_t count) - Reads the function from EEPROM.
  • void eeprom2_memoryEnable() - Enables the write function.

Examples Description

The application is composed of three sections:

  • System Initialization - CS GPIO as the output pin, initializes SPI and UART for logging.
  • Application Initialization - Initializes EEPROM 2 driver.
  • Application Task - writing data to EEPROM, reading that data and displaying it via UART.
void applicationTask()

eeprom2_writeBytes(0x01, &text[0], 6);
mikrobus_logWrite("Writing Mikroe to EEPROM 2 click", _LOG_LINE);
mikrobus_logWrite("Data read:", _LOG_LINE);
mikrobus_logWrite(memValue, _LOG_LINE);

The full application code, and ready to use projects can be found on our Libstock page.

Other mikroE Libraries used in the example:

  • I2C
  • UART

Additional notes and information

Depending on the development board you are using, you may need USB UART click, USB UART 2 click or RS232 click to connect to your PC, for development systems with no UART to USB interface available on the board. The terminal available in all MikroElektronika compilers, or any other terminal application of your choice, can be used to read the message.


This click board is supported by mikroSDK - MikroElektronika Software Development Kit. To ensure proper operation of mikroSDK compliant click board demo applications, mikroSDK should be downloaded from the LibStock and installed for the compiler you are using.

View full details

Featured collection

The crazyflie is a versatile platform that is designed to engage people in learning about robotics and quadcopters.
1 of 25