Page 1

Joy Featherwing
Created by Dean Miller
https://learn.adafruit.com/joy-featherwing
Last updated on 2021-11-15 07:02:13 PM EST
©Adafruit Industries Page 1 of 18
Page 2

Table of Contents
Overview
Pinouts
• Power and Reset Pins
• I2C Data Pins
• I2C Addressing
• Optional Interrupt Pin
Assembly
• Prepare the header strip:
• Add the FeatherWing:
• And Solder!
Arduino Wiring & Test
• Adafruit seesaw Library
• Running the Example Code
• FeatherJoyWing library!
Circuit Python Wiring & Test
• Download Adafruit_CircuitPython_seesaw Library
Downloads
• Files
• Schematic
• Dimensions
3
5
5
6
6
7
9
9
10
11
13
13
14
14
15
15
17
17
17
18
©Adafruit Industries Page 2 of 18
Page 3

Overview
Make a game or robotic controller with this Joy-ful FeatherWing.This FeatherWing has
a 2-axis joystick and 5 momentary buttons (4 large and 1 small) so you can turn your
feather board into a tiny game controller. This wing communicates with your host
microcontroller over I2C so it's easy to use and doesn't take up any of your precious
analog or digital pins. There is also an optionalinterrupt pinthat can alert your feather
when a button has been pressed or released to free up processor time for other
tasks.
©Adafruit Industries Page 3 of 18
Page 4

This FeatherWing features Adafruit Seesaw technology - a custom programmed little
helper microcontroller that takes the two analog inputs from the joystick, and 5 button
inputs, and converts it into a pretty I2C interface. This I2C interface means you don't
'lose' any GPIO or analog inputs when using this 'Wing, and it works with any and all
Feathers! You can easily stack this with any other FeatherWing because I2C is a
shared bus. If you have an I2C address conflict, or you want to connect more than
one of these to a Feather, there are two address-select jumpers so you have 4
options of I2C addresses
There's an optional IRQ (interrupt) line that you can use if you'd like the Wing to let
you know when a button has been pressed. Since its optional (and most Feathers are
perfectly happy polling the Wing for data) we left a bunch of solder jumpers so you
can select what pin has the IRQ on it. Or just leave it disconnected!
©Adafruit Industries Page 4 of 18
Page 5

We have an Adafruit Seesaw library for Arduino, Python and CircuitPython so you can
get started with the Joy FeatherWing in a jiffy.
Pinouts
Power and Reset Pins
The power to the Joy Featherwing comes from the host Feather's 3.3V regulator, 3.3V
and ground are both required and are highlighted above
The Feather's Reset pin ends up coming from the left-most circled pin and connects
to the on-board reset button. This is great for resetting when you have the Wing on
top
©Adafruit Industries Page 5 of 18
Page 6

I2C Data Pins
All data and control is done over I2C so it works with any and all Feathers! SDA and
SCL are highlighted above. There are 10K pullups to 3.3V on each.
I2C Addressing
Because multiple featherwings of all kinds can be stacked, the I2C address can be
changed if necessary. The Joy Featherwing's default I2C address is 0x49, but
soldering jumpersA0and/orA1 can change this:
A0 A1 Addr
open open 0x49 (default)
©Adafruit Industries Page 6 of 18
Page 7

closed open 0x4A
open closed 0x4B
closed closed 0x4C
Optional Interrupt Pin
Soldering one of the jumpers for the optional interrupt will connect that pin of your
Feather to the interrupt line on the Joy Featherwing. This will allow your Feather to
know whether a button has been pressed or released without having to read each
button over and over in a loop.
Each Feather has different pin names/numbers so check your mainboard for which
pin you want to use then solder that jumper closed
×
Add Table Row
Text
Image
Formats
<p>5</p>
Remove Column
Text
Image
Formats
<p>6</p>
©Adafruit Industries Page 7 of 18
Page 8

Remove Column
Text
Image
Formats
<p>9</p>
Remove Column
Text
Image
Formats
<p>10</p>
Remove Column
Text
Image
Formats
<p>11</p>
Remove Column
Text
Image
Formats
<p>12</p>
Remove Column
Text
Image
Formats
<p>13</p>
Remove Column
DELETECANCELSAVE
©Adafruit Industries Page 8 of 18
Page 9

Assembly
Prepare the header strip:
Cut the strip to length if necessary. It will
be easier to solder if you insert it into a
breadboard -long pins down
©Adafruit Industries Page 9 of 18
Page 10

Add the FeatherWing:
Place the featherwing over the pins so
that the short pins poke through the two
rows of breakout pads
©Adafruit Industries Page 10 of 18
Page 11

