Tuesday, July 26, 2016

Filled Under: , , , ,

Arduino Laser Tag Target System

Arduino UNO R3 Intermediate LDR LED project

This tutorial will show you how to construct a basic interactive laser-sensitive target, great for those just getting started with Arduino. This could easily be used as a platform for a laser tag system, or just something fun to play with! It might also drive your cat insane.





Step 1: What You Need?

1 x Blue LED 
4 x Red LED (you could always change the colors or use multicolored LEDs)
3 x Green LED

1 x Computer with Arduino IDE installed
1 x USB Type-B CableMale-to-Male Jumper Wires 

Arduino Uno R3 Acrylic Transparent Casing
Cable Cover
Arduino Compatible UNO Ultimate Starter Kit / Learning Kit
USB To Power Jack Cable



Don't have components? Don't worry. Just click the component's name. 


Step 2: Build Your Circuit.


I built this on a Maker Shield, but you could build this project on anything! This circuit is very straightforward. The four red LEDs are connected to pins 8,9,10,11; the three green LEDs are connected to 2,3,4; and the blue LED is connected to pin 12. (All LEDs are also connected to ground)





The sensor consists of a 5k potentiometer and a photo-resistor. The middle pin on the potentiometer is connected to ground on the Arduino and the other pin on the potentiometer is connected to analogue pin 0, or A0, on the Arduino. The photo-resistor is connected to +3.3 volts on the Arduino and to the A0 pin on the Arduino.

Your almost done!

Step 3: Upload Code To Board.

In it is the program for the Arduino. Now open the file in the Arduino IDE and upload it to your Arduino! Make sure you have the Arduino plugged in to your computer and make sure you have the newest version of Arduino. Once you have the program loaded onto the Arduino, the four red lights should blink on and off in sequence.




Step 4: Have Fun!


Now get a standard 5mw red laser pointer and try pointing it at the photo-resistor! The blue light should turn on and the three green lights should blink on as well. If nothing happens, try adjusting the potentiometer to increase or decrease sensitivity. You can change things in the Arduino program as well. If you are still having issues, let me know in the comments and I might be able to help you.

You could easily use this as a base for a laser tag system with a few modifications to the program. You could also re-program the Arduino to use the green and blue LEDs as a health bar or something. The possibilities are endless! But remember kids, DON'T POINT LASERS IN ANYONE'S EYES!

Unknown

Author & Editor

My Robot Education Sdn. Bhd. (Robotedu.my) was founded in 2015 as the first robotics education centre in Malaysia to provide Arduino-based robotics courses for youths. Our vision is to be able to provide robotics education to every youth in Malaysia.

0 comments:

Post a Comment

 

  • Copyright © Arduino Tutorial ™ is a registered trademark.
    Designed by Templateism. Hosted on Blogger Templates.