DIY Interactive Animated Pumpkins - 3D Printed | Raspberry Pi

by DIY Machines in Circuits > Raspberry Pi

20445 Views, 143 Favorites, 0 Comments

DIY Interactive Animated Pumpkins - 3D Printed | Raspberry Pi

DIY Interactive Animated Pumpkins - 3D Printed | Raspberry Pi
Instructables Cover Card.jpg

In this project I’m going to explain (and show) you how to 3D print and build this trio of performing pumpkins. 🎃

Though the pumpkins are outside themselves , these three singing squashes are brought alive by a single low-cost projector from the inside of your home. This means you do not need to worry about mains electricity outside, or any trickers - treating themselves to your projector.

The performance is controlled by your visitors using this set of mini-arcade buttons in the 3D printable control housing. They can choose between a Song, scare or haunting tale. The speaker for the audio is built into this control panel so that your guests can hear the pumpkins clearly from where they are stood without waking your neighbours from their crypts.

I have prepared a project video which shows the pumpkins in action at the beginning if you wanted to see the effect. The video us embedded just above.

You Will Need...

Screenshot 2020-10-21 at 09.58.40.png

To build your own set of animated pumpkins you’re going to need a few things, I have included links and a list of everything. You’ll need:

(Both the portable speaker and projector can continue to be used after Halloween. We won’t be damaging them in anyway for this project. So you could use a projector you already own or use this as an excuse to buy one!) :)

Printing the Pumpkins

Screenshot 2020-10-20 at 17.10.38.png
Screenshot 2020-10-20 at 17.03.13.png
Screenshot 2020-10-20 at 17.10.56.png
Screenshot 2020-10-20 at 17.05.43.png
Screenshot 2020-10-20 at 17.11.12.png
Screenshot 2020-10-20 at 17.06.06.png
Screenshot 2020-10-20 at 17.06.29.png
Screenshot 2020-10-20 at 17.11.23.png

All the files for the 3D printed components can be found on my Thingiverse page: https://www.thingiverse.com/thing:4628211

You can off course make the pumpkins and control panel from any other suitable materials if you don’t have a 3D printer. Just ensure that it you are going to rear project onto the pumpkins as show in this project that your material for the pumpkins is translucent enough.

We can start by 3D printing three sets of parts for the Pumpkins. Each of your three pumpkin sets requires a base, left hand and right hand side, and stem/top. I have chosen to print two colours of pumpkins, one cream colour and two orange ones - each with green stems.

The base is printed with supports - it is the only part which requires them. I used a speedy 0.3mm layer height for the pumpkins as they will be seen from afar and in low light conditions. Two of them were printed in PLA and one in PETG (just because that it what I had to hand). The PLA pumpkins came out better because they were less stringy.

Brims were used for the two main sides and the stem requires neither a brim or supports.

Please take a look at the images above for the print orientations I have the designed the parts to be printed at.

Assembling the Pumpkins

Screenshot 2020-10-20 at 17.18.21.png
Screenshot 2020-10-20 at 17.20.29.png
Screenshot 2020-10-20 at 17.20.37.png
Screenshot 2020-10-20 at 17.20.45.png
Screenshot 2020-10-20 at 17.23.34.png
Screenshot 2020-10-20 at 17.23.42.png
Screenshot 2020-10-20 at 17.23.47.png
Screenshot 2020-10-20 at 17.24.03.png
Screenshot 2020-10-20 at 17.27.20.png
Screenshot 2020-10-20 at 17.27.41.png
Screenshot 2020-10-20 at 17.24.44.png

To assemble the pumpkins you will need some M3 nuts and bolts.

Take the stem and fix each of the two side parts using a pair of bolts each through its underside.

The base is then attached using two more M3 bolts (and nuts if you would like a tighter fit depending on your printing tolerances). This is done through the tab like holes on each of the side prints.

To hold together the front edges of the pumpkins panels we will use glue. I’m going to use hot melt glue as I can smooth it out with my finger whilst it is still warm and it’s fairly invisible to the projections. You could also consider using super glue or even a 3D printing handheld pen if you have one - just ensure that you don't increase the thickness of the shell too much or it will show as a darker patch when we apply our projections.

Printing the Control Panel

Screenshot 2020-10-20 at 17.31.25.png
Screenshot 2020-10-20 at 17.32.25.png
Screenshot 2020-10-20 at 17.33.59.png
Screenshot 2020-10-20 at 17.34.08.png

There are two different 3D printable design for the control panel which I have created for you to use. One includes a mounting for the low-cost battery speaker I used in my project and the other design does not include space for the speaker leaving you to decide how to handle the audio your own way.

I recommend printing this part on the print bed face down. It has been designed so that you can momentarily change the filament colour after a few layers to add the colour to the text on the front. Use a large brim to help with adhesion whilst this part prints and I did not require any supports.

Preparing the Buttons

