Visit our Halloween space and find out how to win one of two Cel Robox 3D Printers. There are two ways to win:
|Share your Project and Win|
|The Ben Heck Show Episodes|
Also: Check out my other Halloween project the "Scary Porch" : How to Startle Halloween Trick-or-Treaters with the Raspberry Pi B+
Disclaimer: I’m an engineer, not a pro film maker. Be advised.
Disclaimer: I’m an engineer, not a pro film maker. Be advised.
The Raspberry Pi Powered Halloween Effects Door. This is a video capture during one of the routines. (via Cabe)
Backyard haunted houses, carving pumpkins, elaborate decorations, jumping out to scare trick-or-treaters; Halloween is packed with the DIY spirit. People’s desire to be scared or scare others is primal. It’s the “fight or flight” response, the deep psychological need to survive. Halloween give many the chance to feel the fear, since back in our minds we know there is no real danger. Perhaps it is just the excitement that drives us to walk through that haunted house. Either way, it’s fun for both the builder and the viewer.
I am a big Halloween fan, visited countless haunted houses (multiple times), trick-or-treated at inappropriate ages (to see decorations), helped build some themed attractions, and of course dressed up. I think a lot of the passion comes from my brother building a haunted house back in the 80s. What would be considered a “backyard haunted house” today. My brother’s haunted house was burned a few days after it was built, but the one time I saw it made a lasting impression.
I had a talk with my brother, the following is paraphrasing the story:
Haunted house fair-use image.
The world looked a whole lot different when you were a kid living in the ‘80s, more so when the fall sets in and Halloween was just around the corner. This meant that the haunted house attractions were being set-up to fleece a modest price from neighborhood kids. Sure, back then there were haunted attractions at most giant amusement parks, such as Six Flags, but for us, that was a few hour drive and being 12 at the time we didn’t have a driver’s license, much less a vehicle. Still, in our eyes, the local haunted attractions looked great on the outside even though most of them were setup in a shopping center parking lot on the same lines as a carnival at local parks. After paying anywhere from $2 to $7, we would walk a maze of corridors that featured plastic and rubber body parts drenched in red food coloring, trap-doors that would spring open to reveal a shouting employee or plastic skeleton (also drenched in red dye) and of course strobe lighting complete with fog machines to give the place atmosphere. It didn’t take long for that vision of terror, while waiting outside to subside once we went through the place, which left us feeling a little disappointed. The fog (literally) was removed from our eyes and we could see those attractions for what they were: moneymaking machines using as little technology and effort as possible. After being continuously let down by most of those haunted houses and our money seemingly turning into ghosts from our pockets, we decided to do what any industrious kids would do. We built our own.
With our budget being extremely limited (most of it allotted for candy and soda), we needed a location where property wouldn’t be a factor and our friends parent’s backyard shed looked to be prime. We already used it as our clubhouse, so all we needed to do was transform it into the most terrifying experience people could have for the price of a buck. To make the place into a haunted house took some finesse along with some fishing line, Woolite, a few black lights, strobe light, faux spider webs (along with the real ones already in place), white sheets and hand tools. The clubhouse wasn’t very big but it did have two floors and several key escape hatches that could be utilized for a myriad of options. After several minutes of planning, we went to work by first cleaning out all the clutter to get more square footage (more like inches), after which we installed the lighting systems in key areas. Starting with the lighting first gave us more options on how things could be seen or rather unseen. Unlike most animatronic setups at the time (ShowTime pizza), we relied on a system of pulleys and fishing line to make most of our contraptions move. These were mostly positioned on the ceiling of the bottom floor and moved things like giant rubber spiders and snakes as well as for opening and closing hatches built into the walls.
One of my friends would stand behind one of the walls with his head positioned inside of a wall-mounted box, which looked like a severed head that would bleed and scream when the hatch was popped as patrons walked by. We positioned a homemade coffin at the entrance where my friend’s sister would hide in. When people were close enough, she would pop out (bleeding of course) as a vampire, scream and pop back into the coffin. As people went to open it, she would ‘vanish’ behind the coffin’s false bottom (we used spring-loaded hinges that would snap it back into place). We used Woolite fabric softener to paint scary images onto the clubhouse’s walls, which would glow when subjected to the black lights. This also allowed us to ‘mask’ some of the fishing line anchored to the walls with small eye screws. Over all, we completed the ‘house of horrors’ in about 4 hours and actually made about $5 on the opening night, which was subsequently the closing night as well. Our Goonies-styled contraptions didn’t frighten too many guests (all five of them) but it was fun to build, cheap to outfit (we took what we needed from our parents) and resulted in more candy and sodas that we could have while going to the next haunted attraction.
An older sibling of my brother’s friends burned the haunted house down. As was the practice of older brothers in the ‘80s. It’s a shame that no pictures were taken of it.
Things have changed dramatically since then, and haunted attractions have increasingly gone high-tech since the 80s. It is a striking contrast that the revenue generated this year is set to rake in over $500 million from ticket sales over haunted attractions from a few decades ago. This is mostly due the technology they incorporate. Fog machines, animatronics and strobe lights are still around but they have been enhanced using state of the art laser lighting systems, customizable rooms using sophisticated software to manipulate objects and surroundings and even 3D-based high-definition sound systems to create intense sound-scapes. Some of the more high-profile vendors are now using RFID bracelets to keep track of the visitors going through the attractions, for not only safety reasons (getting lost) but also to garner information on what frightens people. The bracelets are outfitted with sensors that monitor body heat and heart rate to gauge the level of horror experienced.
For those who do not visit haunted houses, here is sad fact – the same effects and props are used year after year, even the high tech ones. They just tend to get in more disrepair. In fact, you will see the same “scares” happen the same exact way every time. Even with live-actors, they tend to be rather repetitive; saying the same thing, rattling the same chains, it is monotonous for the actor as well as the repeat visitor. It seems once the program is set for the advanced effects, they are rarely changed. I maintain that with technology the possibilities in a haunted house should have an endless variation.
My goal was to create pro-haunted house level effects on the cheap. I wanted something that would be different every time you see it. Planning to combine visuals and sound, I created the monster behind the door effect. Through the window of the door, the viewer can see what might be happening behind the door. On time the viewer goes through might have a monster in the window trying to get through the door. The next time it would be a normal scene inside a house followed by the “monster pop-up” scare. Variety is my goal. It can turn a stale effect into one of constant apprehension.
The door’s window is, in fact, a LCD screen, making for an infinite number of possibilities. Also behind the door is an array of air-pistons to hit the door in various places to simulate commotion or direct hits. This door can be placed anywhere. Even at a distance, it has a frightening effect. This system could be adapted to work on any front door, as long as you don’t mind that door getting destroyed by pistons.
Disclaimer: I’m an engineer, not a pro film maker. Be advised.
Disclaimer: I’m an engineer, not a pro film maker. Be advised.
The project by sections and the project video
I wanted to create reproducible “scary” effects powered by the Raspberry Pi. Being a big haunted house fan, I wanted to mimic some of the classic gimmicks. This one, being the “thing” crashing behind a door or wall. As many probably know, this effect can get repetitive, even with a live person. So, I wanted to create a system that would cycle through different sequences for the surprise factor. Since a wall is not exactly frightening, I added a window to simulate that of a front door. The window gives the viewer the sensation that whatever it is, it is right behind a thin storm door.
Window and LCD behind the door:
24” screen used in the project. (via Cabe)
I added the LCD screen to the window to play the various video. In this case, I used a 24” 1080p TFT panel. It was adequate for the small window effect. I found the door had a butcher shop, creepy basement door feel, great for this example. I simply lined up the LCD with the door’s portal, and build a shelf to hold it. I set the LCD back a few inches so that the viewer would see a mesh-screen first before the video. “Hey, this is just a normal screen door.”
Pistons behind the door:
Pistons, solenoid vales, and air fittings for the set up. Also, The Enforcer photoelectric sensor on the bottom left. (via Cabe)
I wanted to hit the door in several places from top to bottom. To do this I used six BIMBA two-way air pistons, the kind found in factory assembly lines. I mounted them three inches from the edge of the door at the bottom, middle, and top. After some early tests that dented the front of the door, I layered sheet metal in the strike area of each piston - they were more powerful than I imagined. To actuate the pistons properly, I needed a five-way solenoid air-valve for each. The valves would let me control a piston in both directions. Driving the valves is an eight-relay board from SaneSmart. To split the air from the air compressor to each piston system, I constructed a six way air manifold. All that is needed is connecting the quick release hose from the air-compressor to the block. Push-to-fit air hoses run from the manifold to the valves and then to the pistons. No pun intended, but they hit with monster like force, which is terrifying in its self. The solenoid valves all run off of 110VAC.
Trigger for the event:
To trip an event on the door I originally planned a “door bell” like button. “Ring the doorbell, get a monster.” A friend suggested I trigger the door before the viewer even approaches. “oh, hey.. there is someone in the window… oh no, monster!” I liked that idea better, so I figured I would go with some sort of break-beam solution. After considering building my own, I found a break-beam device that have relay output… in other words, perfect. I bought a Seco-Larm “Enforcer” from amazon for a hefty price, but I found it was worth it. It has build in relay functionality. I am able to take either the NC or NO outputs of the relay and trigger anything I want. I could even trigger a piston directly.
Raspberry Pi’s driving force:
(Left) Piface and the Relay controlling Pi. (Middle) SaneSmart 8 relay board (Right) Video Pi. The black wiring is the AC (Hot) power line for the pistons. (via Cabe)
The Raspberry Pi portion is cut up into two sections; the video output and the relay output. To avoid any issues with bogging down a single Pi, I cut up the tasks onto two boards. A single Raspberry Pi will play the video content. It waits for a trigger/button input, once hit, it plays the first video in a series. With each additional button push, it plays the next and so on. The other half is controlled by a Raspberry Pi and a Piface Digital. I chose the Piface for the fact it already has two onboard relays capable of handling AC and DC. The Piface also has 8 open collectors ports. This makes for easy triggering of the Solonoid valves. I tied the Piface directly to the eight-relay board, mentioned earlier, with an old IDE cable. Worked great, however, I am sure the IDE cable is not a proper cable for supplying 5V to the eight –relay board. When the Enforcer sensor detects a break, it triggers both Raspberry Pi boards at the same time, producing the timed effects I wanted.
Content - the scary material:
Another creepy screencap. Why is the TV so close to the door? (via Cabe)
The content was a different story. It seems more thought went into this part than I needed elsewhere, it was surprising. I downloaded some video from youtube I found scary. Almost all of it needed some editing. I used Sony Vegas Movie Studio HD to chop up and change some of the video. I needed all of them rendered at 1080P, despite their original resolution, easily done with the Vegas. In the case of the “Rubber Johnny” video by Aphex Twin, I cut up the scenes I thought would create the best effect. I wanted it to look like someone was further in from the window, looking creepy, then slamming their face in the window, like what is in the video. I think it worked out quite well. Then came the relay programming, the biggest time consumer.
Code on the Raspberry Pi:
Despite what I thought was a great way to trigger the relays, with a single line of code, I needed to also shut them off. So, to perform a single on then off sequence required two lines (one to start, one to end), not the end of the world. To program the sequence, I just needed the time, from the beginning of the video, when each relay was supposed to hit. Watching the video in Vegas made that easy, I could see exactly on the timeline when I wanted the relay event. I then just hard programmed in the sequence I want. Each line of code contains the time at which to fire the piston. For example, fire piston one at three seconds into the video, etc.
The initial tests of hitting the door ended up with the door dented in all six piston locations. They were far too powerful, even at 40 PSI. I layered a few sheets of sheet metal in the strike areas where the pistons hit. I also machined six plastic piston tips to spread out the force.
Early versions was a single push button. I dropped this for the Enforcer sensor.
Video editing was probably the most time consuming. Picking the video, editing sections, adding sound, etc was all done through Sony Movie Studio HD. I learned the basics in an hour. However, with more experience, I think this wouldn’t be an issue at all.
Coding in debounce routines was the only major code issue. After working out a different scheme, I was able to stop the program from triggering the next video/relay series before the first finishes.
Making the screen black while the program is running was an issue. I didn’t think the Linux desktop or command line was all that frightening.
Schematics and design
To see it in full detail, download the PDF. (See files attached to this post)
The important part of the video code. (via Cabe)
I wrote the video output program in regular old C, since it was good enough to call up OMXPlayer for playing the video/audio. I just place the videos number “1,” “2,” … “#” into the video directory. I wrote this part some time ago.
The relay code, where the sequences get defined. It is a simple relay on/relay off scenario. (via Cabe)
I used C++ on the relay/Piface code. The file “ap-gen.h” header file is the most important part of the system. It contains the relay sequences. It is a bit brute force, turn on then turn off, but it does the job. Geany was used to compile. http://www.geany.org/
Bill of material (BOM)
|Raspberry Pi Model B (2X)||A credit card-sized board with a Broadcom BCM2835 System-On Chip running Linux.||Raspberry-Pi|
|Piface Digital||PiFace™ Digital plugs onto the top of your Raspberry Pi, and allows you to sense and control the real world.||PiFace|
|Pre-Programed-8GB-SD Card (2X)||Raspberry Pi 8GB SD Card pre-loaded with NOOBS—a collection of 6 operating systems.||Raspberry-Pi|
|Breadboard, Solderless, 400 Tie Points||Breadboard, Solderless, 400 Tie Points||Twin Industries|
|Budget Pack for Raspberry Pi||Budget Pack for Raspberry Pi (Mostly unused, only for parts)||Adafruit Industries|
|Raspberry Pi Halloween Effect Door v1.0 Bill of Material by Cabe Atwell 10/1/2013|
|DESCRIPTION||QUANTITY||Unit Price||VENDOR||Vendor Part#||PRICE|
|Blue Wire Nuts, pack of 35||1||$1.97||Home Depot||NA||$1.97|
|Storm Door||1||$50.00||Home Depot||NA||$50.00|
|2x4 x 8'||7||$2.57||Home Depot||NA||$17.99|
|1x2 x 8'||2||$0.90||Home Depot||NA||$0.90|
|2'x2' Sheet metal||2||$8.00||Home Depot||NA||$16.00|
|Drywall Screws 2 1/2", 1 LB||1||$11.96||Home Depot||NA||$11.96|
|Extra-Flexible Nylon Tubing .180" ID, 1/4" OD, .035" Wall Thickness, Semi-Clear White, (50 ft. roll)||1||$21.00||McMaster Carr||5112K43||$21.00|
|Medium-Pressure Brass Threaded Pipe Fitting, 1/4 Female X 1/8 Male Pipe Size, Adapter||24||$1.58||McMaster Carr||50785K26||$37.92|
|Steel Two-Hole Clamp, for 13/16" OD, 1/2" Pipe/Rigid Conduit Size, (pack of 50)||1||$7.76||McMaster Carr||9439T43||$7.76|
|BIMBA 040.5-D-B PNEUMATIC CYLINDER 1/2" STROKE 3/4" BORE, (LOT OF 7)||1||$70.59||Ebay||NA||$70.59|
|4 Way Pneumatic Directional Solenoid Valve 120VAC Coil 1/4" NPT work ports||6||$19.85||Ebay||NA||$119.10|
|1/4" Tube x 1/4" NPT push to connect fitting, (pack of 10)||4||$7.37||Ebay||NA||$29.48|
|ASUS 24" LCD||1||$100.00||Ebay||NA||$100.00|
|Zitrades (SaneSmart) 5V 8 Channel Relay Module for Arduino DSP AVR PIC ARM||2||$14.25||Amazon||NA||$28.50|
|Palm Touchpad 5V 2A microUSB power supply||1||$5.00||Amazon||NA||$5.00|
|Seco-Larm E-931-S35RRQ Enforcer Indoor/Outdoor Wall Mounted Photoelectric Beam Sensor||1||$49.00||Amazon||NA||$49.00|
|Raspberry Pi Model B||2||$35.00||element14||43W5302||$70.00|
|PRE PROGRAMMED, MICROSD, 8GB, RASPBERRY PI||2||$17.99||element14||97W1422||$35.98|
|BREADBOARD, SOLDERLESS, 400 TIE POINTS||1||$7.35||element14||56T0249||$7.35|
|BUDGET PACK, RASPBERRY PI (Mostly unused, only for parts)||1||$49.95||element14||44W3511||$49.95|
|Items found or for free|
|Air Compressor (Harbor Freight model)|
|Quick fit air compressor lines/fittings|
|Door brackets for handing, made from scrap aluminum|
|HDMI and HDMI to DVI cables|
|Keyboards and mice|
|CNC Mill, Manual Mill & Lathe, Power Drills, Sheet metal cutter, various hand tools|
SEE BOM PDF
Other uses of the system
The system being cut up into two sections can give the DIY Halloween fanatic some freedom of choice.
- Placing the pistons around, underneath some boxes let’s say, could create the ghostly moving objects effect. Set the sensor so that everything jumps when the visitor is surrounded by the objects. Only need a relay program.
- Using the video program and a projector, a large image can be displayed when visitors walk through the sensor. Like a giant screaming face covering a whole room or even a field.
- Using the relay program and board, have the relays turn on pairs of LED lights to simulate eyes in the forest. The user walks up, a pair of eyes light up… then twenty more. Feeling ambitious, make it a hundred pairs.
- Using the relay program and the pistons again, make it so it looks like hands are trying to push through the wall. A large white rubber sheet to simulate a wall and some mannequin hands behind it would do the trick. This would require a second set of valves to slow the pistons down. Alternatively, you can use motors and leadscrew to actuate the hands.
- Use the relay program to turn on electronic toys suddenly, as if the toys are possessed. This is similar to the ghostly objects.
- Relay program again, have it fire pistons against some wood. As the visitor walks through a path, the pistons make a startling effect.
- I could go on and on… here is the final thought… make the system do all of the above at the same time! It is possible, and it is cheap.
If I had more time/money
- I would have liked to use one of those cheap 40” LCD TVs in portrait mode – giving a much more intimidating feel.
- A change from TFT to and IPS monitor would be a good idea. IPS has better colors and wider viewing angles.
- More pistons in other door locations, and even around the door would have been useful. Like, popping a piston behind the viewer.
- More scary videos and relay routines.
- Streamlines code onto one system. Perhaps one Raspberry Pi and the ChipKit Pi expansion board. Even with the existing code, I believe I could simplify it quite a bit, especially in the relay section.
- I would have liked to setup the pistons to move slower. This would have required a secondary valve that would restrict the airflow when each piston is triggered.
- I would have made a wireless trigger or even a series of triggers for different effects.
Oddities and observations
- When I would turn on compact florescent lights, or when the pistons would fire at the end of programs, had a tendency to trip the next video cycle. I attribute this to a few issues.
- The wire lengths connecting all the Raspberry Pi and relay board. This will act like an antenna, tripping the system falsely. Making the lines shorted did help. See my cartoon about this effect.
- With every solenoid valve, there is back-EMF when discharging. Being so close the Raspberry Pi boards would have tripped the system.
- The lights also seemed to have an effect Photoelectric Beam Sensor (the Enforcer).
With a little more time, I would have made a tight and shielded Raspberry Pi setup, placed transient suppression diodes on the solenoid valves, and made sure no compact florescent lights were around the system (just to be sure).