Introduction: Computer Prank With Arduino
This is an instructable to make a crappy robot that turns off your laptop when you go in front of it and just to piss you off turns it on when you go away.
Step 1: Materials Needed
To make this robot you will need :
- Arduino board
- an ultrasonic sensor
- a servo motor for Arduino
- Masking tape
- a computer
- a breadboard
Step 2: Wiring the Ultrasonic Sensor
- Insert the ultrasonic sensor into the breadboard.
- Connect the trig pin to digital port 8 and the echo pin to port 7.
- Connect the 5V to the 5V line in the breadboard and the GND to the GND line in the breadboard.
- Connect these two lines to the board (5V to 5V and GND to GND).
Step 3: Wiring the Servo Motor
Connect the servo motors three wires to the 5V on the breadboard, GND on the breadboard and digital port 9 respectively.
Step 4: Setting the Robot Up
- Tape the motor to the computer such that the motor will be able to push the power button.
- The end of the motor should be facing the screen of the laptop.
- Place the ultrasonic sensor facing where you expect a person to be standing when he is trying to work on the computer (like in the picture).
Step 5: The Code
Step 6: Final Step
Upload the code to the board and you should have your own crappy robot.