Introduction: Song-following Led-flashing Hack-O-Lantern!

About: Hi! I'm a freshman in college at California Polytechnic State University, majoring in Aerospace engineering. I interned for a short period at Instructables and love building and making. A few of my projects ar…

Make a jack-o-lantern that plays, and flashes Multi-Colored LED's to everyones favorite Halloween song.

Step 1: Overview

This project will show you how to make an awesome PIC controlled pumpkin that flashes different LED's to the tune of the Adams family at the same time as it plays the Adams family theme song through a speaker.

This video is of the LED lights going off outside of the pumpkin.


Sorry, I couldn't get my camera to pick up the light coming out of the pumpkin well enough to be worth including the video of this really working.

Step 2: Materials

Materials:

- Pumpkin!

- Super Bright LED's- I used regular LED's, and I think it would look a lot better with the super bright type of LED's

- Some kind of Micro-controller board - I used the Parallax Basic Stamp two because that was what I had, but I'm sure the Make Controller or some other type of controller could be used as well.

Nails- These will be used to hold the Micro-controller board onto the side of the pumpkin, you might not need these depending on how your controller can be mounted

Optional:

Computer Speaker- this will serve as an amplifier for the small speaker that comes with the Micro Controller

Tools:

Knives


Step 3: Carve Your Pumpkin!

I personally like to make my pumpkin scary, but this is the part where you get to decide what you do. The only thing that you will have to worry about is whether your LED's will be bright enough to show through your design. To make sure your LED's will shine through, don't make any really big holes in your pumpkin where light can escape. For some great pumpkin design ideas try this site

Step 4: Hook Up Your Microcontroller

This step really depends on the type of Micro Controller you use, I will be using the Parallax Basic Stamp 2 micro controller. If you have a different type of Micro Controller such as the Make Controller, and you need some help, feel free to ask in a comment.

You will need to hook up the LED's and speakers in the exact same place as I show, or the program that I will include in the next step will not work. In the 14th 13th 12th and 11th rows, plug in 470 ohm resistors leading into the far set of rows under the Vss terminals, the resistors should lead into the same row as they came out of. Now take four different LED's and plug the negative (shorter end) ends of the LED's into the Vss terminals. Take the positive ends (longer ends) of the LED's and plug them into the same rows as you plugged the resistors into (rows 14, 13, 12, and 11) The two ends of the speaker should be plugged into row 9, and into one of the Vss terminals, using a longer wire if necessary. If you are going to use a computer speaker to amplify the sound, just hook up the wire coming out of terminal 9 to the input wire of your computer speaker. The pictures should make all of this a lot clearer if this was confusing for you.

Step 5: The Software

The program that I made, is in the basic programming language, and will output the frequency required, at the same time as it lights up an LED. If your not a programmer or just don't like coding, don't worry, Ive included the code I used, and I will explain how it works so you can modify it if you need to. I've included the program in basic stamp format (.bs2) and in a text document (.txt)

' {$STAMP BS2}
' {$PBASIC 2.5}
These two commands above are to tell the compiler what type of coding you are using, and what type of hardware you will be using.


DO

The "do" command tells the controller to do everything it finds until it hits a loop command

HIGH 14

The "high" command tells the Controller to apply voltage to
the pin that follows, in this case the PIN is number 14,
the same number fourteen as there is on your micro controller


PAUSE 100

The "pause" command tells the controller to pause everything that it is doing
for a given time in this case it will pause for 100 mili seconds

FREQOUT 9,200, 1568

The "Freqout" command tells the Controller to output a certian frequency
for a certian durration of time through a certian pin number, in this case
the pin number is 9, the time is 200 mili seconds and the frequency is 1568Hz

LOW 14

The "low" command tells the controller to stop applying voltage to a certain pin,
in this case pin 14.

LOOP
The "loop" command tells the controller to go back the the "DO" command it
found earlier, this will create a loop.

Step 6: Put It All Together, and Have a Great Halloween

Now, all you have to do is put your controller into the pumpkin. I used a few nails to secure the controller to the side of the pumpkin so that more light would shine through my design. Once you've done this, you will have successfully completed your LED-Flashing, Song-Playing Hack-O-Lantern. Congratulations, you now have the beginnings of a great Halloween.

The Instructables Book Contest

Participated in the
The Instructables Book Contest