And Solder!
Be sure to solder all pins for reliable
electrical contact.
(For tips on soldering, be sure to check
out ourGuide to Excellent
Soldering(https://adafru.it/aTk)).
Start by soldering the first row of header
©Adafruit Industries Page 11 of 18
Page 12

Now flip around and solder the other row
completely
You're done with the two header strips.
Check your solder joints visually and
continue onto the next steps
©Adafruit Industries Page 12 of 18
Page 13

OK You're done! You can now plug your
FeatherWing into your Feather and get
your JOY on!
Arduino Wiring & Test
Adafruit seesaw Library
To use with the Arduino IDE, you will need to install the Adafruit_seesaw library
(here'sthe Github repository(https://adafru.it/BrV).)
It is available from the Arduino library manager so we recommend using that.
From the IDE open up the library manager...
And type in adafruit seesaw to locate the library. Click Install
©Adafruit Industries Page 13 of 18
Page 14

For more details on how to install Arduino libraries, check out our detailed tutorial!(ht
tps://adafru.it/aYM)
Running the Example Code
The library comes with a Joy Featherwing example to get you started fast. Plug the
Wing into the Feather and connect the Feather to your computer with the USB cable.
Open the Arudino IDE and load File->Examples->Adafruit_seesaw-
>joy_featherwing_example
The example assumes the interrupt pin is connected to pin 5 on the Feather via
the first solder jumper on the far left. If you have not soldered this jumper the
example code will need to be modified.
Click the Upload button and open the Serial Monitor at 115200 baud speed.
When you move the joystick you should see data appear in the formatx,y
When you press a button, a notification should appear in the monitor.
FeatherJoyWing library!
If you'd like an all-in-one library that abstracts some of the FeatherWing for you, check
out Leonid(https://adafru.it/ven)'s FeatherJoyWing library https://github.com/
leonidlezner/FeatherJoyWing(https://adafru.it/Bsi)
©Adafruit Industries Page 14 of 18
Page 15

Circuit Python Wiring & Test
Download Adafruit_CircuitPython_seesaw
Library
To begin reading data from your Joy Featherwing, you will need to download Adafru
it_CircuitPython_seesaw from our github repository.You can do that by visiting
the github repo and manually downloading or, easier, just click this button to
download the zip
CircuitPython SeeSaw library
https://adafru.it/A0u
Extract the zipped folder. And rename thefolder it contains to Adafruit_seesaw.
Plug your CircuitPython device into your computer via the USB cable, and you should
see the CIRCUITPY drive appear.
you should have thelibfolder already on the drive. If you do not have thelib folder, or
you encounter errors due to missing libraries, you can download the latest library
packagehere(https://adafru.it/Bsl).
©Adafruit Industries Page 15 of 18
Page 16

Drag the Adafruit_seesaw folder you just renamed to theCIRCUITPY/lib folder on
your CircuitPython drive. The folder should look like this:
open thecode.py file in the root of theCIRCUITPY drive and copy and paste the
following code:
# SPDX-FileCopyrightText: 2021 ladyada for Adafruit Industries
# SPDX-License-Identifier: MIT
import time
import board
from micropython import const
from adafruit_seesaw.seesaw import Seesaw
BUTTON_RIGHT = const(6)
BUTTON_DOWN = const(7)
BUTTON_LEFT = const(9)
BUTTON_UP = const(10)
BUTTON_SEL = const(14)
button_mask = const(
(1 << BUTTON_RIGHT)
| (1 << BUTTON_DOWN)
| (1 << BUTTON_LEFT)
| (1 << BUTTON_UP)
| (1 << BUTTON_SEL)
)
i2c_bus = board.I2C()
ss = Seesaw(i2c_bus)
ss.pin_mode_bulk(button_mask, ss.INPUT_PULLUP)
last_x = 0
last_y = 0
while True:
x = ss.analog_read(2)
y = ss.analog_read(3)
©Adafruit Industries Page 16 of 18
Page 17

if (abs(x - last_x) > 3) or (abs(y - last_y) > 3):
print(x, y)
last_x = x
last_y = y
buttons = ss.digital_read_bulk(button_mask)
if not buttons & (1 << BUTTON_RIGHT):
print("Button A pressed")
if not buttons & (1 << BUTTON_DOWN):
print("Button B pressed")
if not buttons & (1 << BUTTON_LEFT):
print("Button Y pressed")
if not buttons & (1 << BUTTON_UP):
print("Button x pressed")
if not buttons & (1 << BUTTON_SEL):
print("Button SEL pressed")
time.sleep(0.01)
Plug your Joy Featherwing onto the top of your CircuitPython Feather board.
When you open the REPL you should see output when you press buttons or move the
joystick.
Downloads
Files
Fritzing object in Adafruit Fritzing Library(https://adafru.it/aP3)
•
PCB files (EAGLE format)(https://adafru.it/Bsm)
•
Schematic
click to enlarge
©Adafruit Industries Page 17 of 18
Page 18

Dimensions
in Inches
©Adafruit Industries Page 18 of 18