Arduino Lasertag Project

Introduction: Arduino Lasertag Project

Hello there! Today I'll be explaining how I made a Arduino lasertag gun for a project at the HKU School of Arts at Utrecht, The Netherlands.

Teacher Notes

Teachers! Did you use this instructable in your classroom?
Add a Teacher Note to share how you incorporated it into your lesson.

Step 1: Get Yourself an Arduino and Some Infrared Leds and Sensors (plus Some More Stuff).

Step 1.

I started this project by buying some Infrared LED's and and Infrared Sensor that function at 33khz (you can use 38khz aswell). Most lasertag guns use infrared to send data, as it is much more reliable to send data with. With infrared you won't have any interference from other lightsources such as the sun.

For this project I used:

  • a Piezo buzzer.
  • a simple button component..
  • a 128x64 adafruit lcd screen.
  • a red led light for visual feedback.
  • a laser diode module (laserpointer).
  • a infrared led (33khz).
  • a infrared receiver (33khz).
  • some transistors and gauge wires.
  • a soldering iron and some lead.
  • sticky tape.
  • a glue gun.
  • a Arduino Uno and a Usb B cable.

I used the Adafruit SSD1306 monochrome 128x64 OLED Display for showing stats on the gun.

The first thing I did was to make a basic setup for my lightgun (see pictures).

Step 2: Use This Code for the Gun.

NOTE

This code requires the Arduino library for SSD1306 monochrome 128x64 and 128x32 OLEDs as this was the screen I used for the gun.

https://github.com/adafruit/Adafruit_SSD1306

Step 3: Take That Dusty Old Nerf Gun Out of Your Drawer (or Buy One).

After I got my software and hardware to work I used old Nerf gun I had lying around to function as the housing of the Arduino and it's hardware.

Step 4: Modify the Nerf Gun.

After I dusted of the gun, I took it apart and had a look inside. I planned out where the different parts of the gun would come and where I would place the Arduino Uno.

I took out all the lose parts and the old firing mechanism and painted the gun. After this I made some modifications on the inside so I could fit the arduino inside the old magazine chamber of the gun.

Step 5: Solder Your Components and Glue Them Into the Gun.

After I modified and painted the gun it was time for me to solder all my components to seperate breadboards. Shortly after that, I glued them into the gun and I was ready to go test it!

Step 6: Tadaa!

Eventually the lasertag gun turned out like this. You can shoot, receive and decode IR messages with the code. Whilst everything is connected in a neatly modified nerf gun. Just connect the powerbank to the arduino and you are ready to go :)

Be the First to Share

    Recommendations

    • Backyard Contest

      Backyard Contest
    • Finish It Already Speed Challenge

      Finish It Already Speed Challenge
    • First Time Author Contest

      First Time Author Contest

    9 Discussions

    0
    designer20055234
    designer20055234

    Question 2 months ago on Step 6

    error in code .it is saying
    exit status 1
    expected unqualified-id before '<' token

    1
    TimP196
    TimP196

    Reply 4 weeks ago

    Hey! I finally got around to uploading the original file I used for the gun. Which propably fixes the error you are having.

    0
    designer20055234
    designer20055234

    Reply 4 weeks ago

    thank you is there any way to increase the range.

    1
    Rocket Builder
    Rocket Builder

    Question 2 months ago

    I wanted to know that what would be the range of it? I'm using a 100mA IR LED with 1.1-1.4 V forward current.

    0
    TimP196
    TimP196

    Reply 4 weeks ago

    Hi, the range I had on my IR led's whas around 10 meters when in good lighting conditions (without to much interference). It really depends on what environment you are in, because a lot of interference from e.g. the sun made the gun work around only 5 meters in my case. I can't remember the exact specifications of the led I used, but the range is not extremely far I'm afraid.

    0
    TimP196
    TimP196

    4 weeks ago

    Update 24-4-2020
    I uploaded the original sourcecode .ino file, as the code I posted was poorly pasted and contained errors.

    This code requires the Arduino library for SSD1306 monochrome 128x64 and 128x32 OLEDs as this was the screen I used for the gun.

    https://github.com/adafruit/Adafruit_SSD1306

    0
    Barathsundar
    Barathsundar

    5 months ago

    How to connect adafruit screen to the circuit?

    This awesome! With the Arduino you can make all kinds of interactive systems to go along with the game.