Jewel Hair Stick. Created by Leslie Birch. Last updated on :47:17 PM UTC

Similar documents
NeoPixel Punk Collar. Created by Becky Stern. Last updated on :41:18 PM UTC

Cyberpunk Spikes. Created by Becky Stern. Last updated on :07:06 PM UTC

Light-Up Angler Fish Embroidery

NeoPixel Ring Bangle Bracelet

Interior Purse Light. Created by Becky Stern. Last updated on :41:08 PM UTC

Celebration Spectacles

Mystical LED Halloween Hood

NeoPixel LED Cortana Costume

Adafruit LED Sequins. Created by Becky Stern. Last updated on :02:00 AM UTC

FLORA Pixel Brooch. Created by Becky Stern. Last updated on :19:07 PM EST

ISS Pin. Created by Leslie Birch. Last updated on :27:30 PM UTC

3D Printed Camera LED Ring

Guardian Shield+ Zelda Breath of the Wild

NeoPixel Basketball Hoop

Clockwork Goggles. Created by John Park. Last updated on :03:10 PM UTC

Sewable NeoPixels. Created by Becky Stern. Last updated on :50:14 PM EDT

FLORA TV-B-Gone. Created by Becky Stern. Last updated on :32:57 PM UTC

Adafruit TPL5110 Power Timer Breakout

Sparkle Skirt. Created by Becky Stern. Last updated on :48:58 PM UTC

NeoPixel Manicure. Created by Sophy Wong. Last updated on :50:38 PM UTC

Getting Started with FLORA

Adafruit TPL5111 Reset Enable Timer Breakout

Crystal Glow Knuckles

Bunny Ears with MakeCode

Adabot Operation Game

Portable Apple Watch Charger

FLORA and GEMMA ICSP. Created by Becky Stern. Last updated on :42:16 PM UTC

Pushrod Garage. Created by John Park. Last updated on :07:30 PM UTC

Camera LED Ring Light

Infinity Mirror Valentine's Candy Box

Chirping Plush Owl Toy

Kaleidoscope Eyes (Trinket-Powered NeoPixel LED Ring Goggles)

Lie Ren's Stormflower Gun Blade

3D Printed Daft Punk Helmet with Bluetooth

Getting Started with FLORA

Feather Weather Lamp. Created by Ruiz Brothers. Last updated on :54:26 PM UTC

Tent Lantern. Created by Timothy Reese. Last updated on :17:25 AM UTC

Trinket NeoPixel LED Longboard

NeoMatrix 8x8 Word Clock

FLORA and GEMMA ICSP. Created by Becky Stern. Last updated on :30:55 PM EST

Bluetooth Controlled NeoPixel Headphones

Solar Boost Bag. Created by Becky Stern. Last updated on :44:55 PM UTC

LED Breath Stats Mask

Adafruit LED Sequins. Created by Becky Stern. Last updated on :00:06 PM EST

Bike Wheel POV Display

NeoPixie Dust Bag with Circuit Playground Express

Crawling Animatronic Hand

Con Badge with Circuit Playground Express

Simple LED Unicorn Horn

Slider Crank Mechanism -- from Cardboard and Craft Sticks

Adafruit Capacitive Touch Sensor Breakouts

i2c/spi LCD Backpack Created by lady ada Last updated on :11:04 PM UTC

Trinket-Powered Conference Room Occupancy Display

Snake Charmer Box. Created by Dano Wall. Last updated on :07:25 PM UTC

Neon LED Signs. Created by John Park. Last updated on :11:09 PM UTC

LED Stego Flex Spike Hoodie

LED Eyes. Created by Ruiz Brothers. Last updated on :50:55 AM UTC

Circuit Playground Express Head-Tilt Ears

Magical Mistletoe. Created by Leslie Birch. Last updated on :45:29 PM UTC

Ping Pong Ball Launcher

Adafruit MCP9808 Precision I2C Temperature Sensor Guide

