HAUNTED HOUSE With Arduino
Introduction: HAUNTED HOUSE With Arduino
Would you dare to enter a haunted house as horrible and mysterious as this one?
In this project we have designed an enchanted house with the Arduino UNO that interacts with users. Depending on the movements that the user does the house will perform one action or another.
1. Turn on the lights of the house when turning the sign.
2. Open and close the door when ringing the bell of the house and turning the hall’s light on.
3. Wake up the lord of the house when touching his tomb and make the curtains move. If the actions take up during night terrorific lights will be opened.
Step 1: Materials Used in This Project
Electronic components:
Arduino UNO (x1)
Protoboard (x1)
Resistors 220 Ω (x9)
Resistors 10 kΩ (x4)
LEDs (x4)
LED RGB (x1)
Micro Servomotor (x1)
Motor CC (x1)
Photoresistor (x1)
Potentiometer (x1)
Transistor NPN (BJT) (x1)
Diode (x1)
Push Button (x2)
DFPlayer (x1)
Speaker (x1)
Micro SDcard Wires
Components of the house:
Cardboard to build the main structure of the house and other detail such as the door
Moss paper to recreate the ground
Scrapbook paper to simulate wood
Fan blade to move the curtain
Artificial ground
Halloween details such as spiders, cobweb, and so on
Fabric to make the curtains and ghosts
Wooden depressors to make the fence
Tools used:
Glue
Paints
Paint brush
Cutter Pliers
Stapler for fixing some cables
Soldering iron Ruler
Hand saw
Insulating tape for covering the cables once they are soldered so that there is no contact between them
Step 2: Schematic of Electrical Connections
Action 1: Turn on the lights of the house when turning the sign.
To perform the action used three LEDs, which represent the lights of the house, and a potentiometer to turn them on gradually. To make sure the potentiometer is coherent with the house and the context of Halloween we simulated the house entry sign.
Action 2: Open and close the door when ringing the bell of the house and turning the hall’s light on.
In that case, the idea is that when somebody rings the entry bell this one sounds while opening and closing the door of the house. This movement simulates ghosts and enchantments. At the same time. the same button, turns on the hall light of the house. The ring consists of a Push Button connected to the pin 2 of the Arduino board making the DFPlayer sound, the light of the hall a white LED and the door opens due to a Servo Motor.
Action 3: Wake up the lord of the house when touching his tomb and make the curtains move.
If the actions take up during night terrorific lights will be opened. Finally if you touch the tomb located on the garden, that in reality is a Push Button, will activate a motor CC connected to a fan, making the curtains of the house move and fly while playing a terrorific laugh played by the DFPlayer. 769
When this happens, if the house is located in a dark room, will make a LED RGB blink with an orange hue. To achieve that we used a photosensor.
Step 3: Flow Diagram
Step 4: Guide: ACTION 1
ASSEMBLY
1. Place the three white LEDs to the protoboard.
2. Connect them to the pins 3, 4, 5. (Remember that the LED lights have a positive and negative leg. To make sure they work connect the positive and longest legs to the pins).
3. Connect the negative and short legs of the LEDs to the ground.
4. Remember to put resistances of 220Ω so the LEDs do not burn.
CODE
1. Declare the necessary variables with the int function, to name the pins that will be used in the code.
2. In the setup() we indicate the pins chosen to send information or outputs.
3. In the loop() we declare a variable (“lecturaPotenciometer”) to read the potentiometer. Afterwards we declare a new variable (“brillo”) to transform all the collected data of the potentiometer to values so the LED lights can turn on. Finally with this same variable, (“brillo”), we can open the LEDs depending on the potentiometer.
Step 5: Guide: ACTION 2
ASSEMBLY
1. 854