Flash 6 Click Board
Flash 6 Click Board
The Flash 6 Click Board™ is based on the W25Q128JV (128M-bit) flash memory from Winbond provides a storage solution for systems with limited space, pins and power. The 25Q series offers flexibility and performance well beyond ordinary Serial Flash devices. They are ideal for code shadowing to RAM, executing code directly from Dual/Quad SPI (XIP) and storing voice, text and data. The small 4KB sectors allow for greater flexibility in applications that require data and parameter storage.
The Flash 6 Click Board™ is supported by a mikroSDK compliant library, which includes functions that simplify software development. This Click Board™ comes as a fully tested product, ready to be used on a system equipped with the mikroBUS™ socket.
How Does The Flash 6 Click Board™ Work?
The Flash 6 Click Board™ is based on the W25Q128JV array is organized into 65,536 programmable pages of 256-bytes each. Up to 256 bytes can be programmed at a time. Pages can be erased in groups of 16 (4KB sector erase), groups of 128 (32KB block erase), groups of 256 (64KB block erase) or the entire chip (chip erase). The W25Q128JV has 4,096 erasable sectors and 256 erasable blocks respectively. The small 4KB sectors allow for greater flexibility in applications that require data and parameter storage.
The Flash 6 Click Board™ uses the standard Serial Peripheral Interface (SPI), supporting SPI clock frequencies of up to 133MHz Single, Dual/Quad SPI clocks. Besides that, the W25Q128JV provides a Continuous Read Mode that allows for efficient access to the entire memory array with a single Read command. This feature is ideal for code shadowing applications. Also, it offers the highest performance thanks to 133MHz Standard/Dual/Quad SPI clocks and a 66MB/S continuous data transfer rate. Given the fact it has a efficient "Continuous Read Mode", it allows direct read access to the entire array. However, the performance also depends on the main MCU used with this Click board™.
A Hold pin, Write Protect pin and programmable write protection, provide further control flexibility. Additionally, the device supports JEDEC standard manufacturer and device ID and SFDP, and a 64-bit Unique Serial Number and three 256-bytes Security Registers.
The W25Q128JV is accessed through an SPI compatible bus consisting of four signals: Serial Clock (CLK), Chip Select (/CS), Serial Data Input (DI) and Serial Data Output (DO). Standard SPI instructions use the DI input pin to serially write instructions, addresses or data to the device on the rising edge of CLK. The DO output pin is used to read data or status from the device on the falling edge of CLK.
For the detailed explanation, please consult the included datasheet. However, MikroElektronika provides a library which contains functions that simplify and speed up working with this device. The provided application example demonstrates the functionality of the library functions. It can be used as a reference for a custom project development.
The Flash 6 Click Board™ is designed to be operated only with 3.3V logic level. A proper logic voltage level conversion should be performed before the Click board™ is used with MCUs with logic levels of 5V.
SPECIFICATIONS
Type | FLASH |
Applications | A storage solution for systems with limited space, pins and power, code shadowing to RAM, executing code directly from Dual/Quad SPI (XIP) and storing voice, text and data. |
On-board modules | W25Q128JV (128M-bit) Flash Memory from Winbond |
Key Features | Highest Performance Serial Flash, Efficient "Continuous Read", Advanced Security Features |
Interface | QSPI,SPI |
Compatibility | mikroBUS |
Click board size | S (28.6 x 25.4 mm) |
Input Voltage | 3.3V |
PINOUT DIAGRAM
This table shows how the pinout on the Flash 6 Click corresponds to the pinout on the mikroBUS™ socket (the latter shown in the two middle columns).
Notes | Pin | Pin | Notes | ||||
---|---|---|---|---|---|---|---|
NC | 1 | AN | PWM | 16 | IO2 | WP/IO2 | |
NC | 2 | RST | INT | 15 | IO3 | HOLD/IO3 | |
SPI Chip Select | CS | 3 | CS | RX | 14 | NC | |
SPI Clock | SCK | 4 | SCK | TX | 13 | NC | |
SPI Data OUT/IO1 | SDO | 5 | MISO | SCL | 12 | NC | |
SPI Data IN/IO0 | SDI | 6 | MOSI | SDA | 11 | NC | |
Power Supply | 3.3V | 7 | 3.3V | 5V | 10 | NC | |
Ground | GND | 8 | GND | GND | 9 | GND | Ground |
ONBOARD SETTINGS AND INDICATORS
Label | Name | Default | Description |
---|---|---|---|
LD1 | PWR | - | Power LED Indicator |
Software Support
We provide a library for the Flash 6 Click Board™ on our LibStock page, as well as a demo application (example), developed using MikroElektronika compilers. The demo can run on all the main MikroElektronika development boards.
Library Description
Library contains function for write in memory and read from memory.
Key Functions
void flash6_erase_memory_segment( uint8_t segment, uint32_t start_addr );
- Function for eraseing segmentvoid flash6_write_memory_data ( uint32_t addr, uint8_t *data_buf, uint16_t buf_size );
- Function used for writing in memoryvoid flash6_read_memory_data ( uint32_t addr, uint8_t *data_buf, uint16_t buf_size );
- Function used for reading from memory
Example Description
The application is composed of three sections :
- System Initialization - Initializes SPI module
- Application Initialization - Initializes driver, resets device and tests communication.
- Application Task - Clears the memory sector, writes "MikroE" to device memory and then reads it and sends it to log every 2 sec.
void application_task ( ) { uint32_t start_addr; uint8_t read_buff[ 50 ]; uint8_t cnt; start_addr = 0x002000; mikrobus_logWrite( " >>>> Erase sector <<<< ", _LOG_LINE ); flash6_erase_memory_segment( FLASH6_CMD_SECTOR_ERASE_4KB, start_addr ); Delay_ms( 500 ); mikrobus_logWrite( " >>>> Write in memory <<<< ", _LOG_LINE ); mikrobus_logWrite( " >>>> ............... <<<< ", _LOG_LINE ); flash6_write_memory_data( start_addr, &write_buf[ 0 ], 6 ); mikrobus_logWrite( " >>>> Read from memory <<<< ", _LOG_LINE ); flash6_read_memory_data( start_addr, &read_buff[ 0 ], 6 ); mikrobus_logWrite( " >>>> ", _LOG_TEXT ); for( cnt = 0; cnt < 6; cnt++ ) { mikrobus_logWrite( &read_buff[ cnt ], _LOG_BYTE ); mikrobus_logWrite( " ", _LOG_TEXT ); Delay_ms( 100 ); } mikrobus_logWrite( " <<<< ", _LOG_LINE ); mikrobus_logWrite( "---------------------------", _LOG_LINE ); Delay_ms( 2000 ); } The full application code, and ready to use projects can be found on our LibStock page.
Other mikroE Libraries used in the example:
- SPI Library
- Conversions Library
Additional Notes and Information
Depending on the development board you are using, you may need a 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.
MIKROSDK
The Flash 6 Click Board™ is supported with 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.
Software Support
We provide a library for the Flash 6 Click Board™ on our LibStock page, as well as a demo application (example), developed using MikroElektronika compilers. The demo can run on all the main MikroElektronika development boards.
Library Description
Library contains function for write in memory and read from memory.
Key Functions
void flash6_erase_memory_segment( uint8_t segment, uint32_t start_addr );
- Function for eraseing segmentvoid flash6_write_memory_data ( uint32_t addr, uint8_t *data_buf, uint16_t buf_size );
- Function used for writing in memoryvoid flash6_read_memory_data ( uint32_t addr, uint8_t *data_buf, uint16_t buf_size );
- Function used for reading from memory
Example Description
The application is composed of three sections :
- System Initialization - Initializes SPI module
- Application Initialization - Initializes driver, resets device and tests communication.
- Application Task - Clears the memory sector, writes "MikroE" to device memory and then reads it and sends it to log every 2 sec.
void application_task ( ) { uint32_t start_addr; uint8_t read_buff[ 50 ]; uint8_t cnt; start_addr = 0x002000; mikrobus_logWrite( " >>>> Erase sector <<<< ", _LOG_LINE ); flash6_erase_memory_segment( FLASH6_CMD_SECTOR_ERASE_4KB, start_addr ); Delay_ms( 500 ); mikrobus_logWrite( " >>>> Write in memory <<<< ", _LOG_LINE ); mikrobus_logWrite( " >>>> ............... <<<< ", _LOG_LINE ); flash6_write_memory_data( start_addr, &write_buf[ 0 ], 6 ); mikrobus_logWrite( " >>>> Read from memory <<<< ", _LOG_LINE ); flash6_read_memory_data( start_addr, &read_buff[ 0 ], 6 ); mikrobus_logWrite( " >>>> ", _LOG_TEXT ); for( cnt = 0; cnt < 6; cnt++ ) { mikrobus_logWrite( &read_buff[ cnt ], _LOG_BYTE ); mikrobus_logWrite( " ", _LOG_TEXT ); Delay_ms( 100 ); } mikrobus_logWrite( " <<<< ", _LOG_LINE ); mikrobus_logWrite( "---------------------------", _LOG_LINE ); Delay_ms( 2000 ); } The full application code, and ready to use projects can be found on our LibStock page.
Other mikroE Libraries used in the example:
- SPI Library
- Conversions Library
Additional Notes and Information
Depending on the development board you are using, you may need a 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.
MIKROSDK
The Flash 6 Click Board™ is supported with 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.
Flash 6 Click Board
Frequently Asked Questions
Have a Question?
Be the first to ask a question about this.