
A colorful CLUE slideshow purse with Bright Wearables
Created by Anne Barela
Last updated on 2021-02-08 06:57:50 PM EST

2
3
3
5
7
7
9
9
11
11
11
11
14
14
14
15
15
15
16
16
Guide Contents
Guide Contents
Overview
Adafruit Parts
Bags
CircuitPython on CLUE
Set up CircuitPython Quick Start!
CLUE CircuitPython Libraries
Installing CircuitPython Libraries on your CLUE
Code
Libraries
Text Editor
Code and Sample Graphics
Assembly
Place the Bright Board into Your Wearable
Inserting CLUE into the Bright Board
Use
LED Ring Display
Picture Slideshow
Power
Enjoy
© Adafruit Industries https://learn.adafruit.com/a-colorful-clue-slideshow-purse Page 2 of 17

Overview
Wearable electronics clothing and accessories continue to remain very popular with designers and
fashion lovers alike. Adafruit has featured a great number of wearable projects. Many of them have
required sewing skills, electronic skills or both.
Bright Wearables (https://adafru.it/JBM) is a recent company that has designed a board which interfaces
with a BBC micro:bit or Adafruit CLUE board. The Bright Board may be incorporated into one's own
designs or paired with a number of backpack and handbag styles specifically designed to highlight the
multicolored, programmable LEDs and the board's display.
This project pairs a Bright Wearables crossbody bag and Bright Board with the Adafruit CLLE to provide a
colorful, changeable picture display surrounded by lights. It would look great shopping, socializing or for
nightlife.
Adafruit Parts
Your browser does not support the video tag.
Adafruit CLUE - nRF52840 Express with Bluetooth LE
Do you feel like you just don't have a CLUE? Well, we can help with that - get a CLUE here at Adafruit by
picking up this sensor-packed development board. We wanted to build some...
$39.95
In Stock
Add to Cart
© Adafruit Industries https://learn.adafruit.com/a-colorful-clue-slideshow-purse Page 3 of 17

USB cable - USB A to Micro-B
This here is your standard A to micro-B USB cable, for USB 1.1 or 2.0. Perfect for connecting a PC to your
Metro, Feather, Raspberry Pi or other dev-board or...
$2.95
In Stock
Add to Cart
© Adafruit Industries https://learn.adafruit.com/a-colorful-clue-slideshow-purse Page 4 of 17

Alkaline AA batteries (LR6) - 3 pack
Battery power for your portable project! These batteries are good quality at a good price, and work
fantastic with any of the kits or projects in the shop that use AAs. This is a pack...
$2.25
In Stock
Bags
1 x Bright Wearables Bright Board
Main LED board with power
1 x Bright Wearables Grace Bag
Comes in three colors, Bright Board not included
1 x Bright Wearables Grace Bundle
The Grace purse and the Bright Board (no micro:bit included)
This project uses the Bright Board (https://adafru.it/JBN) by BrightWearables.com. The board works with
both the BBC micro:bit and Adafruit CLUE. It contains 12 nice RGB DotStar LEDs in a circle, an on/off
switch and a battery pack.
You can place the Bright Board into your own purse or wearable with the knowledge that all the
electronics are safe from jostling (no finicky metallic thread like in some projects).
Bright Wearables sells purses and backpacks (https://adafru.it/JBO) specifically made to have the Bright
Board snap in. This project uses the Grace crossbody phone bag (https://adafru.it/JBP) (which comes in
three colors). All the bags allow the LEDs and the micro:bit/CLUE display to show through the bag.
The bags and the Bright Board may be purchased as a bundle. For this project, selecting a bundle with the
Add to Cart
Buy Now
Buy Now
Buy Now
© Adafruit Industries https://learn.adafruit.com/a-colorful-clue-slideshow-purse Page 5 of 17

bag of your choice + the Bright Board without the micro:bit board may be what you want.
Other products on BrightWearables.com (https://adafru.it/JBO)
© Adafruit Industries https://learn.adafruit.com/a-colorful-clue-slideshow-purse Page 6 of 17

CircuitPython on CLUE
CircuitPython (https://adafru.it/tB7) is a derivative of MicroPython (https://adafru.it/BeZ) designed to
simplify experimentation and education on low-cost microcontrollers. It makes it easier than ever to get
prototyping by requiring no upfront desktop software downloads. Simply copy and edit files on the
CIRCUITPY flash drive to iterate.
The following instructions will show you how to install CircuitPython. If you've already installed
CircuitPython but are looking to update it or reinstall it, the same steps work for that as well!
Set up CircuitPython Quick Start!
Follow this quick step-by-step for super-fast Python power :)
https://adafru.it/IHF
Click the link above to download the latest version of
CircuitPython for the CLUE.
Download and save it to your desktop (or wherever is handy).
Plug your CLUE into your computer using a known-good USB
cable.
A lot of people end up using charge-only USB cables and it
is very frustrating! So make sure you have a USB cable you
know is good for data sync.
Double-click the Reset button on the top (magenta arrow) on
your board, and you will see the NeoPixel RGB LED (green
arrow) turn green. If it turns red, check the USB cable, try
another USB port, etc. Note: The little red LED next to the
USB connector will pulse red. That's ok!
If double-clicking doesn't work the first time, try again.
Sometimes it can take a few tries to get the rhythm right!
https://adafru.it/IHF
© Adafruit Industries https://learn.adafruit.com/a-colorful-clue-slideshow-purse Page 7 of 17

You will see a new disk drive appear called CLUEBOOT.
Drag the adafruit-circuitpython-clue-etc.uf2 file to
CLUEBOOT.
The LED will flash. Then, the CLUEBOOT drive will disappear
and a new disk drive called CIRCUITPY will appear.
If this is the first time you're installing CircuitPython or you're
doing a completely fresh install after erasing the filesystem,
you will have two files - boot_out.txt, and code.py, and one
folder - lib on your CIRCUITPY drive.
If CircuitPython was already installed, the files present before
reloading CircuitPython should still be present on your
CIRCUITPY drive. Loading CircuitPython will not create new
files if there was already a CircuitPython filesystem present.
That's it, you're done! :)
© Adafruit Industries https://learn.adafruit.com/a-colorful-clue-slideshow-purse Page 8 of 17

CLUE CircuitPython Libraries
The CLUE is packed full of features like a display and a ton of sensors. Now that you have CircuitPython
installed on your CLUE, you'll need to install a base set of CircuitPython libraries to use the features of the
board with CircuitPython.
Follow these steps to get the necessary libraries installed.
Installing CircuitPython Libraries on your CLUE
If you do not already have a lib folder on your CIRCUITPY drive, create one now.
Then, download the CircuitPython library bundle that matches your version of CircuitPython from
CircuitPython.org.
https://adafru.it/ENC
The bundle downloads as a .zip file. Extract the file. Open the
resulting folder.
Open the lib folder found within.
https://adafru.it/ENC
© Adafruit Industries https://learn.adafruit.com/a-colorful-clue-slideshow-purse Page 9 of 17

Once inside, you'll find a lengthy list of folders and .mpy files.
To install a CircuitPython library, you drag the file or folder
from the bundle lib folder to the lib folder on your
CIRCUITPY drive.
Copy the following folders and files from the bundle lib folder
to the lib folder on your CIRCUITPY drive:
adafruit_apds9960
adafruit_bmp280.mpy
adafruit_bus_device
adafruit_clue.mpy
adafruit_display_shapes
adafruit_display_text
adafruit_lis3mdl.mpy
adafruit_lsm6ds
adafruit_register
adafruit_sht31d.mpy
adafruit_slideshow.mpy
neopixel.mpy
Your lib folder should look like the image on the left. These
libraries will let you run the demos in the CLUE guide.
© Adafruit Industries https://learn.adafruit.com/a-colorful-clue-slideshow-purse Page 10 of 17

Code
Libraries
Once your CLUE is set up with CircuitPython and library files in general, we'll add some project specific
libraries.
From the library bundle you downloaded in that guide page, transfer any additional libraries shown here
onto the CLUE's /lib directory on the CIRCUITPY drive:
adafruit_apds9960
adafruit_bus_device
adafruit_bmp280
adafruit_clue.py
adafruit_dotstar.mpy
adafruit_fancyled
adafruit_imageload
adafruit_lis3mdl.mpy
adafruit_lsm6ds.mpy
adafruit_register
adafruit_sht31d.mpy
adafruit_slideshow.mpy
neopixel.mpy
Text Editor
Adafruit recommends using the Mu editor for using your CircuitPython code with the CLUE boards. You
can get more info in this guide (https://adafru.it/Jzc).
Alternatively, you can use any text editor that saves files.
Code and Sample Graphics
Use the Download: Project Zip link in the code window below to download the code and sample graphics
files for this project. Unzip the files into a directory.
© Adafruit Industries https://learn.adafruit.com/a-colorful-clue-slideshow-purse Page 11 of 17

# Bright Wearables Purse Slideshow with FancyLED
# Anne Barela for Adafruit Industries, February 2020
# MIT License
import board
import adafruit_dotstar as dotstar
from adafruit_clue import clue
from adafruit_slideshow import SlideShow, PlayBackDirection
import adafruit_fancyled.adafruit_fancyled as fancy
# Set the LED ring speed and brightness
LED_SPEED = 0.2 # pick a number from 0 (no motion) to 1.0 (fastest!)
BRIGHTNESS = 0.2 # pick a number from 0 (dark) to 1.0 (bright!)
# colors available are RED, YELLOW, ORANGE, GREEN, TEAL
# CYAN, BLUE, PURPLE, MAGENTA, WHITE, BLACK, GOLD, PINK
# AQUA, JADE, AMBER, VIOLET, SKY - pick any color set!
# 3 to 5 colors looks best...
palette = [clue.PINK, clue.GOLD, clue.JADE]
# For the Bright Wearables DotStar LED Ring
num_leds = 12
pixels = dotstar.DotStar(board.P13, board.P15, num_leds, auto_write=False)
offset = 0
# Create the BMP displayer
slideshow = SlideShow(clue.display, None, folder="/",
auto_advance=False)
# turn palette to fancytype
for i, color in enumerate(palette):
palette[i] = fancy.CRGB(*[x / 255 for x in color])
while True:
if clue.button_b:
slideshow.direction = PlayBackDirection.FORWARD
slideshow.advance()
if clue.button_a:
slideshow.direction = PlayBackDirection.BACKWARD
slideshow.advance()
# spin the LEDs
for i in range(num_leds):
# Load each pixel's color from the palette using an offset, run it
# through the gamma function, pack RGB value and assign to pixel.
color = fancy.palette_lookup(palette, offset + i / num_leds)
color = fancy.gamma_adjust(color, brightness=BRIGHTNESS)
pixels[i] = color.pack()
pixels.show()
offset += LED_SPEED / 10
Plug your CLUE into your computer via a known good USB cable. In your operating system's file
explorer/finder, you should see a new flash drive named CIRCUITPY. Copy the code.py file and the three
sample bmp files to the CLUE CIRCUITPY drive main (root) folder.
The files on your CLUE should be similar to the directory tree listed on this page. The first three files may
not show up on a mac, they tell OSX to not put system files on the CLUE CIRCUITPY drive which might fill
it up.
© Adafruit Industries https://learn.adafruit.com/a-colorful-clue-slideshow-purse Page 12 of 17

© Adafruit Industries https://learn.adafruit.com/a-colorful-clue-slideshow-purse Page 13 of 17

Assembly
Place the Bright Board into Your Wearable
Follow the instructions on brightwearables.com (https://adafru.it/JBR) on assembly of the Bright Board with
your wearable. This includes:
Installing batteries in the battery case
Plugging in the battery connector into the bottom of the Bright Board
Inserting the Bright Board into your purse/backpack
Securing the Bright Board with the built-in snaps.
Inserting CLUE into the Bright Board
Insert the CLUE into the slot in the Bright Board, so the CLUE display is facing the transparent window in
the wearable (facing out) and the electronics laden side of CLUE faces in towards the bag. Please double
check, as the CLUE can be inserted the other way around and that's not going to work. Also be sure the
CLUE board is pressed firmly on both sides into the Bright Board slot so all the connections are made.
© Adafruit Industries https://learn.adafruit.com/a-colorful-clue-slideshow-purse Page 14 of 17

Use
The Bright Board has a handy on/off switch on the board. When switched on, the screen should show
some brief boot information before displaying the first picture on screen and making the DotStar LEDs
light up.
LED Ring Display
The DotStars cycle through three colors selected in the code. Up to five may be selected to look best:
# colors available are RED, YELLOW, ORANGE, GREEN, TEAL
# CYAN, BLUE, PURPLE, MAGENTA, WHITE, BLACK, GOLD, PINK
# AQUA, JADE, AMBER, VIOLET, SKY - pick any color set!
# 3 to 5 colors looks best...
palette = [clue.PINK, clue.GOLD, clue.JADE]
You may use Mu or a text editor to change the colors you like. The pictures you select and the color of the
bag may guide your choice as to colors.
The colors will cycle through those chosen. Kind of an "Ambilight" type effect but the lights are not
dependent on the picture chosen.
Picture Slideshow
The code will display the first bitmap it sees in the root directory of the CIRCUITPY drive. You may have
as many pictures as you like, up to the capacity of the CIRCUITPY drive. All pictures should be 240 x 240
pixels square and saved in bitmap (BMP) format with a .bmp file extension.
The three sample bitmap files are in the GitHub repo (https://adafru.it/JBS) and if you selected Download:
Project Zip on the code page, the three files are in the zip file (or get them in the link in the line above).
To change the displayed image, you use the CLUE A and B buttons: B on the right side of the display
advances to the next image, A on the left of the display goes back to the previous image. The buttons are
not visible on the outside of the purse, but are easily pressed through the material. Only you will know the
magic.
© Adafruit Industries https://learn.adafruit.com/a-colorful-clue-slideshow-purse Page 15 of 17

Power
The Bright Board has a convenient slide switch on it for power (circled in blue below). To turn on the
lights, slide the switch on and turn it off to conserve power. If you decide to remove your CLUE board
from the Bright Wearables board, please be sure to turn the power off to protect the electronics.
Enjoy
Enjoy your colorful wearable!
© Adafruit Industries https://learn.adafruit.com/a-colorful-clue-slideshow-purse Page 16 of 17

© Adafruit Industries Last Updated: 2021-02-08 06:57:50 PM EST Page 17 of 17