Introduction: Lilypad Arduino - Rainbow Fish Twinkle Bag
I am participating in a course this semester on technology in schools & libraries. We were required to do some sort of project using the LilyPad Arduino and its software. This was my first experience sewing, and was definitely a "learn-as-you-go" assignment with the coding.
This "literary" bag idea came out of inspiration for my god-daughter who loves to read books and sign fish. I found a simple lunch bag template online that I modified from the following site - (http://www.designsponge.com/2009/09/diy-project-kates-notebook-lunchbag.html). I also wanted my fish to light up and twinkle but not make any noise, so I borrowed and modified some code from the following project - (https://www.sparkfun.com/tutorials/312).
To see the bag in action download the video file below, or click: https://www.youtube.com/watch?v=dMh-lgW95Ow&feature=youtu.be
Step 1: Materials
A couple Yards of different color fabric (my bag was made of blue medium weight felt, and my straps were deep purple)
Scraps of non-stretchy fabric for fish body, scales and seaweed (such as felt or quilting cotton)
Scraps of see-through fabric for seaweed and fish-body
2 packets of Iron on letters (can be found at any fabric store)
All Purpose thread (I used green, red/pink, light blue, dark blue, and purple)
Sewing needles (I purchased a multi-packet with different sizes)
Fabric Glue
Iron (for the letters)
(Optional) If you can find something like an Embroidery hoop (which makes stitching easier, I couldn't find one)
(Optional) Fabric Paint (for extra decorations)
Electronics Materials:
ProtoSnap - LilyPad Development Board - https://www.sparkfun.com/products/11262
Green LilyPad LEDs - https://www.sparkfun.com/products/10046
Colored LilyPad LEDs - https://www.sparkfun.com/products/11842
Mini-USB cable - http://www.amazon.com/C2G-Cables-27005-Mini-B-Cable/dp/B000067RVL
FTDI driver- http://arduino.cc/en/main/software
Arduino IDE - http://arduino.cc/en/main/software (should be installed on your computer)
Fish Sketch/Trace Outline:
Rainbow fish B&W outline - http://www.pinterest.com/pin/522417625496516567/
Step 2: Bag Template
2. I traced with a yard stick the measurements of my bag, and cut along my dotted line to get the cross shape you see in the image below. The backside of the bag's bottom flap was the surface I was going to sew my decorative rainbow fish (aka the front of the bag).
3. (Optional Step) My next step was to trace and cut out my fish design for the front of the bag. If you want you could have first used the trace to put together a "sketch" of where the electronic components would go. The main circuit board, lights, & stitches with the conductive thread. I did not make this sketch, but it could be helpful for those who don't like to "free" sew these components.
Step 3: Fish Sketch & Construction (Part 1)
2. Cut out scale components in multiple colors (I used the children's book for inspiration of colors to use).
3. Place the scales inside the fish body to see if you have enough to layout and sew with. I had a couple left over just in case, as you can see from the pictures.
Step 4: Fish Construction (Part 2)
2. Place the head, tail, and fin components on the bag and sew on.
3. As you can see, I also cut out lips in yellow cotton fabric, and eyes with white & black fabric. I glued these on with fabric paint instead of sewing them down. It was quick and easier for me, but you can also sew them down if you want.
4. Next I placed the fish scales in a row and sewed them on individually. After two rows, and an hour of pricking my finger with the needle...I decided to glue the rest of the scales down. :-)
5. Finally, I placed and ironed on the title for my literary bag. Make sure you have an iron that can get hot enough for the letters to stick to felt (if that is the material you decide to use).
Step 5: Decoration & Bag Straps
1. Measure out on felt four 18" x 2" purple fabric straps (or what ever fabric you want).
2. Sew together two pieces of fabric for each strap (as you can see from below). This makes the straps thicker, and gives it that homemade sew look to it as well.
3. Save these straps to sew on at the end of bag construction.
Step 6: Sewing in the Electronics
1. Here is where you can really get creative depending on the design you have on the front of your bag. I made sure that all my LED's I sewed on with conductive thread was in a radial like pattern. Make sure you tie off and cut your thread for each LED, restarting on the next pad you'd like to sew down. You might find it easier to move to the other side of the board and sew your second LED down. Again, make sure you are sewing down the positive side of the LED...not the negative side.
2. Repeat this process for every pad except for the ones labeled (+) and (-). Since the conductive thread is uninsulated in my project, if the lines of stitching cross, two LEDs will receive the current meant for only one. So, remember not to cross the stitches of your thread. As you can see from the image of the circuitry that I sewed on the back of the front of my bag, the positive (+) threading didn't cross the negative (-) line that goes around and connects all the LED's together.
3. You should now have all your LEDs connected to individual pads on the Arduino board on their positive sides, and all of them connected in one contiguous line to each other and to the ground pad (-).
Step 7: Uploading the Twinkle Code
1. Take the other end of the USB cable and plug it into your computer.
2. Next, you'll upload the Arduino program on your computer. (Note: If you haven't installed Arduino on your computer yet, you'll need to do it now. See the following hyperlink - https://www.sparkfun.com/tutorials/312
3. When you open the Arduino program, you'll get a blank "sketch" screen with the current date. Make sure you double check that you've selected the correct board under Tools --> Board --> Lilypad Arduino w/ ATemga328. Next it's time to upload the code that will run your LED lights. Copy and paste the code I used for the twinkle LED's in your blank sketch.
4. Remember, the code I used was borrowed and edited (the code is attached below). I have never really used C++ coding before, so it was easier for me to use this code and change it a bit. I'm sure that people who have more experience coding could do more (like add a song or what not), but since my niece loves toys that blink this was the best option for me.
5. Click the upload button and watch the LED's light up! If for some reason the lights don't blink, take a look at the black box at the bottom of the Arduino program. If you've got a red error message, check your com port. You can do this by opening up this menu and unplugging the cord that connects the computer to the FTDI board from the computer's USB port. Look at which COM port disappears, then plug the USB back into the computer and select that port.
Step 8: Final Touches!
Now you can go ahead and unplug the FTDI board from the Arduino board and plug in your battery. Once you turn flip the "on off" switch on the board, you should see the LED's light up again. As you can see from my pictures the last steps included: Sewing the seems of the bag together and adding on the bag straps.
I also made sure to add a sewn in strap to hold the battery attached to the board down (so it wasn't just floating in the bag). If you also want to protect the back of the board from anything you put in the bag, think about glueing or sewing in the back a pice of cloth on-top of the board.