How To: Infrared Tag, Version 1.0

We are releasing a fun new experiment into the community on Saturday, May 2nd at the North Little Rock Mini Maker Faire.  This is version 1.0 and we hope that you enjoy it enough to help us revise and improve it over time.  At the moment we are calling it IR Tag, though we're open for suggestions of catchier names.

The basic point of IR Tag is to give us a fun little gadget we can use to bring our intangible community to life with. The idea is simple: buy a little kit, make a cool badge and switch it on while you roam around in the world. When another geek spots you they get to 'blast' you to light you up. If we wear them while we are out and about our friends and fellow geeks will be able to traverse longer distances with their hello (screw you "waving", we're in the 21st century now!). These devices make the connections in our community tangible.  Plus it's fun to see your friend realize their hit, scramble to find their blaster and hit you back.

Read on to see the kit basics and assemble your own.  We will have a few pre-assembled kits, and a few assemble it yourself kits for people to pickup during the NLR Mini Maker Faire.  If the response is good we will order up another round and offer them for sale prior to our upcoming workshop.

Check out the details on the workshop, where we will talk about how to customize and program your kit and be around to play with them while we scheme about how to make the game even better.

The kit is based around Adafruit's Tinket.  This tiny board is great because it can be programmed just like an Arduino, so any coding skills you build playing with this project will be applicable to future 'internet of things' projects you build on the versatile Arduino platform & devices.  If you make your kit the way we did it is pretty simple to take apart and reuse the Trinket in a future project.

Disclaimer: we're not experts or engineers. The Locals crew is just makers that love using technology to creatively engage the community, to inspire wonder, and because we're hackers by nature.  There are probably things we could have done better, but like we said - this is version 1. We are completely open to your input!!  If you have a kit, or decide to make one of these, please email shawn@laluchaspace.com with any suggestions or questions. 

A couple important notes: the Trinket requires you to install a special version of the Arduino IDE (program you use to program your device).  You can get it from Adafruit here.

What your kit includes:

  • (1) Trinket 3.3v Microcontroller 
  • (1) IR Receiver for grabbing IR signals
  • (2) RGB Fast Flashing Diffused LEDs  (these are pre-programmed to flash a certain color patter and can only be turned on or off like single color LEDs).  SOME KITS COME WITH SOLID COLOR LEDS, we mix it up based on the quantity of LEDs we have for various projects that are going on.
  • (1) Small vibrating disc to add the awesome buzz effect
  • (1) Coin cell battery holder 
  • (1) IR LED 

How you assemble it

There are a number of ways to assemble this, but we made our demo kits in a way that allowed us to use the breadboard headers even after it was all soldered together. We chose to do so in order to make it as easy as possible for people to make changes, experiment and augment their blaster.

We chose to make a little ground rail that runs down the middle of the board with a bit of the LED lead that we cut off from the positive side. It seems to work well, but there may be a sturdier or more effective method. To do as we did be sure all ground leads are pointing into the center of the Trinket and leave them to be soldered last. Save the positive leads you cut from the LEDs when you trim them.

Follow-up post on the way! After all the awesome conversations at Maker Faire we have some revisions on two preferred methods for building the kit in a way that lets you keep using your Trinket for other projects and requires minimal soldering.  We will be changing the design for our next round of kits that will be available soon (around May 15) and that we will discuss at the upcoming workshop (May 30). 

Solder headers to the board

(it is a great idea to put your components in a breadboard, if you have one, and test the Trinket, code and components prior to soldering them)

Solder resistors to the LEDs (+ lead)

Solder resistors to pins 3 & 4

Solder red lead of vibrating disc to pin 2

Solder IR Receiver left lead to pin 1 & right lead to 3.3v pin

Solder ground connections from IR Receiver, and LEDs to a ground rail (scrap) running the length of the board

Solder the blue lead of your vibrating disc to the ground rail

Solder the remaining scrap to connect the GND pin to the ground rail

Pictures of this version are on the way!!

Code

We created a sample sketch to help get you started.  To make it easy to read we have broken our code into functions with obvious names. This way you can move around, duplicate, or extend (longer delay) any function you would like. 

int buzzer = 2;
int led2 = 4;
int led1 = 3;
int ir = 1;

void setup() {
pinMode(buzzer, OUTPUT);
pinMode(led2, OUTPUT);
pinMode(led1, OUTPUT);
pinMode(ir, INPUT);
}

void ledOn() {

digitalWrite(led2, HIGH);
digitalWrite(led1, HIGH);
}

void ledOff() {
digitalWrite(led2, LOW);
digitalWrite(led1, LOW);
}
void buzz(){
digitalWrite(buzzer, HIGH);
delay(4000);
digitalWrite(buzzer, LOW);
}

void loop() {
while( !digitalRead(ir)){
ledOn();
buzz();
delay(8000);
ledOff()

}
}

Test it out!

Use any remote control.  One important note about this model: it just looks for infrared light. Since that is in sunlight we found that if we didn't have sugru or a case around an IR receiver it tended to see too much IR in bright sunlight.  Our friend Tony explained that other "laser tag" systems often have issues with bright sunny afternoons. For best result enjoy in the evening, or indoors during bright days.  You can use literally any remote control that is infrared, that means TV remotes, the remote that came with your Mac, whatever. Go for that junk drawer, feel free to get creative with the look of it (mod away!).

Build yourself a cool case: 3D Print one, use a (small) mint tin, try some Sugru, or show us some other creative fun way to do it that we haven't thought of!

Remember: when making a case or enclosure for most any project always leave yourself the ability to: change your batteries, get back to that USB port, and hit the reset button. Generally you want to be able to fix things if they go wrong after you have assembled it.

This is a work in project and we love doing things like this with all of you.  We look forward to seeing your creation. With a basic kit started we can all start to develop games that is deeper than just blinking lights. It seems like there is a great interest in playing with bluetooth and other connected boards, so we look forward to seeing you all experiment alongside us.   Post your work to our Facebook, or mention us on Twitter.  Get creative in code, in form, or even go wild and add a piezo or something!

 

Do you like this post?

Showing 1 reaction

published this page in Blog 2015-05-02 13:00:14 -0500