Screenshot 2020-10-20 at 17.41.41.png
Screenshot 2020-10-20 at 17.34.36.png
Screenshot 2020-10-20 at 18.37.48.png
Screenshot 2020-10-20 at 18.40.55.png
Screenshot 2020-10-20 at 18.41.04.png

For this step you will need:

  • Momentary illuminated 30mm arcade buttons (x3)
  • 10cm lengths of 'hook-up' wire (x9)
  • 220 ohms resistors (x3)

Orientate the button so that we can see the legs on the underside and so that the pair of legs coming out through the grey plastic are towards the top (these are the legs for the button mechanism, the bottom pair are for the LED). We can then put a resistor between the top right and bottom left leg and a wire onto all of the legs accept the bottom left.

These can then all be soldered into position and any excess wire trimmed away.

Repeat this for all three buttons.

Fitting the Buttons Into the Control Panel

Screenshot 2020-10-20 at 19.42.39.png
Screenshot 2020-10-20 at 19.48.10.png
Screenshot 2020-10-20 at 19.47.59.png
Screenshot 2020-10-20 at 19.42.39.png
Screenshot 2020-10-20 at 19.48.28.png

To add the buttons into the housing you will need to remove the plastic nut if it is still attached. Thread the button down through the front of the housing and then firmly tighten the nut from the inside of the housing.

Again, repeat for all three. :)

Adding the Audio Jacks to Our Cable

Audio Jack Connecitons - Coloured.jpg
Screenshot 2020-10-20 at 19.57.21.png
Screenshot 2020-10-20 at 19.58.49.png
Screenshot 2020-10-20 at 19.57.44.png
Screenshot 2020-10-20 at 19.58.06.png
Screenshot 2020-10-20 at 19.58.12.png
Screenshot 2020-10-20 at 19.58.24.png

You will need both 3.5mm jack connections for this.

If you remove the plastic sleeve from the connector by unscrewing it you will find three legs. The leg highlighted in red in the image is for the right hand side audio and the green leg the left hand side audio. The leg highlighted in blue is a common ground.

You will need to expose about 10 cm's worth of internal wires from inside your long multi-core cable and then solder any three onto the three legs on the connector. Before you solder it though, make sure you slide the plastic sleeves over the three wires so that it is in place for screwing back together once the soldering is complete!

We can then repeat this at the other end of the multi-core cable but this time you will need to expose about 20 cm's worth of internal wiring and this time use the same three wire colours you used earlier in the same three positions.

You can check your work by using the cable between something such as your laptop/phone and the speaker.

Connecting Buttons to Our Main Cable

Screenshot 2020-10-20 at 21.01.51.png
Screenshot 2020-10-20 at 21.02.16.png
DIYM Halloween 2020 - Wiring Sheet2.jpeg
Screenshot 2020-10-20 at 21.07.13.png
Screenshot 2020-10-20 at 21.07.30.png
Screenshot 2020-10-20 at 21.07.33.png

As this is a very seasonal project I will use plastic 'Wago' connectors to join my wire up in this step of the project. This will make it very easy for me to re-use the cables and buttons in another project in the future. You can use either a similar type of connector, or solder the wires together if you prefer.

The first bundle of wires we need to connect are the ground wires from the buttons (for me this is the purple wires I used) and a wire from the main cable length. I chose purple again to help follow things through.

To make it easier to follow I created a sheet (you'll find it above) which you can use to record which wire is connected to which in the main cable. You'll see a blank copy above for you to use (you can either screenshot/photograph it with your phone and fill it in on device or print it). There is also a copy I have filled in for my records to show you an example of what a completed sheet should look like.

So for my purple ground wires, I have recorded that I connected them to the purple wire in the main cable.

Work through the remaining wires, but this time just connecting one unique wire from the buttons to one wire from the main cable whilst keeping your records up to date.

Connecting Our Main Cable to the Raspberry Pi

Dupont Connectors - Quickly and easily make your own
Screenshot 2020-10-21 at 09.35.51.png
Screenshot 2020-10-21 at 10.00.26.png
Screenshot 2020-10-21 at 10.00.10.png
Screenshot 2020-10-21 at 10.00.39.png
Screenshot 2020-10-21 at 10.00.34.png
Screenshot 2020-10-21 at 10.00.59.png
Screenshot 2020-10-21 at 10.00.45.png
Screenshot 2020-10-21 at 10.01.05.png
Screenshot 2020-10-21 at 10.01.12.png

Now that we have one end of our main cable connected we can connect the other end. This is the end which we exposed roughly 20cm's worth of internal wiring on earlier.

To connect them I'm going to add the wires into a simple and cheap Dupont style connector using some female crimps. This means it's very easy to connect and disconnect the cables from the Pi which is ideal for several reasons.

  1. It's much easier to transport things when you can break them down to smaller parts.
  2. It allows me to pass this end of my cable through the letter box / window when I set up the show.
  3. I don't need to make any semi-permanent solder connections to the Pi.

I have a made a separate video and guide on Instructables which will step you through how to crimp your wires ready for adding into the plastic housing of the Dupont connector. The video is above and the Instructable article is here: https://www.instructables.com/Crimping-Dupont-Connectors/

If you are going to solder your wires, don't worry! I've not abandoned you. If you look at the sheet you filled in earlier to record which wire is connected to which then you will see that I included the pin label it needs to be connected to on the Raspberry Pi in the bottom right of each box you completed. :)

