# Adafruit SPI FLASH Breakouts

## Overview

![](https://cdn-learn.adafruit.com/assets/assets/000/123/221/medium800/components_5635-03.jpg?1690985834)

Sometimes you need a little extra storage for your microcontroller projects: for files, images, fonts, audio clips, etc. If you need lots of space, like in the gigabytes,&nbsp;[we always recommend an SD card](https://www.adafruit.com/product/254)&nbsp;because you can easily plug it into a computer to edit files. But sometimes you don't need whole gigabytes, you just need a megabyte or two, with the lower cost and power usage that comes with it. That's when we recommend an&nbsp; **Adafruit SPI FLASH Breakout** in one of three variants: [W25Q16 - 16 Mbit **/ 2 MByte**](https://www.adafruit.com/product/5635), [**W25Q64** - 64 Mbit / 8 MByte](https://www.adafruit.com/product/5636) or [W25Q128&nbsp;- **128** &nbsp;Mbit / 16&nbsp;MByte](https://www.adafruit.com/product/5643)&nbsp;chip.

![](https://cdn-learn.adafruit.com/assets/assets/000/123/222/medium800/components_5635-02.jpg?1690985859)

[Compared to our QSPI breakouts](https://www.adafruit.com/?q=qspi+breakout&sort=BestMatch), this one is single-channel SPI only...BUT it comes with level shifting so it can be used safely with 3V or 5V power and logic. Since we needed to add level shifting, the&nbsp;chip is pre-wired into single channel&nbsp;"SPI" mode, with a level shifters so you can use it with 3V or 5V logic easily. You also get a 3.3V regulator and a pullup on CS.&nbsp;

![](https://cdn-learn.adafruit.com/assets/assets/000/123/223/medium800/components_5635-01.jpg?1690985870)

Note that the chips come blank, and do not have a wear-leveling subsystem. You can address them as a flat memory space or, if you like, format them with a filesystem like littleFS or FAT. Great for use with data-logging or storage needs where you are OK with doing the management yourself - or if you are adding external memory to an older chip that would like 5V-compatibility.

[In Arduino, we have the Adafruit\_SPIFlash library](https://github.com/adafruit/Adafruit_SPIFlash)&nbsp;that can be used to interface with this chip. Comes with a bit of header that can be used to solder in and plug into a breadboard if desired.

# Adafruit SPI FLASH Breakouts

## Pinouts

![](https://cdn-learn.adafruit.com/assets/assets/000/116/716/medium800/components_dbl.jpg?1668617271)

## Power Pins

- **VIN** - this is the power pin. Since the flash chip may use 3 VDC, we have included a level shifter on board that will take 3-5VDC and safely convert it down. To power the board, give it the same power as the logic level of your microcontroller - e.g. for a 5V microcontroller like Arduino, use 5V.
- **3V3** &nbsp;- this is the 3.3V output from the level shifter, you can grab up to 100mA from this if you like.
- **GND** &nbsp;- common ground for power and logic.

## SPI Logic Pins

- **SCK** - This is the SPI&nbsp;Clock&nbsp;pin /&nbsp; **SCK S** erial&nbsp; **C** loc **k** , it's an input to the flash chip.
- **MISO** - this is the&nbsp; **S** erial&nbsp; **O** ut /&nbsp; **M** icrocontroller&nbsp; **I** n&nbsp; **S** erial&nbsp; **O** ut pin, for data sent from the flash chip to your processor.
- **MOSI** - this is the&nbsp; **S** erial&nbsp; **I** n /&nbsp; **M** icrocontroller&nbsp; **O** ut&nbsp; **S** erial&nbsp; **I** n pin, for data sent from your processor to the flash chip. It's an input to the chip.
- **CS** - this is the&nbsp; **C** hip&nbsp; **S** elect pin, drop it low to start an SPI transaction. It's an input to the flash chip and has a pullup.&nbsp;

# Adafruit SPI FLASH Breakouts

## Arduino

Using a SPI flash breakout board&nbsp;with Arduino involves wiring up the flash chip to your Arduino-compatible microcontroller, installing the&nbsp;[Adafruit\_SPIFlash](https://github.com/adafruit/Adafruit_SPIFlash)&nbsp;library&nbsp;and running the provided example code.

## Wiring

Wire as shown for a&nbsp; **5V** &nbsp;board like an Uno. If you are using a **&nbsp;3V** &nbsp;board, like an Adafruit Feather, wire the board's 3V pin to the flash breakout VIN.

Here is an Adafruit Metro wired up to the flash breakout using a solderless breadboard.

- **Board 5V** &nbsp;to&nbsp;**breakout VIN (red wire)**
- **Board GND** &nbsp;to&nbsp;**breakout GND (black wire)**
- **Board pin 10** to **breakout CS (orange wire)**
- **Board pin 11** &nbsp;to&nbsp;**breakout MOSI (blue wire)**
- **Board pin 12** &nbsp;to&nbsp;**breakout MISO (green wire)**
- **Board pin 13** &nbsp;to&nbsp;**breakout SCK (yellow wire)**

![components_spiFlashArduinoBB_bb.jpg](https://cdn-learn.adafruit.com/assets/assets/000/124/237/medium640/components_spiFlashArduinoBB_bb.jpg?1694025634)

## Library Installation

You can install the&nbsp; **Adafruit SPIFlash&nbsp;** library&nbsp;for Arduino using the Library Manager in the Arduino IDE.

![](https://cdn-learn.adafruit.com/assets/assets/000/116/717/medium800/components_Arduino_Open_Library_Manager.png?1668618668)

Click the&nbsp; **Manage Libraries ...** &nbsp;menu item, search for&nbsp; **Adafruit SPIFlash** ,&nbsp;and select the&nbsp; **Adafruit SPIFlash** &nbsp;library:

![](https://cdn-learn.adafruit.com/assets/assets/000/116/718/medium800/components_libManager.jpg?1668618688)

If asked about dependencies, click "Install all".

![](https://cdn-learn.adafruit.com/assets/assets/000/116/719/medium800/components_arduinoDependencies.jpg?1668618706)

If the "Dependencies" window does not come up, then you already have the dependencies installed.&nbsp;

Warning: 

## Example Code
https://github.com/adafruit/Adafruit_Learning_System_Guides/blob/main/SPI_Breakout_Flash_Info/SPI_Breakout_Flash_Info.ino

![](https://cdn-learn.adafruit.com/assets/assets/000/124/238/medium800/components_flash_info.png?1694026034)

Upload the read/write sketch to your board and open up the Serial Monitor ( **Tools -\> Serial Monitor** ) at 115200 baud. You'll see the flash ID and size printed to the Serial Monitor.

# Adafruit SPI FLASH Breakouts

## Arduino Docs

# Adafruit SPI FLASH Breakouts

## Downloads

## Files

- [Flash Module Datasheet](https://cdn-learn.adafruit.com/assets/assets/000/116/709/original/datasheetQspi.pdf?1668549256)
- [W25Q16 Technical Documentation](https://www.winbond.com/hq/product/code-storage-flash-memory/serial-nor-flash/?__locale=en&partNo=W25Q16JV)
- [W25Q64 Technical Documentation](https://www.winbond.com/hq/product/code-storage-flash-memory/serial-nor-flash/?__locale=en&partNo=W25Q64FV)
- [W25Q128 Technical Documentation](https://www.winbond.com/hq/product/code-storage-flash-memory/serial-nor-flash/?__locale=en&partNo=W25Q128JV)
- [EagleCAD PCB files on GitHub](https://github.com/adafruit/Adafruit-SPI-Flash-Breakout-PCB)
- [Fritzing object in the Adafruit Fritzing Library](https://github.com/adafruit/Fritzing-Library/blob/master/parts/Adafruit%20SPI%20FLASH%20Breakout.fzpz)

## Schematic and Fab Print

These apply to all versions of the board.

![](https://cdn-learn.adafruit.com/assets/assets/000/116/721/medium800/components_schem.png?1668619694)

![](https://cdn-learn.adafruit.com/assets/assets/000/116/722/medium800/components_fab.png?1668619701)


## Primary Products

### Adafruit SPI FLASH Breakout - W25Q16 - 16 Mbit / 2 MByte

[Adafruit SPI FLASH Breakout - W25Q16 - 16 Mbit / 2 MByte](https://www.adafruit.com/product/5635)
Sometimes you need a little extra storage for your microcontroller projects: for files, images, fonts, audio clips, etc. If you need lots of space, like in the gigabytes, [we always recommend an SD card](https://www.adafruit.com/product/254) because you can easily plug it into a...

In Stock
[Buy Now](https://www.adafruit.com/product/5635)
[Related Guides to the Product](https://learn.adafruit.com/products/5635/guides)
### Adafruit SPI FLASH Breakout - W25Q64 - 64 MBit / 8 MByte

[Adafruit SPI FLASH Breakout - W25Q64 - 64 MBit / 8 MByte](https://www.adafruit.com/product/5636)
Sometimes you need a little extra storage for your microcontroller projects: for files, images, fonts, audio clips, etc. If you need lots of space, like in the gigabytes, [we always recommend an SD card](https://www.adafruit.com/product/254) because you can easily plug it into a...

In Stock
[Buy Now](https://www.adafruit.com/product/5636)
[Related Guides to the Product](https://learn.adafruit.com/products/5636/guides)
### Adafruit SPI FLASH Breakout W25Q128 - 128 MBit / 16 MByte

[Adafruit SPI FLASH Breakout W25Q128 - 128 MBit / 16 MByte](https://www.adafruit.com/product/5643)
Sometimes you need a little extra storage for your microcontroller projects: for files, images, fonts, audio clips, etc. If you need lots of space, like in the gigabytes,&nbsp;[we always recommend an SD card](https://www.adafruit.com/product/254)&nbsp;because you can easily plug it...

In Stock
[Buy Now](https://www.adafruit.com/product/5643)
[Related Guides to the Product](https://learn.adafruit.com/products/5643/guides)

## Related Guides

- [Adafruit Audio BFF](https://learn.adafruit.com/adafruit-audio-bff.md)
- [74HC595 Shift Register](https://learn.adafruit.com/74hc595.md)
- [Adafruit QT Py CH32V203](https://learn.adafruit.com/adafruit-qt-py-ch32v203.md)
- [Adafruit ItsyBitsy RP2040](https://learn.adafruit.com/adafruit-itsybitsy-rp2040.md)
- [Wireless Security Camera with the Arduino Yun](https://learn.adafruit.com/wireless-security-camera-arduino-yun.md)
- [Adafruit 1-Wire GPIO Breakout - DS2413](https://learn.adafruit.com/adafruit-1-wire-gpio-breakout-ds2413.md)
- [Adafruit Capacitive Touch Sensor Breakouts](https://learn.adafruit.com/adafruit-capacitive-touch-sensor-breakouts.md)
- [Adafruit TSSP77038 38KHz Infrared IR Demodulator Breakout](https://learn.adafruit.com/adafruit-tssp77038-38khz-infrared-ir-demodulator-breakout.md)
- [DC & USB Boarduino Kits](https://learn.adafruit.com/boarduino-kits.md)
- [Playing sounds and using buttons with Raspberry Pi](https://learn.adafruit.com/playing-sounds-and-using-buttons-with-raspberry-pi.md)
- [Adafruit USB Type C Power Delivery Switchable Breakout](https://learn.adafruit.com/adafruit-usb-type-c-power-delivery-switchable-breakout.md)
- [Adafruit USB Host FeatherWing with MAX3421E](https://learn.adafruit.com/adafruit-usb-host-featherwing-with-max3421e.md)
- [Adafruit TCA8418 Keypad Matrix and GPIO Expander Breakout](https://learn.adafruit.com/adafruit-tca8418-keypad-matrix-and-gpio-expander-breakout.md)
- [LSM303 Accelerometer + Compass Breakout](https://learn.adafruit.com/lsm303-accelerometer-slash-compass-breakout.md)
- [Pico W YBox3](https://learn.adafruit.com/pico-w-ybox3.md)
