swieeprom 2.1.0.0
|
SWI EEPROM Click is a compact add-on board that provides a highly reliable memory solution. This board features the AT21CS01, a single-wire serial EEPROM with a unique, factory-programmed 64-bit serial number from Microchip Technology. The AT21CS01 has an ultra-high write endurance capability allowing more than one million cycles for each memory location to meet the requirements for today's high-write endurance applications. It is internally as 128 words of 8 bits each with achieved communication through a single I/O pin with Standard-Speed and High-Speed mode options. Also, it offers a security register with a factory-programmed serial number, which makes it the easiest way to add identification to various accessories and consumables.
We provide a library for the SWI EEPROM Click as well as a demo application (example), developed using MikroElektronika compilers. The demo can run on all the main MikroElektronika development boards.
Package can be downloaded/installed directly from NECTO Studio Package Manager(recommended way), downloaded from our LibStock™ or found on Mikroe github account.
This library contains API for SWI EEPROM Click driver.
swieeprom_cfg_setup
Config Object Initialization function. swieeprom_init
Initialization function. swieeprom_mem_write_page
This function writes data to the specified memory address page. swieeprom_mem_read
This function reads data from the specified memory address. swieeprom_mem_clear
This function clears the whole memory to zero. This example demonstrates the use of SWI EEPROM click board by writing specified data to the memory and reading it back.
The demo application is composed of two sections :
Initializes the driver and logger and checks the communication.
Writes the specified text message to the memory and reads it back. After that, erases
the whole memory and tries to read the same message verifying that the memory is erased. All data is being displayed on the USB UART where you can track the program flow.
This application is written for the following MCUs and specifically for MIKROBUS 1:
STM32F407ZG, MK64FN1M0VDC12, TM4C129XNCZAD, GD32VF103VBT6, PIC32MX795F512L In order to use it on another MCUs the pin_x functions must be defined in a way it matches the required timing specifications for the Single Wire interface.
The full application code, and ready to use projects can be installed directly from NECTO Studio Package Manager(recommended way), downloaded from our LibStock™ or found on Mikroe github account.
Other Mikroe Libraries used in the example:
Additional notes and informations
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. UART terminal is available in all MikroElektronika compilers.