Introduction: Simple Door Prank With Arduino 1Sheeld
This instructable shows how to make a simple door prank using an arduino board and 1Sheeld.
All you need to make this prank: Arduino board, Android phone, Ultrasonic sensor.
Feel free to ask any questions in the comments and I'll answer them as best i can. Video below shows the final result:
Step 1: What You Need
Arduino Uno or Mega.
Ultrasonic sensor hc-sr04
Android Phone (or IOS).
3 x Connection Wires.
1 x Breadboard.
1- The Arduino IDE which you can download here
2- Get the 1sheeld Arduino library and the phone app here
Step 2: Wiring and Setup
1.mount the 1sheeld on the Arduino board
2.Make sure the power switch shown above is turned to 5V (for Arduino UNO users) if you're using another Arduino board check here
3.Connect the ultrasonic sensor and the wires as shown in the figure.
Step 3: Software
Simply, the code opens the mp3 file that is selected from the media player sheeld in the 1Sheeld app and that happens only when any object is 25 cm or less in front of the ultrasonic sensor (you can change the distance as you like).
Upload the attached code and lets move to the next step.
Use your 1Sheeld Mobile App (Media Player Shield) to get the signal from the ultrasonic sensor to open the mp3 file.
PS: make sure the 1sheeld is in upload mode as seen in the image above.
Step 4: Putting It All Together
After connecting all components as shown.
Connect the Arduino to your laptop and make sure the code is uploaded.
Switch the 1Sheeld back to operating mode.
Open your 1Sheeld app and connect your phone to your 1Sheeld board.
(Check 1Sheeld tutorial here if you haven't already).
Select Media Player Shield, and press on the multiple shields icon at the top right of the app.
Now, put your circuit and your mobile phone in a hidden place and enjoy your prank.
feel free to ask any questions in the comments and I'll answer them as best i can.