3D Printed LED Buckle

Paper Airplane Launcher

Crawling Baby Sea Turtle Robot

GPS Logging Dog Harness

Stumble-Bot. Created by Dano Wall. Last updated on :04:06 AM UTC

Crickit Dancing Marionette Kit Created by Dano Wall. Last updated on :03:11 PM UTC

Interactive Gift Box. Created by codingpro. Last updated on :47:40 AM UTC

Easy Sparkle Pocket T-Shirt

Alohamora Bottle. Created by Erin St Blaine. Last updated on :58:53 PM UTC

NeoPixel Bike Light. Created by Ruiz Brothers. Last updated on :43:46 PM UTC

PyPortal NeoPixel Color Picker Created by Kattni Rembor. Last updated on :42:41 PM UTC

'Sup Brows. Created by Kate Hartman. Last updated on :52:04 PM UTC

Android GBoard Morse Code Control with Circuit Playground Express

Adafruit VL53L0X Time of Flight Micro-LIDAR Distance Sensor Breakout

Adafruit 1.27" and 1.5" Color OLED Breakout Board

Trellis 3D Printed Enclosure

Adafruit Mini TFT " 160x80

Hammer Time Mini Golf Hazard with Crickit

No-Sew LED Wristband. Created by Kathy Ceceri. Last updated on :23:40 PM UTC

Adafruit APDS9960 breakout

Monochrome OLED Breakouts

Wind Blowing Emoji Prop

Adafruit Si7021 Temperature + Humidity Sensor

MCP Bit DAC Tutorial

Adafruit Color Sensors

Flora Brake Light Backpack

7 Portable Multitouch Raspberry Pi Tablet

FPV Mini Display. Created by Ruiz Brothers. Last updated on :00:18 PM UTC

Reindeer Mask with Animated Eyes

Crickit Powered Holiday Diorama

Bandolier of Light. Created by Becky Stern. Last updated on :16:17 PM EST

MCP Bit DAC Tutorial

Crickit Carnival Bumper Bot

Luminous LED Flowers. Created by Becky Stern. Last updated on :47:44 PM UTC

Circuit Playground Yoyo

Prophet 600 GliGli mod

Fiddy - the FTDI Clip

Joy Featherwing. Created by Dean Miller. Last updated on :03:07 PM UTC

Adafruit AS channel Visible Light Sensor

Transcription:

Jewel Hair Stick Created by Leslie Birch Last updated on 2018-08-22 03:47:17 PM UTC

Guide Contents Guide Contents Overview Tools & Supplies Prepare Chopstick Circuit Diagram Solder Circuit Arduino Code CircuitPython Code Prepare Ornament Finishing Touches Wear it! 2 3 4 6 8 9 11 14 17 20 23 Adafruit Industries https://learn.adafruit.com/jewel-hair-stick Page 2 of 23

