# Adafruit 5x5 NeoPixel Grid BFF

## Overview

![](https://cdn-learn.adafruit.com/assets/assets/000/116/785/medium800thumb/adafruit_products_5646-05.jpg?1669146721)

Our QT Py boards are a great way to make very small microcontroller projects that pack a ton of power - and now we have a way for you to quickly add a glittering grid of 25 RGB addressable micro NeoPixels. It's an excellent way to make tiny wearable, cosplay, or IoT projects with dazzling LEDs.

![](https://cdn-learn.adafruit.com/assets/assets/000/123/229/medium800/adafruit_products_5646-07.jpg?1690986092)

We call this the **Adafruit 5x5 NeoPixel Grid BFF** - a "Best Friend Forever". When you were a kid you may have learned about the "buddy" system, well this product is kinda like that! A board that will watch your QT Py's back and act like a technicolor raincoat.

![](https://cdn-learn.adafruit.com/assets/assets/000/123/230/medium800/adafruit_products_5646-06.jpg?1690986106)

This PCB is designed to fit onto the back of any QT Py or Xiao board, it can be soldered into place or use pin and socket headers to make it removable. Onboard is a grid of 25 1.5x1.5mm NeoPixel LEDs (SK6805 to be exact), connected to pin A3 by default. You can cut/solder some jumpers to select A1, or A2 instead if you like. There's also solder pads for 5V, GND and IN data, in case you want to power externally. Advanced solderers can use a thin wire to connect from the IN pad to other GPIO pins if desired.

![](https://cdn-learn.adafruit.com/assets/assets/000/116/786/medium800thumb/adafruit_products_5646-04.jpg?1669146933)

We include some header that you can solder to your QT Py. [You can also pick up an Itsy Bitsy short female header kit to make it removable but compact](https://www.adafruit.com/product/4174), you'll just need to trim down the headers to 7 pins long.

- Comes as an assembled and tested PCB
- For any QT Py or Xiao boards
- Uses the 5V input via USB Type-C connector on QT Py to power 25 NeoPixels
- Default connected to pin A3 for NeoPixel data line. Not level shifted but the SK6805's&nbsp;are happy to run at 5V power with 3V input logic level.

**QT Py is&nbsp;not included**.

# Adafruit 5x5 NeoPixel Grid BFF

## Pinouts

![](https://cdn-learn.adafruit.com/assets/assets/000/116/794/medium800/adafruit_products_dbl.jpg?1669640474)

The default input pin is **A3**.

## External Input Pads

These pads are for powering and/or controlling the board externally. They are located at the top of the board going horizontally across.

- **-** &nbsp; - common ground for power and logic.
- **+** &nbsp; - 5V input power pad.&nbsp;
- **In** - **In** put data pin. Connect to a data output pin if controlling externally.

## A3 Jumper

- **A3 jumper** - This jumper is located on the front of the board, towards the right and is labeled **A3**. If cut, the **In** pin is no longer connected to **A3** and you can solder one of the solder-jumpers closed to change the output pin.

## Pin Select Solder-jumpers

- Two solder-jumpers are available to change the&nbsp; **in** put pin for the NeoPixel BFF. They are placed in the top right-hand corner on the front of the board and are located next to their corresponding pin names. You can choose to solder one of the solder-jumpers for one of the following pins:
  - **A1**
  - **A2**

# Adafruit 5x5 NeoPixel Grid BFF

## CircuitPython

It's easy to use the **5x5 NeoPixel Grid BFF** with CircuitPython and the [Adafruit\_CircuitPython\_NeoPixel](https://github.com/adafruit/Adafruit_CircuitPython_NeoPixel) module. This module allows you to easily write Python code that lets you control NeoPixels.

## CircuitPython Microcontroller Wiring

Plug a 5x5 NeoPixel Grid BFF into your QT Py or Xiao form factor board exactly as shown below. Here's an example of connecting a QT Py RP2040 to the BFF.

Connect the QT Py RP2040 with plug headers into the 5x5 NeoPixel Grid BFF with socket headers. They should be plugged in with the backs of the boards facing each other.

For more information on soldering socket headers,&nbsp;[check out this Learn Guide](https://learn.adafruit.com/how-to-solder-headers/female-headers).

![adafruit_products_edited_P1390316.jpg](https://cdn-learn.adafruit.com/assets/assets/000/116/795/medium640/adafruit_products_edited_P1390316.jpg?1669641744)

[How to Solder Headers Learn Guide](https://learn.adafruit.com/how-to-solder-headers/female-headers)
## CircuitPython Usage

To use with CircuitPython, you need to first install the NeoPixel library, and its dependencies, into the **lib** folder on your **CIRCUITPY** drive. Then you need to update **code.py** with the example script.

Thankfully, we can do this in one go. In the example below, click the **Download Project Bundle** button below to download the necessary libraries and the **code.py** file in a zip file. Extract the contents of the zip file, and copy the **entire lib folder** , the **tom-thumb.pcf** font file, and the **code.py** file to your **CIRCUITPY** drive.

Your **CIRCUITPY/lib** folder should contain the following folders and files:

- **/adafruit\_bitmap\_font**
- **/adafruit\_display\_text**
- **adafruit\_pixelbuf.mpy**
- **neopixel.mpy**

Additionally, a font file, **tom-thumb.pcf** , is included. This font will be utilized in both examples.

![CIRCUITPY](https://adafruit.github.io/Adafruit_Learning_System_Guides/5x5_NeoPixel_BFF_Examples_CircuitPython_Scrolling_Text.png )

## Basic Scrolling Text Example
https://github.com/adafruit/Adafruit_Learning_System_Guides/blob/main/5x5_NeoPixel_BFF_Examples/CircuitPython_Scrolling_Text/code.py

Once everything is saved to the **CIRCUITPY** drive, you'll see your 5x5 NeoPixel grid scroll the text "Hello World!! Adafruit QT Py RP2040 + NeoPixel BFF" in rainbow colors.

You can edit the scrolling text by updating the `text` property of `label`.

```python
label = Label(text="Hello World!!  Adafruit QT Py RP2040 + NeoPixel BFF  ", font=font)
```

The code begins by instantiating the `label` text object and the `pixels` NeoPixel object. In the loop, the text scrolls continuously across the grid. The text is scrolled by moving the `y` coordinate of the text by `1`.

## Fancy Scrolling Text Example
https://github.com/adafruit/Adafruit_Learning_System_Guides/blob/main/5x5_NeoPixel_BFF_Examples/CircuitPython_Store_Demo/code.py

Once everything is saved to the&nbsp; **CIRCUITPY** &nbsp;drive, you'll see your 5x5 NeoPixel grid scroll a heart shape followed by the text "adafruit!".

![](https://cdn-learn.adafruit.com/assets/assets/000/116/796/medium800thumb/adafruit_products_5646-05.jpg?1669642311)

The code begins by adjusting the `tom-thumb` font file with `PatchedFont`. The "`i`" and "`!`" characters and space are made narrower is so it looks a little better.

Then, the text and heart sprite shape are instantiated, followed by the `pixels` NeoPixel object.

In the loop, the heart sprite cycles through a `colorwheel` rainbow color cycle and then the text scrolls on the grid. The text is scrolled by moving the `y` coordinate of the text by `1`.

# Adafruit 5x5 NeoPixel Grid BFF

## Python Docs

# Adafruit 5x5 NeoPixel Grid BFF

## Arduino

Using the 5x5 NeoPixel Grid BFF with Arduino involves plugging the breakout into your Arduino-compatible QT Py or Xiao form factor board, installing the [Adafruit-GFX-Library](https://github.com/adafruit/Adafruit-GFX-Library), [Adafruit\_NeoPixel](https://github.com/adafruit/Adafruit_NeoPixel) and [Adafruit\_NeoMatrix](https://github.com/adafruit/Adafruit_NeoMatrix) libraries, and running the provided example code.

## Wiring

Plug a 5x5 NeoPixel Grid BFF into your QT Py or Xiao form factor board exactly as shown below. Here's an example of connecting a QT Py RP2040 to the BFF.

Connect the QT Py RP2040 with plug headers into the 5x5 NeoPixel Grid BFF with socket headers. They should be plugged in with the backs of the boards facing each other.

For more information on soldering socket headers,&nbsp;[check out this Learn Guide](https://learn.adafruit.com/how-to-solder-headers/female-headers).

![adafruit_products_edited_P1390316.jpg](https://cdn-learn.adafruit.com/assets/assets/000/116/797/medium640/adafruit_products_edited_P1390316.jpg?1669643066)

[How to Solder Headers Learn Guide](https://learn.adafruit.com/how-to-solder-headers/female-headers)
## Library Installation

You can install the **Adafruit NeoPixel** , **Adafruit NeoMatrix** and **Adafruit GFX** libraries for Arduino using the Library Manager in the Arduino IDE.

![](https://cdn-learn.adafruit.com/assets/assets/000/116/798/medium800/adafruit_products_Arduino_Open_Library_Manager.png?1669643288)

Click the **Manage Libraries ...** menu item, search for **Adafruit NeoPixel** and select the **Adafruit NeoPixel** library:

![](https://cdn-learn.adafruit.com/assets/assets/000/116/799/medium800/adafruit_products_libManage.jpg?1669644031)

Then, search for **Adafruit NeoMatrix** and select the **Adafruit NeoMatrix** library:

![](https://cdn-learn.adafruit.com/assets/assets/000/116/800/medium800/adafruit_products_neomatrixLib.jpg?1669644044)

Finally, search for&nbsp; **Adafruit GFX** ,&nbsp;and select the&nbsp; **Adafruit GFX** &nbsp;library:

![](https://cdn-learn.adafruit.com/assets/assets/000/116/801/medium800/adafruit_products_gfxLib.jpg?1669644056)

If asked about dependencies for any of the libraries, click "Install all".

![](https://cdn-learn.adafruit.com/assets/assets/000/116/802/medium800/adafruit_products_libDepends2.jpg?1669644068)

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/5x5_NeoPixel_BFF_Examples/Arduino_5x5_Scrolling_Text_Demo/Arduino_5x5_Scrolling_Text_Demo.ino

Upload the sketch to your board. You'll see the 5x5 NeoPixel grid scroll the text "HELLO BFF". The text will loop through being red, green and blue.

![](https://cdn-learn.adafruit.com/assets/assets/000/116/803/medium800thumb/adafruit_products_arduinoScrolling_1.jpg?1669646035)

If you'd like to change the text being scrolled, you can edit the `message[]` constant at the top of the code.

```cpp
// Message to display, and a set of colors to cycle through. Because
// the matrix is only 5 pixels tall, characters with descenders (e.g.
// lowercase p or y) are best avoided. There are even smaller fonts
// but these get progressively less legible. ALL CAPS helps!
const char message[] = "HELLO BFF";
```

# Adafruit 5x5 NeoPixel Grid BFF

## Adafruit NeoPixel Library Docs

# Adafruit 5x5 NeoPixel Grid BFF

## Adafruit NeoMatrix Docs

# Adafruit 5x5 NeoPixel Grid BFF

## Adafruit GFX Library Docs

# Adafruit 5x5 NeoPixel Grid BFF

## Downloads

## Files

- [SK6805 NeoPixel datasheet](https://cdn-shop.adafruit.com/product-files/3484/3484_Datasheet.pdf)
- [EagleCAD PCB files on GitHub](https://github.com/adafruit/Adafruit-5x5-NeoPixel-Grid-BFF-PCB)
- [3D models on GitHub](https://github.com/adafruit/Adafruit_CAD_Parts/tree/main/5646%20NeoPixel%20Grid%205x5%20BFF)
- [Fritzing object in the Adafruit Fritzing Library](https://github.com/adafruit/Fritzing-Library/blob/master/parts/Adafruit%205x5%20NeoPixel%20Grid%20BFF.fzpz)

## Schematic and Fab Print
![](https://cdn-learn.adafruit.com/assets/assets/000/116/788/medium800/adafruit_products_schem.png?1669148073)

![](https://cdn-learn.adafruit.com/assets/assets/000/116/849/medium800/adafruit_products_fab.png?1669759825)


## Primary Products

### Adafruit 5x5 NeoPixel Grid BFF Add-On for QT Py and Xiao

[Adafruit 5x5 NeoPixel Grid BFF Add-On for QT Py and Xiao](https://www.adafruit.com/product/5646)
Our QT Py boards are a great way to make very small microcontroller projects that pack a ton of power - and now we have a way for you to quickly add a glittering grid of 25 RGB addressable&nbsp;micro NeoPixels. It's an excellent way to make tiny wearable, cosplay, or IoT projects with...

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

## Featured Products

### 20-pin 0.1" Female Headers - Rainbow Color Mix - 5 pack

[20-pin 0.1" Female Headers - Rainbow Color Mix - 5 pack](https://www.adafruit.com/product/4160)
Female header is like the duct tape of electronics. It's great for connecting things together, soldering to perf-boards, sockets for wires or break-away header, etc. We go through these real fast, and thought that given how handy they are, we'd offer them in a pack of five!

Each...

Out of Stock
[Buy Now](https://www.adafruit.com/product/4160)
[Related Guides to the Product](https://learn.adafruit.com/products/4160/guides)
### Break-away 0.1" 36-pin strip male headers in Various Colors

[Break-away 0.1" 36-pin strip male headers in Various Colors](https://www.adafruit.com/product/4235)
In this world nothing can be said to be certain, except we need headers, headers, and&nbsp;_more headers_!

Each pack contains ten **36-pin&nbsp;0.1" pitch break-away male headers.**

We gave these in bags of 10, in **classic black** as well as...

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

## Related Guides

- [NeoPixel Novelty Cufflinks with Scrolling Text](https://learn.adafruit.com/neopixel-novelty-cufflinks-with-scrolling-text.md)
- [Canary Nightlight ](https://learn.adafruit.com/canary-nightlight.md)
- [NeoPixel Sprite Weather Display](https://learn.adafruit.com/neopixel-sprite-weather-display.md)
- [PiPyPirate Radio](https://learn.adafruit.com/pipypirate-radio.md)
- [Adafruit BME280 Humidity + Barometric Pressure + Temperature Sensor Breakout](https://learn.adafruit.com/adafruit-bme280-humidity-barometric-pressure-temperature-sensor-breakout.md)
- [Adafruit ESP32-S3 TFT Feather](https://learn.adafruit.com/adafruit-esp32-s3-tft-feather.md)
- [Adafruit ENS160 MOX Gas Sensor](https://learn.adafruit.com/adafruit-ens160-mox-gas-sensor.md)
- [CircuitPython Elgato WiFi Light Controller](https://learn.adafruit.com/circuitpython-elgato-wifi-light-controller.md)
- [Busy Box Interruption Sign](https://learn.adafruit.com/busy-box-interruption-sign.md)
- [Adafruit ADG729 Dual 1-to-4 Analog Matrix Switch](https://learn.adafruit.com/adafruit-adg729-dual-1-to-4-analog-matrix-switch.md)
- [LoRa Signal Bridge with the Feather RP2040 RFM ](https://learn.adafruit.com/lora-signal-bridge-with-the-feather-rp2040-rfm.md)
- [Adafruit Motor Shield](https://learn.adafruit.com/adafruit-motor-shield.md)
- [No-Touch Hand Wash Timer for Circuit Playground Express and CLUE](https://learn.adafruit.com/no-touch-hand-wash-timer-for-cpx-and-clue.md)
- [Adafruit VCNL4200 Long Distance IR Proximity and Light Sensor](https://learn.adafruit.com/adafruit-vcnl4200-long-distance-ir-proximity-and-light-sensor.md)
- [RGB Matrix Slot Machine](https://learn.adafruit.com/rgb-matrix-slot-machine.md)