If you're going to use a Dupont connector like I have then we need to add in the wires in a specific order to the 2x4 connector housing. You will want your completed wiring sheet in front of you again for this step. I have included mine above but don't forget that you may need to connect to different coloured wires - mine is an example.

Work your way through adding in each wire. The top right corner one is meant to be left blank.

To connect this to your Pi it is positioned offset from the left by three pins with the missing pin furthest away from the left on the outside edge of the Pi. Check the image above - it will make this much clearer. :)

Programming Your Pi and Adding Video Clips

Screenshot 2020-10-21 at 10.02.19.png
Screenshot 2020-10-21 at 10.12.46.png

There are several steps we need to work through for the software side of things - this includes:

  • Installing and configuring Raspbian / Pi OS on to your SD card
  • Installing Pi Presents and supporting software
  • Copy across some pre-prepared profiles and sample video files
  • Setting the show to start automatically at power on
  • Adding your own video files

I have not covered these steps in the project video as they are easier for you to follow when you're able to copy and past commands. It's also rather boring to watch. :/

I have written out a guide on my site which you can follow here: https://www.diymachines.co.uk/interactive-perform...

This where you can also download the sample video clips for your project. I decided not to copy and paste the instructions into this article as it is easier for me to keep them up-to-date and correct if I only have to worry about one location.

Mounting the Pumpkins to Windows

Screenshot 2020-10-21 at 10.32.44.png
Screenshot 2020-10-21 at 10.32.59.png
Screenshot 2020-10-21 at 10.33.05.png
Screenshot 2020-10-21 at 10.33.09.png
Screenshot 2020-10-21 at 10.33.13.png

To mount the pumpkins to the outside of your windows you need to print three of the aptly names 'Pumpkin Mounts'.

Each of these are then coupled with a pair of suction cups and secured to your window. The pumpkins shells you made earlier can then be simply hooked over the mounts. This makes it very easy to adjust or remove the pumpkins when required.

Labelling the Buttons

Screenshot 2020-10-21 at 10.33.36.png
Screenshot 2020-10-21 at 10.38.34.png
Screenshot 2020-10-21 at 10.38.42.png

We can then print a label to attach to our control panel so that your visitors can tell which button will do what. I kept this as a separate part so that you could change the labels to suite your project if you wanted to.

I changed the filament colour part way through the print to get the two colour look. This can then be glued into position just below the buttons.

Installing Control Panel Speaker and Cover

Screenshot 2020-10-21 at 10.40.06.png
Screenshot 2020-10-21 at 10.42.22.png
Screenshot 2020-10-21 at 10.42.28.png

To finish of the the control panel we need to install the speaker (if you chose to build the one with the same Sony speaker I'm using). To do this, plug the jack connection into the speaker, turn on its power and ensure that it is turned up.

Slide this into position and then check that any plastic wiring connectors are tidied up around the housing. The 3D printed rear cover can then be secured in place with some M3 bolts.

Securing Control Panel Outside

Screenshot 2020-10-21 at 10.46.05.png
Screenshot 2020-10-21 at 10.46.21.png
Screenshot 2020-10-21 at 10.46.29.png
Screenshot 2020-10-21 at 10.46.36.png

I have decided to mount my control panel on top of the 70mm x 70mm post at the end of my driveway. For this I printed a sleeve that is secured over the top of the post with some wood screws.

Our control panel is then slid into place thanks to it's wider foot shape. This can also then be kept secure from theft by adding a padlock though the loop at the rear. This will make it much more difficult for people to remove.

Show Time...

Screenshot 2020-10-21 at 10.46.59.png
Screenshot 2020-10-21 at 10.51.46.png
Screenshot 2020-10-21 at 10.52.10.png
Screenshot 2020-10-21 at 10.52.15.png
Screenshot 2020-10-21 at 10.52.29.png

All that's left to do now is to:

  • Connect you Pi to the projector with HDMI cable
  • Connect the audio jack (I connected mine to the projector headphone port)
  • Power on the projector
  • Power on the Raspberry Pi

Your show should start itself automatically and the three arcade buttons will light up on the control panel waiting for someone to choose a performance. Take it for a spin - but I warn you, the tunes get stuck in your head and haunt you. :)

Should you want to support my projects, please consider subscribing to me on here and Youtube. I also have a Patreon page where some very kind people are helping me to cover the cost of designing, documenting and sharing these projects. Please consider joining them in any way if you can.


A vote in the Halloween competition would also be very much appreciated.

Until the next project, ciao for now. Lewis