Overview This Japanese style hair ornament combines an upcycled chopstick with felt, embroidery, beads and a GEMMA M0 (https://adafru.it/ytb) or GEMMA v2 (https://adafru.it/dub) microcontroller. A NeoPixel Jewel provides the real beauty with kaleidoscopic flower designs. Make a hair stick for every season of the year and you'll be the tea ceremony favorite. Don't have long hair? No worries, just eliminate the chopstick and glue/stitch a barrette on the back of your ornament. This guide was written for the Gemma v2 board, but can be done with either the original or Gemma M0. We recommend the Gemma M0 as it is easier to use and is more compatible with modern computers! Adafruit Industries https://learn.adafruit.com/jewel-hair-stick Page 3 of 23

Tools & Supplies This guide was written for the Gemma v2 board, but can be done with either the original or Gemma M0. We recommend the Gemma M0 as it is easier to use and is more compatible with modern computers! What would an electric kanzashi look like? That was the question I was considering when I designed this piece. The simple circular shapes of the Jewel and GEMMA brought the answer. You'll be using plenty of crafting skills, with a wee bit of tools for this beginner's project. The hardest part will be choosing the colors you want for your ornament. The GEMMA M0 (http://adafru.it/1222)is recommended over the GEMMA v2 (https://adafru.it/dub). Either will work. NeoPixel Jewel (http://adafru.it/2226) LiPoly Battery 100mAh (https://adafru.it/daq) A Micro Lipo or other small lipoly battery charger at 100mAh rate (http://adafru.it/1304) Silicone Wire in fave color (http://adafru.it/1970) (at least 1 ft.) - You can try using conductive thread but we prefer silicone wire for stronger connections! USB Cable A/Micro B (http://adafru.it/2008) Needlenose Pliers (http://adafru.it/146) Felt Scrap (6"x6") Jewelry Findings - 2" Head Pins (3)/Eye Pins (1) Jewelry Findings - Jump Ring (1) Crystal Beads - 4 mm (1 pack) Silver Beads - 6 mm (1 pack) Embroidery Floss (1) or scrap piece 24" Embroidery Needle Chopstick Sandpaper Adafruit Industries https://learn.adafruit.com/jewel-hair-stick Page 4 of 23

Hobby knife or small saw Gloss Acrylic Paint (1) Clear Nail Polish Small Paint Brush Scrap cardboard (3"x3") Hot glue gun Make sure you take the time to read the following guides. Jewel is a type of NeoPixel cluster and operates similarly to the other NeoPixel products. Introducing Gemma M0 (https://adafru.it/yeq) or Introducing GEMMA (https://adafru.it/dgh) NeoPixel Uber Guide (https://adafru.it/dhw) Adafruit Guide to Excellent Soldering (https://adafru.it/dri) Adafruit Industries https://learn.adafruit.com/jewel-hair-stick Page 5 of 23

Prepare Chopstick Take your chopstick and measure 6" starting at the tiny tip and mark a line. Then, cut using a hobby knife or saw. Sand the raw edge of the cut until smooth, and also sand the tip of the chopstick so it is a nice point. Now, give the entire chopstick a light sanding, as this will make the stick slide through the hair easier and also produce a better paint job. Apply three coats of acrylic paint to the entire chopstick, allowing correct drying time between coats. It's helpful to clamp a clothespin on the thicker end and stand the pin up so the chopstick is positioned at the top, with its point on the table. Adafruit Industries https://learn.adafruit.com/jewel-hair-stick Page 6 of 23

If you are ambitious, start soldering your circuit, but don't forget to come back here to finish the chopstick. For the final touch, add 2 coats of clear nail polish to give a lacquered appearance. Adafruit Industries https://learn.adafruit.com/jewel-hair-stick Page 7 of 23

Circuit Diagram https://adafru.it/zcm https://adafru.it/zcm This diagram uses the original Gemma but you can also use the Gemma M0 with the exact same wiring! Okay, get set -- all soldering will be done on the back side of the GEMMA and Jewel. Notice I've used the same color wire for all three connections on my finished piece to coordinate with the felt. Wire can be beautiful! GEMMA --> Jewel D1 --> Data In GND --> GND Vout --> Power Adafruit Industries https://learn.adafruit.com/jewel-hair-stick Page 8 of 23

Solder Circuit Lay your GEMMA and Jewel side by side as in the photo. The wires will be going in the area between the two parts. Trim and strip three pieces of wire--2 at 2 1/4" and 1 at 2 3/4". Tin just the one side of each of the wires. This will be the side that gets inserted into the fat pads of the GEMMA. The other side we will leave without solder, so it is easier to insert into the small pads of the Jewel. Don't forget that you will be inserting your wires into the back side of each of these parts to solder. Now solder wires using the longer wire for the ground connection. GEMMA --> Jewel D1 --> Data In GND --> GND Vout --> Power Nip off the excess tips of the wires. Adafruit Industries https://learn.adafruit.com/jewel-hair-stick Page 9 of 23

Adafruit Industries https://learn.adafruit.com/jewel-hair-stick Page 10 of 23

Arduino Code Usually you wait until the end of the project to do the programming. In this case, this is the best way to make sure your parts are working before you glue them down. Connect your GEMMA to your computer with the cable and upload the following code. Notice the section with the colors--you can hack that to be any combination you like. I found that deeper colors work better than lighter ones, but it can be fun to have a subtle mix. The Arduino code presented below works equally well on all versions of GEMMA: v1, v2 and M0. But if you have an M0 board, consider using the CircuitPython code on the next page of this guide, no Arduino IDE required! https://adafru.it/cdj https://adafru.it/cdj /* Jewel Hairstick by Leslie Birch for Adafruit Industries Based on NeoPixel Library by Adafruit */ // This section is NeoPixel Variables #include <Adafruit_NeoPixel.h> #define PIN 1 // Parameter 1 = number of pixels in strip // Parameter 2 = pin number (most are valid) // Parameter 3 = pixel type flags, add together as needed: // NEO_KHZ800 800 KHz bitstream (most NeoPixel products w/ws2812 LEDs) // NEO_KHZ400 400 KHz (classic 'v1' (not v2) FLORA pixels, WS2811 drivers) // NEO_GRB Pixels are wired for GRB bitstream (most NeoPixel products) // NEO_RGB Pixels are wired for RGB bitstream (v1 FLORA pixels, not v2) Adafruit_NeoPixel strip = Adafruit_NeoPixel(7, 1, NEO_GRB + NEO_KHZ800); //You can have fun here changing the colors for the code uint32_t color1 = strip.color(236, 79, 100); //Salmon Pink uint32_t color2 = strip.color(246, 216, 180); //Cream uint32_t color3 = strip.color(174, 113, 208); //Lavendar uint32_t color4 = strip.color(182, 31, 40); //Red uint32_t color5 = strip.color(91, 44, 86); //Purple void setup() { //This is for Neopixel Setup strip.begin(); strip.show(); // Initialize all pixels to 'off' } void loop() { strip.setbrightness(30); // the first number is the pixel number for Jewel. O is the center one Adafruit Industries https://learn.adafruit.com/jewel-hair-stick Page 11 of 23

// the first number is the pixel number for Jewel. O is the center one strip.setpixelcolor(1, color1); strip.setpixelcolor(2, color1); strip.setpixelcolor(3, color1); strip.setpixelcolor(4, color1); strip.setpixelcolor(5, color1); strip.setpixelcolor(6, color1); strip.setpixelcolor(0, color2); strip.show(); delay(3000); strip.setpixelcolor(1, color2); strip.setpixelcolor(2, color2); strip.setpixelcolor(3, color2); strip.setpixelcolor(4, color2); strip.setpixelcolor(5, color2); strip.setpixelcolor(6, color2); strip.setpixelcolor(0, color3); strip.show(); delay(3000); strip.setpixelcolor(1, color3); strip.setpixelcolor(2, color3); strip.setpixelcolor(3, color3); strip.setpixelcolor(4, color3); strip.setpixelcolor(5, color3); strip.setpixelcolor(6, color3); strip.setpixelcolor(0, color4); strip.show(); delay(3000); strip.setpixelcolor(1, color4); strip.setpixelcolor(2, color4); strip.setpixelcolor(3, color4); strip.setpixelcolor(4, color4); strip.setpixelcolor(5, color4); strip.setpixelcolor(6, color4); strip.setpixelcolor(0, color5); strip.show(); delay(3000); strip.setpixelcolor(1, color5); strip.setpixelcolor(2, color5); strip.setpixelcolor(3, color5); strip.setpixelcolor(4, color5); strip.setpixelcolor(5, color5); strip.setpixelcolor(6, color5); strip.setpixelcolor(0, color1); strip.show(); delay(3000); } Adafruit Industries https://learn.adafruit.com/jewel-hair-stick Page 12 of 23

Installing Arduino libraries is a frequent stumbling block. If this is your first time, or simply needing a refresher, please read the All About Arduino Libraries (https://adafru.it/aym) tutorial. (https://adafru.it/zax)if the library is correctly installed (and the Arduino IDE is restarted), you should be able to navigate through the File rollover menus as follows: File Sketchbook Libraries Adafruit_NeoPixel strandtest Connect up your NeoPixels in a solderless breadboard and use alligator clips to attach to GEMMA, referring to the circuit diagram if necessary. You ll need to change a few lines in the code regarding the data pin (1), type of pixels (RGB vs GRB), and number of pixels (5). The resulting (and slightly simplified) code is below: From the Tools Board menu, select the device you are using: Adafruit Gemma M0 Adafruit Gemma 8 MHz Connect the USB cable between the computer and your device. The original Gemma (8 MHz) need the reset button pressed on the board, then click the upload button (right arrow icon) in the Arduino IDE. You do not need to press the reset on the newer Gemma M0 or Trinket M0. When the battery is connected, you should get a light show from the LEDs. All your pixels working? Great! You can take apart this prototype and get ready to put the pixels in the collar. Refer to the NeoPixel Uberguide (https://adafru.it/dhw) for more info. Adafruit Industries https://learn.adafruit.com/jewel-hair-stick Page 13 of 23

CircuitPython Code GEMMA M0 boards can run CircuitPython a different approach to programming compared to Arduino sketches. In fact, CircuitPython comes factory pre-loaded on GEMMA M0. If you ve overwritten it with an Arduino sketch, or just want to learn the basics of setting up and using CircuitPython, this is explained in the Adafruit GEMMA M0 guide (https://adafru.it/z1b). These directions are specific to the M0 GEMMA board. The original GEMMA with an 8-bit AVR microcontroller doesn t run CircuitPython for those boards, use the Arduino sketch on the Arduino code page of this guide. Below is CircuitPython code that works similarly (though not exactly the same) as the Arduino sketch shown on a prior page. To use this, plug the GEMMA M0 into USB it should show up on your computer as a small flash drive then edit the file main.py with your text editor of choice. Select and copy the code below and paste it into that file, entirely replacing its contents (don t mix it in with lingering bits of old code). When you save the file, the code should start running almost immediately (if not, see notes at the bottom of this page). If GEMMA M0 doesn t show up as a drive, follow the GEMMA M0 guide link above to prepare the board for CircuitPython. # Jewel Hairstick by Leslie Birch for Adafruit Industries # Based on NeoPixel Library by Adafruit import time import board import neopixel from digitalio import DigitalInOut, Direction pixpin = board.d1 numpix = 7 Adafruit Industries https://learn.adafruit.com/jewel-hair-stick Page 14 of 23

led = DigitalInOut(board.D13) led.direction = Direction.OUTPUT # defaults to RGB GRB Neopixels strip = neopixel.neopixel(pixpin, numpix, brightness=.1, auto_write=true) # uncomment the following two lines for RGBW Neopixels # strip = neopixel.neopixel( # pixpin, numpix, bpp=4, brightness=.3, auto_write=true) # You can have fun here changing the colors for the code color1 = (236, 79, 100) # Salmon Pink color2 = (246, 216, 180) # Cream color3 = (174, 113, 208) # Lavendar color4 = (182, 31, 40) # Red color5 = (91, 44, 86) # Purple while True: # the first number is the pixel number for Jewel. O is the center one strip[1] = color1 strip[2] = color1 strip[3] = color1 strip[4] = color1 strip[5] = color1 strip[6] = color1 strip[0] = color2 time.sleep(3) strip[1] = color2 strip[2] = color2 strip[3] = color2 strip[4] = color2 strip[5] = color2 strip[6] = color2 strip[0] = color3 time.sleep(3) strip[1] = color3 strip[2] = color3 strip[3] = color3 strip[4] = color3 strip[5] = color3 strip[6] = color3 strip[0] = color4 time.sleep(3) strip[1] = color4 strip[2] = color4 strip[3] = color4 strip[4] = color4 strip[5] = color4 strip[6] = color4 strip[0] = color5 time.sleep(3) This code requires the neopixel.py library. A factory-fresh board will have this already installed. If you ve just reloaded the board with CircuitPython, create the lib directory and then download neopixel.py from Github (https://adafru.it/yew). Adafruit Industries https://learn.adafruit.com/jewel-hair-stick Page 15 of 23

https://adafru.it/yew https://adafru.it/yew Adafruit Industries https://learn.adafruit.com/jewel-hair-stick Page 16 of 23

Prepare Ornament Get your felt out, as well as a shot glass. Trace the larger side of the shot glass on the felt for a 2" circle. Fold the fabric so you can cut 2 circles at one time. Now take your scrap of cardboard and use the other side of the shot glass to trace a 1 1/2" circle. Cut one of these. Get your chopstick, which should now have its finished gloss. Use your hot glue gun to attach the fat side of the chopstick onto the cardboard. The chopstick should lay just a tad under the center of the cardboard, to allow room for the battery. Adafruit Industries https://learn.adafruit.com/jewel-hair-stick Page 17 of 23

Next, glue one circle of felt to the cardboard. Be sure to spread the glue evenly as this will be a support for the Jewel. Glue the other circle of felt just to the stick, and not the cardboard. This will form the pocket for the battery. Embroidery time! Thread a piece of floss and use a split stitch (https://adafru.it/eqy) through the edges of the felt with the cardboard side facing up. You must stay close to the edge to allow room for the battery. Adafruit Industries https://learn.adafruit.com/jewel-hair-stick Page 18 of 23

When you get close to the 10 o'clock position of the circle, only stitch through the top fabric, creating an opening for the battery. Put your battery inside so you know how wide to leave the opening. Then, finish the rest of the edges going through both layers of fabric, until you get to the stick. There you will only be able to get through one layer. Adafruit Industries https://learn.adafruit.com/jewel-hair-stick Page 19 of 23

Finishing Touches Gather the jewelry pieces. Using a head pin, thread your beads in your preferred pattern. Then, use your pliers to create a circle at the top of the wire. Create three of these units. Select an eye pin, and thread your same pattern. When you are done, attach it to one of the other head pin units you made earlier. This will be the one longer strand of the dangle. Adafruit Industries https://learn.adafruit.com/jewel-hair-stick Page 20 of 23

Using a jump ring, rotate the split ends apart by moving one side towards you. Don't pull the ring apart side to side or you will never regain the circular shape. Thread the three beaded units onto the ring. Then, attach the jump ring to the bottom of the Jewel on the unmarked hole at the bottom. Use the pliers to clamp the jump ring shut. Adafruit Industries https://learn.adafruit.com/jewel-hair-stick Page 21 of 23

Now glue the Jewel onto the cardboard backed felt piece. Then, glue the GEMMA onto the stick/felt side. Concentrate the glue on the top half of the GEMMA where it will adhere nicely to the felt. The rest of the part will sit on the stick. You may want to poke something flat like a spoon handle into the felt pocket to help the GEMMA stick well to the felt and to keep the felt from sticking to the cardboard. Adafruit Industries https://learn.adafruit.com/jewel-hair-stick Page 22 of 23

Wear it! Wrap the top of your battery with a little Gaff or masking tape to help add strain relief to the wires. Then, tuck it into its pocket and plug into GEMMA. Finally, switch GEMMA on and weave the stick into your hair. It's helpful to poke it through a hairband to help keep it from twisting. Practice your bows and have fun sharing your Japanese style! Adafruit Industries Last Updated: 2018-08-22 03:47:12 PM UTC Page 23 of 23