# LED Campfire

## Introduction

https://youtu.be/lxI8e9OUMds

Summertime means being outdoors, looking at the stars, and spending time&nbsp;with friends and family. Traditionally, a camp fire or backyard fire has been a place to gather and relax after a hard day's hike.

Many campsites don't allow individual fires -- and in my world, it's just not true camping without a campfire. Nothing can replace a real fire, but this surprisingly realistic LED fire comes really close. Guaranteed to confuse and annoy your kids.

This is a great beginner project -- you can keep it really simple and build it in one afternoon, or get more complicated with onboard chargers and fiber optics. Marshmallows not included.

![](https://cdn-learn.adafruit.com/assets/assets/000/033/001/medium800/adafruit_products_campfire_boys.jpg?1466198151)

# Materials

- [Pro Trinket 5v](https://www.adafruit.com/product/2000)&nbsp;microcontroller
- Around 20 [Dotstar LEDs -- the 30/m spacing](https://www.adafruit.com/product/2238)&nbsp;works great
- Driftwood or fire-sized logs
- Deck screws
- Silicone Glue

There are **two** different options for battery power, depending on your preference&nbsp;and budget…

**Wiring option 1 (lower cost):**

- [Male JST Connector](https://www.adafruit.com/products/1769)
- [3-cell AAA battery holder with switch](https://www.adafruit.com/products/727)&nbsp;-or-
- Instead of the 3x AAA holder, you can substitute&nbsp;a rechargeable [Lithium-Polymer battery](https://www.adafruit.com/products/328), but it won’t charge over USB with this configuration — you’ll need a separate [LiPoly charger](https://www.adafruit.com/products/1304)&nbsp;for this.

**Wiring option 2 (allows USB charging):**

- [A&nbsp;rechargeable&nbsp;](https://www.adafruit.com/products/2124)[Lithium Polymer battery](https://www.adafruit.com/products/1578?q=2500mah&)
- [LiPoly Backpack charger](https://www.adafruit.com/products/2124)
- Clicky&nbsp;[on/off switch](https://www.adafruit.com/products/1092)

**Optional: to add fiber optic sparks:**

- 1-2 [Glowbys](http://www.luminence.com/Glowbys-Glowbys.html)&nbsp;in red or orange
- 1-2 100 ohm resistors

You'll also need a good **soldering iron** and some **solder**.

# LED Campfire

## The Code

Though nothing is assembled yet, let’s get the code onto the microcontroller first. Then the project’s ready to test once all the connections are made.

Get out your Pro Trinket and plug it into your computer via the USB port.

### Software Setup

If this is your first time using Pro Trinket, take a look at **[Introducting Pro Trinket](../../../../introducing-pro-trinket/overview)**&nbsp;to get a guided tour. This walks you through installing the software necessary to use this board. Get the starter “ **blink** ” sketch working to confirm that the Arduino IDE is properly set up and speaking to the board.

Once you've got your Pro Trinket&nbsp;up and running with [Arduino](../../../../getting-started-with-flora/download-software), you'll need to install the **FastLED** library…

FastLED is a fast, efficient, easy-to-use Arduino library for programming addressable LED strips and pixels. It has a lot of features to get your animations up and running fast -- and it has a lot of code samples available if you're just learning to code.

**Use the Library Manager in the Arduino IDE to install this (Sketch→Include Library→Manage Libraries…).** Scroll down or use the search field to locate FastLED.

[All about Arduino Libraries](../../../../adafruit-all-about-arduino-libraries-install-use/arduino-libraries)&nbsp;will&nbsp;tell you everything you ever wanted to know about libraries, including more detailed installation instructions.

Once your curiosity is satiated and the FastLED&nbsp;library is installed, copy and paste the code below into your Arduino window.

Go to the&nbsp;Tools menu and select "Pro Trinket 5V USB"&nbsp;from the list of boards. Plug your&nbsp;Pro Trinket&nbsp;into your computer via the onboard USB port. Press the "reset" button on your Pro Trinket and wait for the blinky red light, then click the upload button in Arduino.

This wonderful Fire code was written by Mark Kriegsman, and is one of my favorite LED effects of all time.

```auto
#include <FastLED.h>

#define LED_PIN     10
#define CLOCK_PIN   9
#define COLOR_ORDER BGR  //if your colors look incorrect, change the color order here
#define NUM_LEDS    20

#define BRIGHTNESS  255
#define FRAMES_PER_SECOND 20

CRGB leds[NUM_LEDS];

// Fire2012 with programmable Color Palette
//
// This code is the same fire simulation as the original "Fire2012",
// but each heat cell's temperature is translated to color through a FastLED
// programmable color palette, instead of through the "HeatColor(...)" function.
//
// Four different static color palettes are provided here, plus one dynamic one.
// 
// The three static ones are: 
//   1. the FastLED built-in HeatColors_p -- this is the default, and it looks
//      pretty much exactly like the original Fire2012.
//
//  To use any of the other palettes below, just "uncomment" the corresponding code.
//
//   2. a gradient from black to red to yellow to white, which is
//      visually similar to the HeatColors_p, and helps to illustrate
//      what the 'heat colors' palette is actually doing,
//   3. a similar gradient, but in blue colors rather than red ones,
//      i.e. from black to blue to aqua to white, which results in
//      an "icy blue" fire effect,
//   4. a simplified three-step gradient, from black to red to white, just to show
//      that these gradients need not have four components; two or
//      three are possible, too, even if they don't look quite as nice for fire.
//
// The dynamic palette shows how you can change the basic 'hue' of the
// color palette every time through the loop, producing "rainbow fire".

CRGBPalette16 gPal;

void setup() {
  delay(3000); // sanity delay
  FastLED.addLeds<DOTSTAR, LED_PIN, CLOCK_PIN, COLOR_ORDER>(leds, NUM_LEDS).setCorrection( TypicalLEDStrip );
  FastLED.setBrightness( BRIGHTNESS );

  // This first palette is the basic 'black body radiation' colors,
  // which run from black to red to bright yellow to white.
  //gPal = HeatColors_p;
  
  // These are other ways to set up the color palette for the 'fire'.
  // First, a gradient from black to red to yellow to white -- similar to HeatColors_p
  gPal = CRGBPalette16( CRGB::Black, CRGB::Red, CRGB::Yellow, CRGB::White);
  
  // Second, this palette is like the heat colors, but blue/aqua instead of red/yellow
  //  gPal = CRGBPalette16( CRGB::Black, CRGB::Blue, CRGB::Aqua,  CRGB::White);
  
  // Third, here's a simpler, three-step gradient, from black to red to white
  //   gPal = CRGBPalette16( CRGB::Black, CRGB::Red, CRGB::White);
}

void loop() {
  // Add entropy to random number generator; we use a lot of it.
  random16_add_entropy( random());

  // Fourth, the most sophisticated: this one sets up a new palette every
  // time through the loop, based on a hue that changes every time.
  // The palette is a gradient from black, to a dark color based on the hue,
  // to a light color based on the hue, to white.
  //
  //   static uint8_t hue = 0;
  //   hue++;
  //   CRGB darkcolor  = CHSV(hue,255,192); // pure hue, three-quarters brightness
  //   CRGB lightcolor = CHSV(hue,128,255); // half 'whitened', full brightness
  //   gPal = CRGBPalette16( CRGB::Black, darkcolor, lightcolor, CRGB::White);

  Fire2012WithPalette(); // run simulation frame, using palette colors
  
  FastLED.show(); // display this frame
  FastLED.delay(1000 / FRAMES_PER_SECOND);
}

// Fire2012 by Mark Kriegsman, July 2012
// as part of "Five Elements" shown here: http://youtu.be/knWiGsmgycY
//// 
// This basic one-dimensional 'fire' simulation works roughly as follows:
// There's a underlying array of 'heat' cells, that model the temperature
// at each point along the line.  Every cycle through the simulation, 
// four steps are performed:
//  1) All cells cool down a little bit, losing heat to the air
//  2) The heat from each cell drifts 'up' and diffuses a little
//  3) Sometimes randomly new 'sparks' of heat are added at the bottom
//  4) The heat from each cell is rendered as a color into the leds array
//     The heat-to-color mapping uses a black-body radiation approximation.
//
// Temperature is in arbitrary units from 0 (cold black) to 255 (white hot).
//
// This simulation scales it self a bit depending on NUM_LEDS; it should look
// "OK" on anywhere from 20 to 100 LEDs without too much tweaking. 
//
// I recommend running this simulation at anywhere from 30-100 frames per second,
// meaning an interframe delay of about 10-35 milliseconds.
//
// Looks best on a high-density LED setup (60+ pixels/meter).
//
//
// There are two main parameters you can play with to control the look and
// feel of your fire: COOLING (used in step 1 above), and SPARKING (used
// in step 3 above).
//
// COOLING: How much does the air cool as it rises?
// Less cooling = taller flames.  More cooling = shorter flames.
// Default 55, suggested range 20-100 
#define COOLING  55

// SPARKING: What chance (out of 255) is there that a new spark will be lit?
// Higher chance = more roaring fire.  Lower chance = more flickery fire.
// Default 120, suggested range 50-200.
#define SPARKING 120

void Fire2012WithPalette() {
  // Array of temperature readings at each simulation cell
  static byte heat[NUM_LEDS];

  // Step 1.  Cool down every cell a little
  for( int i = 0; i < NUM_LEDS; i++) {
    heat[i] = qsub8( heat[i],  random8(0, ((COOLING * 10) / NUM_LEDS) + 2));
  }
  
  // Step 2.  Heat from each cell drifts 'up' and diffuses a little
  for( int k= NUM_LEDS - 3; k > 0; k--) {
    heat[k] = (heat[k - 1] + heat[k - 2] + heat[k - 2] ) / 3;
  }
    
  // Step 3.  Randomly ignite new 'sparks' of heat near the bottom
  if( random8() < SPARKING ) {
    int y = random8(7);
    heat[y] = qadd8( heat[y], random8(160,255) );
  }

  // Step 4.  Map from heat cells to LED colors
  for( int j = 0; j < NUM_LEDS; j++) {
    // Scale the heat value from 0-255 down to 0-240
    // for best results with color palettes.
    byte colorindex = scale8( heat[j], 240);
    leds[j] = ColorFromPalette( gPal, colorindex);
  }
}
```

As soon as you get the "Upload Successful" notification in your Arduino window, unplug the Pro Trinket and get ready for some soldering.

# Troubleshooting

If you're getting errors or having trouble uploading the code, here are a couple things to try:

1. Be sure you have “Pro Trinket 5v” selected from the Tools&nbsp;menu.
2. Make sure the FastLED library is installed.
3. Press the "reset" button on the Pro Trinket just **after** &nbsp;you hit the "upload" button in Arduino. When you press reset, the Pro Trinket will go&nbsp;into bootloader mode for only around 8 seconds, so you need to time things just right and upload the code during that window.
4. Try restarting your Arduino IDE.
5. If you're still having trouble, try uploading the "Blink" sketch (File **→** Examples **→** Basics **→** Blink). This should blink the Pro Trinket's onboard LED. If this is working, you know your Arduino IDE and upload sequence are working, and that the problem lies elsewhere (e.g. missing library, or syntax error in the code).

# LED Campfire

## Wiring Diagram

I've included two different diagrams: a simpler option with a AAA battery pack, and a slightly more advanced option with a LiPoly charger and Lithium Polymer battery pack.

**Use Option 1** if you want a safer, versatile campfire that runs off disposable or rechargeable AAA batteries -- easy to find, hard to break, and can be switched out to last all night. Lithium Polymer batteries are great but they do have their dangers and challenges, so if kids will be using this campfire or you plan to let it bounce around in the back of your truck, this is the option for you.

**Use Option 2** if you want to be able to recharge your campfire by plugging it in with a USB charger. &nbsp;If you use a good-sized Lithium Polymer battery, it will&nbsp;last for hours, but you'll need to stop and recharge it when it dies (or, have a spare&nbsp;Lithium Polymer battery which can be changed out). &nbsp;If you do it this way, the fire&nbsp;can also run indefinitely while plugged in, so this is a great longer-term backyard solution.

You don’t need to actually solder any parts together yet, this is just a reference for what’s ahead…

# Option 1
![](https://cdn-learn.adafruit.com/assets/assets/000/033/283/medium800/adafruit_products_campfire_option1.jpg?1466803859)

The JST connector solders to the **back side** &nbsp;of the Pro Trinket so you can plug your battery pack in.

Then the following connections are made between the microcontroller and Dotstar LED strip:

- Dotstar G --\> Pro Trinket G
- Dotstar + --\> Pro Trinket BAT+
- Dotstar C --\> Pro Trinket 9
- Dotstar D --\> Pro Trinket 10

**Make sure you are connected to the “input” end of the LED strip.** Examine the face of the strip and look for the arrows…these indicate the direction of data from “in” to “out” (as in the diagram above).

# Option 2
![](https://cdn-learn.adafruit.com/assets/assets/000/033/284/medium800/adafruit_products_campfire_option2.jpg?1466804299)

The **LiPoly Backpack** is designed to “piggyback” atop the Pro Trinket board. The diagram shows them side-by-side to make the connections clear, but in reality just use a **3-pin header&nbsp;** to stack them.

- LiPoly backpack Bat --\> Pro Trinket Bat
- LiPoly backpack G --\> Pro Trinket G
- LiPoly backpack 5v --\> Pro Trinket Bus

The **on/off switch** connects into the two switch pads on the LiPoly backpack.

Four connections are made between&nbsp;the Pro Trinket and LED strip:

- Dotstar G --\> Pro Trinket G pad on back
- Dotstar + --\> Pro Trinket 5v pad on back
- Dotstar C --\> Pro Trinket 9
- Dotstar D --\> Pro Trinket 10

# LED Campfire

## Prep Dotstars

![](https://cdn-learn.adafruit.com/assets/assets/000/032/921/medium800/adafruit_products_dotstar_connector_out.jpg?1465599696)

Your Dotstar strand&nbsp;should have&nbsp;connectors already soldered on to both the "in" and "out end. The "in" end usually has a female connector and the "out" has a male. _But not always!_ **Use&nbsp;the arrows on the strip for reference** , find the "out" end and cut that connector&nbsp;off, setting&nbsp;it aside for now. Later you'll solder&nbsp;this connector to the Pro Trinket, so you can plug it into the "in" end of your strip.

Cut your strip to length starting at the "in" end…measure 20 LEDs down the strip, then&nbsp;cut&nbsp;carefully through the silicone sheath and then cut the strip betwen solder pads. &nbsp;For a small to medium sized fire, **20 lights is a good length** -- too many more and the battery will quickly drain.

Info: 

Look at your strand before cutting! **Use the arrows for reference** …they point from “in” to “out.” The factory producing Dotstar strips has occasionally made changes between batches, so you shouldn’t assume a certain gender to the end connectors.

To seal the end of the strip and keep moisture and ants out, fill the cut end of the silicone sleeve with some hot glue. &nbsp;You can use a piece of heat shrink to hold it all neatly together.

![](https://cdn-learn.adafruit.com/assets/assets/000/033/285/medium800/adafruit_products_seal-the-ends.jpg?1466805135)

# LED Campfire

## Wiring - Option 1

![](https://cdn-learn.adafruit.com/assets/assets/000/033/286/medium800/adafruit_products_opt1wired.jpg?1466807166)

### The simplest way to hook up your Dotstars! &nbsp;&nbsp;

Get out the male connector you cut from the end of your Dotstars.

Strip about 1/8" of shielding from each wire. &nbsp;With your soldering iron, neatly and delicately "tin" each wire with just a tiny amount of solder. &nbsp;This will keep the wires from getting frayed and fuzzy and make it a little easier to fit them into the Pro Trinket's holes.

![](https://cdn-learn.adafruit.com/assets/assets/000/032/925/medium800/adafruit_products_dotstar_connector_tinned.jpg?1465600669)

Find the 5v and G holes at the end of the Pro Trinket opposite the USB port. &nbsp;Solder the red wire into 5v and the black wire into G.&nbsp;

Then, solder the green wire into hole 10, and the yellow wire into hole 9.

It's a bit of a tight fit, and you may need to reduce the tin solder or trim the wires a bit, but they will&nbsp;fit (so don't give up).

Plug the connector into your Dotstar strip, and a USB cable into your Pro Trinket, and be sure the strand lights up with fiery light! &nbsp;

![](https://cdn-learn.adafruit.com/assets/assets/000/033/287/medium800/adafruit_products_test_strip.jpg?1466807331)

If you're happy powering from a USB battery or wall charger, you're done! &nbsp;[Go build your fire.](../../../../led-campfire/build-the-fire)

If you want to be able to run the fire from a AAA battery pack or LiPoly battery, there's one more step.&nbsp;

![](https://cdn-learn.adafruit.com/assets/assets/000/032/927/medium800/adafruit_products_pro_trinket_with_jst_connector.jpg?1465601349)

Take some solder and tin the two pads on the back of your Pro Trinket, and carefully solder on a male JST connector.

Now you can plug in a battery of your choice. &nbsp;

# If you encounter trouble…

Any time you&nbsp;hit a roadblock&nbsp;with a DotStar&nbsp;project, we’ll usually ask that you start with the “strandtest” example from our own Adafruit\_DotStar&nbsp;library. This helps us narrow down whether it’s a hardware or software issue. The library is installed similarly to FastLED or any other — unzip, rename “Adafruit\_DotStar” and place in your Arduino/Libraries folder, then restart the Arduino IDE. You’ll find the strandtest example under **File→Sketchbook→Libraries→Adafruit\_DotStar→strandtest**

 **If strandtest fails to run, this suggests a hardware issue** …for example, connecting to the wrong Pro Trinket&nbsp;pin.

If you’re new to Arduino programming and LEDs, we usually suggest starting with the Adafruit\_DotStar&nbsp;library…it’s pretty basic, the strip declaration is more conventional, and we can stay on top of keeping it compatible with our own products and the most mainstream Arduino boards.

As FastLED is a more “bleeding edge” third-party library, **we can’t always guarantee compatibility across versions or with specific boards.** You can find help through their **[community on Google+](https://plus.google.com/communities/109127054924227823508)**. This is potent stuff, written by people with a deep appreciation for LED art, and we wanted to showcase it.

# LED Campfire

## Wiring - Option 2

![](https://cdn-learn.adafruit.com/assets/assets/000/032/932/medium800/adafruit_products_wiring_option_2.jpg?1465602364)

### Wiring with Battery Charging Support

This wiring method is slightly more complicated but may&nbsp;make your campfire easier to use and&nbsp;maintain. &nbsp;

We'll add an on/off switch and a&nbsp;LiPoly backpack charger. This means you can&nbsp;recharge your campfire's batteries the same way you'd charge your phone -- by simply plugging it into a USB charger. &nbsp;Hooray! &nbsp;

![](https://cdn-learn.adafruit.com/assets/assets/000/032/930/medium800/adafruit_products_dotstar_connector_tinned.jpg?1465601998)

Just like with option 1, get out the male connector you cut from the end of your Dotstars.

Strip about 1/8" of shielding from each wire. &nbsp;With your soldering iron, neatly and delicately "tin" each wire with just a tiny amount of solder. &nbsp;This will keep the wires from getting frayed and fuzzy and make it a little easier to fit them into the Pro Trinket's holes.

![](https://cdn-learn.adafruit.com/assets/assets/000/032/931/medium800/adafruit_products_pro_trinket_wired.jpg?1465602179)

Solder the green wire into hole 10, and the yellow wire into hole 9.

It's a bit of a tight fit, and you may need to reduce the tin solder or trim the wires a bit, but they will&nbsp;fit (so don't give up).

Then, flip the Pro Trinket over and add some solder to tin the + and - pads on the back (intended for the JST battery connector). &nbsp;Solder the red and black wires firmly onto these pads.

With a utility knife, carefully scratch the copper lead between the two switch pads on the LiPoly backpack.

&nbsp;

Strip a little shielding from each of your switch leads and solder the two wires into these two holes. &nbsp;It doesn't matter which wire goes into which hole.

![adafruit_products_switch_scratch.jpg](https://cdn-learn.adafruit.com/assets/assets/000/032/934/medium640/adafruit_products_switch_scratch.jpg?1465602884)

![adafruit_products_switch_wired.jpg](https://cdn-learn.adafruit.com/assets/assets/000/032/935/medium640/adafruit_products_switch_wired.jpg?1465602981)

On the back of the LiPoly backpack, bridge these two pads with a dot of solder. This allows faster charging with batteries over 500 mAh capacity such as we’re using here.

![adafruit_products_led_strips_19_backpack_bridge.jpg](https://cdn-learn.adafruit.com/assets/assets/000/033/256/medium640/adafruit_products_led_strips_19_backpack_bridge.jpg?1466661597)

Solder the header that came with your LiPoly backpack into the remaining 3 holes from below. &nbsp;The easiest way to do this is using a solderless breadboard to help hold the pins in place.

&nbsp;

Then, place the LiPoly backpack header pins into the Pro Trinket's Bat, G, and Bus holes (line up the G pin on the Pro Trinket with the one on the charger to be sure you've got this right). &nbsp;Solder the headers into place. &nbsp;Trim off any extra header that's sticking up.

![adafruit_products_backpack_header.jpg](https://cdn-learn.adafruit.com/assets/assets/000/032/936/medium640/adafruit_products_backpack_header.jpg?1465603022)

![adafruit_products_backpack_in_place.jpg](https://cdn-learn.adafruit.com/assets/assets/000/032/937/medium640/adafruit_products_backpack_in_place.jpg?1465603161)

Plug your LiPoly battery into the JST connector on the backpack, and plug your Dotstars into the Dotstar connector. &nbsp;Click the on/off switch and watch your firey lights burn!

If the lights are dim or don't come on, double check all your wiring and make sure there are no fuzzy wires shorting across any pins. &nbsp;If you can't find anything wrong, check out the [troubleshooting tips under option 1](../../../../led-campfire/wiring-option-1).

# LED Campfire

## Build the Fire

![](https://cdn-learn.adafruit.com/assets/assets/000/032/940/medium800/adafruit_products_logs_layout.jpg?1465603589)

Now that your LED strip is flaming and sparking, it's time to add the logs to turn this project into a campfire.

Select logs and sticks with pleasing textures. &nbsp;Forked sticks work great, since you want the fire to pile and hold together nicely -- weaving the forked twigs in and around each other will give your fire architecture and height, and lots of nooks and crannies for hiding the LEDs.

Pile up the logs into a sturdy and aesthetically pleasing shape, then secure them together with long deck screws.

![](https://cdn-learn.adafruit.com/assets/assets/000/032/941/medium800/adafruit_products_logs_ready.jpg?1465603601)

Turn on your LED strand and put your fire on top of it. &nbsp;Weave the strand in and around the logs. &nbsp;You're going for indirect light as much as possible here -- if you can see the bare LEDs it will ruin the effect. &nbsp;Use the logs to create artful diffusion.

Steel wool is another great diffusion medium for any spots your LED strip is still showing.

![](https://cdn-learn.adafruit.com/assets/assets/000/032/942/medium800/adafruit_products_leds_weave.jpg?1465603693)

Glue the LED strip to the underside of the logs. &nbsp;Silicone glue works best for this -- it's about the only thing that will stick to the silicone sleeve on the Dotstars, and it fills in gaps in the wood nicely too.

Secure the Pro Trinket to an edge of the fire where you can reach the USB port and battery jack fairly easily, and glue&nbsp;it in place.

![](https://cdn-learn.adafruit.com/assets/assets/000/032/943/medium800/adafruit_products_glued.jpg?1465603706)

Secure&nbsp;the switch and battery somewhere inconspicuous, and you're ready for a smoke- and spark-free hootenanny.

If you've added the LiPoly backpack and charger, you can run the fire plugged in via the USB port on the Pro Trinket, and the battery will charge the whole time it's plugged in. &nbsp;Unplug it and it will run for hours on a charge -- mine lasted through the evening hours of a 4-day camping trip without needing to be recharged.

# LED Campfire

## Fiber Optic Sparks

![](https://cdn-learn.adafruit.com/assets/assets/000/033/002/medium800/adafruit_products_campfire_still.jpg?1466198478)

Adding fiber optic sparks to your fire takes it to the next level of awesomeness. &nbsp;Glowbys hair barettes are the perfect form factor and size, and can be easily added to your camp fire with a little spray glue.

Note: I'm using the **older, discontinued version** of Glowby hair clips since I had them on-hand. &nbsp;The newer versions will look slightly different, with an open/close lid instead of a sliding lid, but the wiring should still work the same way.

Glowbys&nbsp;run on two coin cell batteries, and they don't have an on/off switch (you have to remove the battery cover to turn them off). &nbsp; I wanted my fire to turn&nbsp;on with one button press and didn't want to have to fumble&nbsp;around with multiple batteries in the dark. &nbsp;Here's how I wired the Glowbys directly into my campfire's circuit.

![](https://cdn-learn.adafruit.com/assets/assets/000/032/997/medium800/adafruit_products_glowby.jpg?1466187006)

Open the glowby up and pull out the batteries. &nbsp;Bend the LED leads up and solder a 100 ohm resistor to the positive lead, and a red wire to the other side of the resistor. &nbsp;Solder a black wire to the negative lead.

Bend the resistor around in an "S" shape so it fits neatly inside the battery space without shorting against itself.

Pull the metal bit out of the inside of the glowby's lid. &nbsp;Carefully close the lid, making sure your two wires are safely separated inside so they don't short out.

![adafruit_products_glowby_lid.jpg](https://cdn-learn.adafruit.com/assets/assets/000/032/998/medium640/adafruit_products_glowby_lid.jpg?1466187348)

![adafruit_products_glowby_closed.jpg](https://cdn-learn.adafruit.com/assets/assets/000/032/999/medium640/adafruit_products_glowby_closed.jpg?1466187363)

![](https://cdn-learn.adafruit.com/assets/assets/000/033/003/medium800/adafruit_products_glowby_splice.jpg?1466199722)

Now, splice&nbsp;your red and black wires into the red and black connector wires on your campfire. &nbsp;&nbsp;

![](https://cdn-learn.adafruit.com/assets/assets/000/033/000/medium800/adafruit_products_spray_glue.jpg?1466188119)

Turn your campfire on and weave the fiber optics in and around your sticks. &nbsp;Gently secure them down with spray glue if needed. &nbsp;

**Note: some spray glues may damage the fibers** so be sure to test your glue on a small section first.

I also left a few sparks "hovering" above the fire. &nbsp;These sparks move and dance in a breeze or if I blow on the fire, adding another level of realism and awesomeness.


## Featured Products

### Adafruit Pro Trinket - 5V 16MHz

[Adafruit Pro Trinket - 5V 16MHz](https://www.adafruit.com/product/2000)
 **Deprecation Warning: The Pro Trinket bit-bang USB technique it uses doesn't work as well as it did in 2014, many modern computers won't work well. So while we still carry the Pro Trinket so that people can maintain some older projets, we no longer recommend it.** Please...

In Stock
[Buy Now](https://www.adafruit.com/product/2000)
[Related Guides to the Product](https://learn.adafruit.com/products/2000/guides)
### Adafruit DotStar Digital LED Strip - White 30 LED - Per Meter 5m

[Adafruit DotStar Digital LED Strip - White 30 LED - Per Meter 5m](https://www.adafruit.com/product/2238)
Move over NeoPixels, there's a new LED strip in town! These fancy new DotStar LED strips are a great upgrade for people who have loved and used NeoPixel strips for a few years but want something even better. DotStar LEDs use generic 2-wire SPI, so you can push data much faster than with...

In Stock
[Buy Now](https://www.adafruit.com/product/2238)
[Related Guides to the Product](https://learn.adafruit.com/products/2238/guides)
### 3 x AAA Battery Holder with On/Off Switch and 2-Pin JST

[3 x AAA Battery Holder with On/Off Switch and 2-Pin JST](https://www.adafruit.com/product/727)
This battery holder connects 3 AAA batteries together in series for powering all kinds of projects. We spec'd these out because the box is slim, and 3 AAA's add up to about 3.3-4.5V, a very similar range to Lithium Ion/polymer (Li-Ion) batteries and have an on-off switch. That makes...

In Stock
[Buy Now](https://www.adafruit.com/product/727)
[Related Guides to the Product](https://learn.adafruit.com/products/727/guides)
### JST-PH 2-Pin SMT Right Angle Connector

[JST-PH 2-Pin SMT Right Angle Connector](https://www.adafruit.com/product/1769)
A simple 2-pin connector that is compatible with the "JST PH 2-pin" connector - perfect for soldering to the bottom of our [3.3V Logic Trinket](//www.adafruit.com/products/1500) and [5V Logic Trinket](//www.adafruit.com/products/1501)! These mate perfectly with...

In Stock
[Buy Now](https://www.adafruit.com/product/1769)
[Related Guides to the Product](https://learn.adafruit.com/products/1769/guides)
### Adafruit LiIon/LiPoly Backpack Add-On for Pro Trinket/ItsyBitsy

[Adafruit LiIon/LiPoly Backpack Add-On for Pro Trinket/ItsyBitsy](https://www.adafruit.com/product/2124)
If you have an ItsyBitsy or Pro Trinket you probably know it's the perfect little size for a portable project. This LiPoly backpack makes it really easy to do! Instead of wiring 2 or 3 boards together to make a charging system, this little PCB sits on top of the PCB and allows a...

In Stock
[Buy Now](https://www.adafruit.com/product/2124)
[Related Guides to the Product](https://learn.adafruit.com/products/2124/guides)
### Lithium Ion Polymer Battery - 3.7v 2500mAh

[Lithium Ion Polymer Battery - 3.7v 2500mAh](https://www.adafruit.com/product/328)
Lithium-ion polymer (also known as 'lipo' or 'lipoly') batteries are thin, light, and powerful. The output ranges from 4.2V when completely charged to 3.7V. This battery has a capacity of **2500mAh** for a total of about 10 Wh. If you need a smaller battery, <a...></a...>

Out of Stock
[Buy Now](https://www.adafruit.com/product/328)
[Related Guides to the Product](https://learn.adafruit.com/products/328/guides)
### Tactile On/Off Switch with Leads

[Tactile On/Off Switch with Leads](https://www.adafruit.com/product/1092)
Squeeze once to turn on, squeeze again to turn off! This clicky switch makes a great power switch or mode toggler. We like this switch because it's easy to embed in a seam for easily powering up/off wearable and fabric projects. Can handle up to 14V and 2 Amps! This is a really satisfying...

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

## Related Guides

- [Using NeoPixels and Servos Together](https://learn.adafruit.com/neopixels-and-servos.md)
- [Color Balancing Video Camera Light feat. DotStars](https://learn.adafruit.com/color-balancing-light-box-with-dotstar-cool-warm-white-leds.md)
- [Galaxy Pendant](https://learn.adafruit.com/life-proof-led-necklace.md)
- [DRAFT PUNK](https://learn.adafruit.com/draft-punk.md)
- [Zelda Guardian Robot Terrako Companion](https://learn.adafruit.com/terrako.md)
- [Ray Gun Blaster](https://learn.adafruit.com/ray-gun-blaster.md)
- [Electronic Animated Eyes for ARM Microcontrollers](https://learn.adafruit.com/animated-electronic-eyes.md)
- [Adafruit Pro Trinket LiPoly/LiIon Backpack](https://learn.adafruit.com/adafruit-pro-trinket-lipoly-slash-liion-backpack.md)
- [Pro Trinket Rotary Encoder](https://learn.adafruit.com/pro-trinket-rotary-encoder.md)
- [NeoPixel LED Necklace Insert with USB Charging](https://learn.adafruit.com/neopixel-led-necklace-insert-with-usb-charging.md)
- [Introducing Pro Trinket](https://learn.adafruit.com/introducing-pro-trinket.md)
- [A NeoPixel Pomodoro Timer](https://learn.adafruit.com/a-neopixel-pomodoro-timer.md)
- [Cup o' Sound](https://learn.adafruit.com/cup-o-sound.md)
- [Trinket “Question Block” Sound Jewelry](https://learn.adafruit.com/trinket-question-block-sound-jewelry.md)
- [Adafruit NeoKey Trinkey](https://learn.adafruit.com/adafruit-neokey-trinkey.md)
