The Arduino Internet Gizmo
by talk2bruce in Circuits > Arduino
31731 Views, 94 Favorites, 0 Comments
The Arduino Internet Gizmo
![0 - 1 - Arduino Internet Gizmo.JPG](/proxy/?url=https://content.instructables.com/FAU/MY0R/H19RHIH1/FAUMY0RH19RHIH1.jpg&filename=0 - 1 - Arduino Internet Gizmo.JPG)
The Arduino Internet Gizmo is a USB, Arduino, and RFID device for web surfing. The gizmo works by placing an RFID tag on the top of the gizmo. The gizmo reads the RFID tag and sends the tag number via USB to a program running on a PC. The program looks up the tag number and the associated web site and then invokes the default web browser to open a new tab for the web site. The gizmo consists of an Arduino Uno, a Parallax serial RFID tag reader, an assortment of LEDs, and a few other parts packaged inside a ATX power supply case recycled from an old PC. The software components of the gizmo consist of a small program running on the Arduino and a small Python program running on the PC or laptop.
The Arduino Internet Gizmo is fun to use and makes an excellent desk toy and sure beats using a mouse and keyboard to load your favorite web sites.
This video demonstrates the Arduino Internet Gizmo:
The Arduino Internet Gizmo is fun to use and makes an excellent desk toy and sure beats using a mouse and keyboard to load your favorite web sites.
This video demonstrates the Arduino Internet Gizmo:
How It Works
![1 - 1 - Arduino Internet Gizmo Overview.png](/proxy/?url=https://content.instructables.com/FMN/BLE9/H1JUDZO7/FMNBLE9H1JUDZO7.png&filename=1 - 1 - Arduino Internet Gizmo Overview.png)
![1 - 2 - Arduino Internet Gizmo.png](/proxy/?url=https://content.instructables.com/FUF/HX5I/H1JUGIS4/FUFHX5IH1JUGIS4.png&filename=1 - 2 - Arduino Internet Gizmo.png)
![1 - 3 - Arduino Internet Gizmo Unknown Tag.png](/proxy/?url=https://content.instructables.com/FC8/82SU/H1KH9BXQ/FC882SUH1KH9BXQ.png&filename=1 - 3 - Arduino Internet Gizmo Unknown Tag.png)
The Arduino Internet Gizmo consists of an Arduino, a RFID card reader, a bunch of LEDs and other components mounted in a recycled PC power supply case connected to a PC as shown in the first diagram. The Arduino is running software that will read an RFID card when it is placed near the reader. When a card is read, the Arduino makes the LEDs on the top of the gizmo light up in sequence and appear to race around in circles. The RFID card's ID is then sent to the PC via a USB cable that connects the Arduino and the PC. On the PC, a Python program is running in a loop waiting for data from the Arduino. When it receives the RFID card id from the Arduino, it looks up the RFID card ID in a table to see what web site is associated with that card. If it finds the card in the table, it opens a new tab in the default web browser for the computer and loads the web site. If the RFID card ID is not in the table, the Python program creates a simple HTML page with an error message and the RFID card ID and displays the information in a new tab in the browser (as shown in the third image). When the Arduino Internet Gizmo is powered on, it illuminates a set of red-green-blue color changing LEDs to indicate that the gizmo is operational.
The second figure and the attached PDF file show the circuit schematic for the Arduino Internet Gizmo. The RFID card reader is connected the Arduino pins 3 and 4. Pin 3 is used for sending the RFID card data to the Arduino and pin 4 is used to enable or disable reading. Arduino pins 6 - 13 are used to control the illumination of the LEDs on top of the gizmo. Arduino pin 5 is used to turn on the red-green-blue LED color changing circuit. Pin 5 connects to an optocoupler that turns the color changing LED circuit on and off. I used the optocoupler circuit rather than connect the color changing LEDs directly to the Arduino because the color changing LEDs draw varying amounts of current as they change color and with five of them, I wasn't sure what effect that would have on the Arduino, so I felt it was better to use the optocoupler and power the color changing LEDs independently.
Details on how the software works is covered in step 20.
More information on how the RFID card reader works can be found in the data sheet for the Parallax serial RFID card reader.
The second figure and the attached PDF file show the circuit schematic for the Arduino Internet Gizmo. The RFID card reader is connected the Arduino pins 3 and 4. Pin 3 is used for sending the RFID card data to the Arduino and pin 4 is used to enable or disable reading. Arduino pins 6 - 13 are used to control the illumination of the LEDs on top of the gizmo. Arduino pin 5 is used to turn on the red-green-blue LED color changing circuit. Pin 5 connects to an optocoupler that turns the color changing LED circuit on and off. I used the optocoupler circuit rather than connect the color changing LEDs directly to the Arduino because the color changing LEDs draw varying amounts of current as they change color and with five of them, I wasn't sure what effect that would have on the Arduino, so I felt it was better to use the optocoupler and power the color changing LEDs independently.
Details on how the software works is covered in step 20.
More information on how the RFID card reader works can be found in the data sheet for the Parallax serial RFID card reader.
Downloads
Prepare the Case
![2 - 1 - Prepare Power Supply Case.JPG](/proxy/?url=https://content.instructables.com/F1X/AQIJ/H1AH6VKG/F1XAQIJH1AH6VKG.jpg&filename=2 - 1 - Prepare Power Supply Case.JPG)
![2 - 2 - Prepare Power Supply Case.JPG](/proxy/?url=https://content.instructables.com/FUJ/ST5E/H19RT4R2/FUJST5EH19RT4R2.jpg&filename=2 - 2 - Prepare Power Supply Case.JPG)
![2 - 3 - Prepare Power Supply Case.JPG](/proxy/?url=https://content.instructables.com/FRH/9EWK/H19RHIHT/FRH9EWKH19RHIHT.jpg&filename=2 - 3 - Prepare Power Supply Case.JPG)
![2 - 4 - Prepare Power Supply Case.JPG](/proxy/?url=https://content.instructables.com/F9F/NG58/H19RQX4W/F9FNG58H19RQX4W.jpg&filename=2 - 4 - Prepare Power Supply Case.JPG)
![2 - 5 - Prepare Power Supply Case.JPG](/proxy/?url=https://content.instructables.com/F5P/IAK6/H1AH6HR7/F5PIAK6H1AH6HR7.jpg&filename=2 - 5 - Prepare Power Supply Case.JPG)
In this step, we will prepare the case for the Arduino Internet Gizmo. You will need the following for this step:
- Power supply from a PC (I used a non-working ATX power supply)
- Screwdrivers
- Wire cutters
- Goo Gone (or similar solvent to remove adhesive)
- 4 Vinyl bumpers (rubber feet)
- Remove the screws holding the power supply case together as shown in the second photo. Save these screws: you'll need them to put the case back together.
- Remove all of the guts from the power supply as shown in the third photo. You'll need to remove screws and cuts wires to get everything out. Save the parts for some future project (there's a wealth of good stuff inside the power supply) or responsibly dispose of the innards as e-waste.
- Remove all the labels and stickers on the outside of the case. I found that my finger nails did the best to scrape them off without scratching the case. Use Goo-Gone or a similar product to remove any remaining adhesive.
- Apply the vinyl bumpers to the bottom of the case (see fourth and fifth photos).
Assemble the Color Changing LED Circuit
![3 - 1 - Assemble RGB LED Circuit.JPG](/proxy/?url=https://content.instructables.com/FE4/0LXV/H19RQXDS/FE40LXVH19RQXDS.jpg&filename=3 - 1 - Assemble RGB LED Circuit.JPG)
![3 - 2 - Assemble RGB LED Circuit.JPG](/proxy/?url=https://content.instructables.com/F32/XDQZ/H19RQXDU/F32XDQZH19RQXDU.jpg&filename=3 - 2 - Assemble RGB LED Circuit.JPG)
![3 - 3 - Assemble RGB LED Circuit.JPG](/proxy/?url=https://content.instructables.com/FDB/6738/H19RHIKL/FDB6738H19RHIKL.jpg&filename=3 - 3 - Assemble RGB LED Circuit.JPG)
![3 - 4 - Assemble RGB LED Circuit.JPG](/proxy/?url=https://content.instructables.com/FLV/BS7W/H19RT583/FLVBS7WH19RT583.jpg&filename=3 - 4 - Assemble RGB LED Circuit.JPG)
![3 - 5 - Assemble RGB LED Circuit.JPG](/proxy/?url=https://content.instructables.com/FJ4/A1RE/H1AH6HUS/FJ4A1REH1AH6HUS.jpg&filename=3 - 5 - Assemble RGB LED Circuit.JPG)
![3 - 6 - Assemble RGB LED Circuit.JPG](/proxy/?url=https://content.instructables.com/FSU/TQMJ/H1AH6HUT/FSUTQMJH1AH6HUT.jpg&filename=3 - 6 - Assemble RGB LED Circuit.JPG)
![3 - 7 - Assemble RGB LED Circuit.JPG](/proxy/?url=https://content.instructables.com/FLI/D6Z6/H19RV5N7/FLID6Z6H19RV5N7.jpg&filename=3 - 7 - Assemble RGB LED Circuit.JPG)
![3 - 8 - Assemble RGB LED Circuit.JPG](/proxy/?url=https://content.instructables.com/FZT/H52O/H1AH6VSI/FZTH52OH1AH6VSI.jpg&filename=3 - 8 - Assemble RGB LED Circuit.JPG)
![3 - 9 - Assemble RGB LED Circuit.JPG](/proxy/?url=https://content.instructables.com/F08/4I2W/H19RV5N8/F084I2WH19RV5N8.jpg&filename=3 - 9 - Assemble RGB LED Circuit.JPG)
![3 - 10 - Assemble RGB LED Circuit.JPG](/proxy/?url=https://content.instructables.com/FSF/7XFY/H19RQXE7/FSF7XFYH19RQXE7.jpg&filename=3 - 10 - Assemble RGB LED Circuit.JPG)
![3 - 11 - Assemble RGB LED Circuit.JPG](/proxy/?url=https://content.instructables.com/FDJ/07BH/H1AH6HUY/FDJ07BHH1AH6HUY.jpg&filename=3 - 11 - Assemble RGB LED Circuit.JPG)
![3 - 12 - Assemble RGB LED Circuit.JPG](/proxy/?url=https://content.instructables.com/FJ4/AD8A/H19RT58H/FJ4AD8AH19RT58H.jpg&filename=3 - 12 - Assemble RGB LED Circuit.JPG)
![3 - 13 - Assemble RGB LED Circuit.JPG](/proxy/?url=https://content.instructables.com/F9J/K0W1/H19RT58I/F9JK0W1H19RT58I.jpg&filename=3 - 13 - Assemble RGB LED Circuit.JPG)
![3 - 14 - Assemble RGB LED Circuit.JPG](/proxy/?url=https://content.instructables.com/FAU/Z1MW/H1AH6HV6/FAUZ1MWH1AH6HV6.jpg&filename=3 - 14 - Assemble RGB LED Circuit.JPG)
In this step, we will assemble the color changing LED circuit. This circuit is "on" whenever the Arduino Internet Gizmo is powered on and operational. It's purpose is decorative and to make the gizmo look cool! You will need the following parts and tools for this step:
- 5 Red-Green-Blue color changing LEDs (You probably won't find these in your local electronics store. If you search on eBay for "5mm led rainbow rgb" you'll find them. They cost approximately $13 for 100.)
- 5 100 ohm 1/4 watt resistors (Radio Shack 271-1311)
- 1 4-Pin Lite-On LTV-817 Optocoupler (Jameco part number 878243)
- Screw terminal (Jameco part number 2094485)
- Adafruit Perma-Proto Quarter-Sized Breadboard Printed Circuit Board (part number 589)
- 4 1/4" Round nylon #4 spacers
- Wire
- Soldering iron and solder
- Wire strippers and wire cutters
- Solder the resistors and jumper wires as shown in the first photo. Use the labels for the pins in the photo as a guide to make sure you're placing everything correctly (note: the numbers 1 to 15 along the top and A to J along the sides)
- Solder the optocoupler as shown in the second photo. The alignment of the chip is critical: the round dot on the chip indicating "pin 1" should be in the lower left hand corner (hole E2)
- Bend the LED wires as shown the third photo.
- Solder three of the LEDs as shown in the fourth and fifth photo. Note that the longer lead on the LED (the positive side) goes in the hole in the same column as the orange wires (6, 10, 14).
- Put two nylon spacers on each of the LEDs leads as shown in the sixth and seventh photos.
- Solder the LEDs to the circuit board as shown in the eighth, ninth, and tenth photos. Note that the longer (positive) LED lead goes into the holes in the same columns as the orange wires (8 and 12).
- Solder the screw terminal to the circuit board as shown in the eleventh photo (note: this photo shows a red and black wire attached the the circuit board - you don't need to attach anything there in this step - I had those attached so I could test the board).
Assemble USB Power Cord for Color Changing Circuit
![4 - 1 - Assemble RBG Power Cable.JPG](/proxy/?url=https://content.instructables.com/FTG/X4FU/H19RQXHX/FTGX4FUH19RQXHX.jpg&filename=4 - 1 - Assemble RBG Power Cable.JPG)
![4 - 2 - Assemble RBG Power Cable.JPG](/proxy/?url=https://content.instructables.com/FT0/JCQE/H1AH6HX8/FT0JCQEH1AH6HX8.jpg&filename=4 - 2 - Assemble RBG Power Cable.JPG)
![4 - 3 - Assemble RGB Power Cable.JPG](/proxy/?url=https://content.instructables.com/F9R/0BW7/H19RV5V5/F9R0BW7H19RV5V5.jpg&filename=4 - 3 - Assemble RGB Power Cable.JPG)
![4 - 7 - Assemble RBG Power Cable.JPG](/proxy/?url=https://content.instructables.com/FJ1/3CX6/H19RT5MV/FJ13CX6H19RT5MV.jpg&filename=4 - 7 - Assemble RBG Power Cable.JPG)
![4 - 8 - Assemble RBG Power Cable.JPG](/proxy/?url=https://content.instructables.com/FBX/8N5A/H1AH6HXG/FBX8N5AH1AH6HXG.jpg&filename=4 - 8 - Assemble RBG Power Cable.JPG)
![4 - 9 - Assemble RGB Power Cable.JPG](/proxy/?url=https://content.instructables.com/FIW/7APT/H19RQXHU/FIW7APTH19RQXHU.jpg&filename=4 - 9 - Assemble RGB Power Cable.JPG)
![4 - 10 - Assemble RGB Power Cable.JPG](/proxy/?url=https://content.instructables.com/FVU/WX0M/H1AH6N2P/FVUWX0MH1AH6N2P.jpg&filename=4 - 10 - Assemble RGB Power Cable.JPG)
The color changing LED circuit is powered separately from the Arduino: the power comes from a USB-AC adapter. In this step, we will construct the power cable. You will need the following parts and tools for this step:
- USB Cable with a type A connector on one end
- USB Power Adapter
- Soldering iron and solder
- Wire strippers/cutters
- Knife
- Cut off the non-type A connector as shown in the first photo.
- Using a knife, gently cut off about a quarter inch of the outer insulation as shown in the second photo.
- Cut off the outer wire braid and then strip the ends of the red and black (power) wires as shown in the third photo.
- Cut off the green and white (data) wires as shown in the fourth photo.
- Solder the red and black wires to the circuit board as shown in the fifth and sixth photos.
- Attach your USB power adapter to the end of the USB cable (see last photo). I used an Apple USB power adapter because of it's small size.
Cut Acrylic for the Two Inner Platforms
![5 - 1 - Bottom Platform.JPG](/proxy/?url=https://content.instructables.com/F43/DBOB/H1AH6WGM/F43DBOBH1AH6WGM.jpg&filename=5 - 1 - Bottom Platform.JPG)
![5 - 2 - Bottom Platform.JPG](/proxy/?url=https://content.instructables.com/FTO/EQM4/H1AH6I3N/FTOEQM4H1AH6I3N.jpg&filename=5 - 2 - Bottom Platform.JPG)
![5 - 3 - Top Platform.JPG](/proxy/?url=https://content.instructables.com/FVW/HK2H/H19RQY0D/FVWHK2HH19RQY0D.jpg&filename=5 - 3 - Top Platform.JPG)
![5 - 4 - Top Platform.JPG](/proxy/?url=https://content.instructables.com/F82/YVE0/H19RV5Z6/F82YVE0H19RV5Z6.jpg&filename=5 - 4 - Top Platform.JPG)
In this step, we will cut the acrylic for two platforms that hold all of the electronic components. The upper platform holds the RFID card reader and the top LEDs. The lower platform holds the Arduino, the color changing LED circuit, and a terminal strip for all the ground connections. The design for the lower platform includes some engraving to mark where the components are placed.
You will need the following parts and tools for this step:
Attached to this step are PDF files with the designs for those that do not have software that can open CorelDraw files.
Use the laser cutter to cut the platforms. "Lower Platform v10.cdr" and "Upper Platform v10.cdr" are used to cut the lower and upper platforms, respectively. I used a 60 watt Epilog Helix laser cutter and used these settings:
Important note: Different brand power supplies have their mounting holes and cutouts in different places: you may need to tweak the designs for the mounting platforms to match the case you have.
You will need the following parts and tools for this step:
- Two 6" x 6" sheets of 1/8" thick acrylic. I used transparent blue for the upper platform and fluorescent transparent red for the lower platform.
- CorelDraw, Adobe Illustrator, or similar software if you need to modify the design to fit your power supply case.
- Epilog Laser Cutter
Attached to this step are PDF files with the designs for those that do not have software that can open CorelDraw files.
Use the laser cutter to cut the platforms. "Lower Platform v10.cdr" and "Upper Platform v10.cdr" are used to cut the lower and upper platforms, respectively. I used a 60 watt Epilog Helix laser cutter and used these settings:
- Vector: Speed 10, Power 90, Frequency 2500
- Engrave: Speed 50, Power 80
Important note: Different brand power supplies have their mounting holes and cutouts in different places: you may need to tweak the designs for the mounting platforms to match the case you have.
Contruct and Mount Terminal Strip for Ground Connections
![6 - 1 - Ground Bus.JPG](/proxy/?url=https://content.instructables.com/F4K/UKPM/H1AH6WI7/F4KUKPMH1AH6WI7.jpg&filename=6 - 1 - Ground Bus.JPG)
![6 - 2 - Ground Bus.JPG](/proxy/?url=https://content.instructables.com/FZ6/BAL2/H1AH6I44/FZ6BAL2H1AH6I44.jpg&filename=6 - 2 - Ground Bus.JPG)
![6 - 3 - Ground Bus.JPG](/proxy/?url=https://content.instructables.com/FXU/8ZOT/H1AH6I54/FXU8ZOTH1AH6I54.jpg&filename=6 - 3 - Ground Bus.JPG)
![6 - 4 - Ground Bus.JPG](/proxy/?url=https://content.instructables.com/FKR/SQE2/H19RV5ZL/FKRSQE2H19RV5ZL.jpg&filename=6 - 4 - Ground Bus.JPG)
![6 - 5 - Ground Bus.JPG](/proxy/?url=https://content.instructables.com/FR6/2DIV/H19RT654/FR62DIVH19RT654.jpg&filename=6 - 5 - Ground Bus.JPG)
As you can see in the schematic for the Arduino Internet Gizmo, there are many parts that need to connect to "ground." There are more parts to connect to ground than there are ground pins on the Arduino. To deal with this, most of the ground wires will connect to a terminal strip and the terminal strip will connect to one of the Arduino ground pins. In this step, we will assemble the terminal strip and mount it to the lower platform.
You will need the following parts and tools for this step:
You will need the following parts and tools for this step:
- 4-Position Dual Row Barrier Strip (Radio Shack part number 274-658)
- Two #6-32 x 1/2" Round head machine Screws
- Two #6-32 Nuts
- 4" of solid core wire (I used #24 AWG)
- Wire strippers/cutters
- Screw driver
- Small pliers
- Strip all the insulation off the wire as shown in the second photo.
- Bend the wire around all the screws on one side of the terminal strip and tighten the screws as shown in the third photo. This wire connects all the terminals together electrically.
- Place the terminal strip on lower platform as shown in the last two figures. Keep the side with the wire aligned towards the inside. This will make it easier for you to attach all the ground wires to the strip in a later step.
- Gently tighten the screws with the screw driver and pliers but be very careful not to over-tighten and crack the acrylic.
Mount the Arduino to the Lower Platform
![7 - 0 - Mount Arduino.JPG](/proxy/?url=https://content.instructables.com/F6L/9YLI/H1AH6I5D/F6L9YLIH1AH6I5D.jpg&filename=7 - 0 - Mount Arduino.JPG)
![7 - 1 - Mount Arduino.JPG](/proxy/?url=https://content.instructables.com/F2D/4Z0O/H1AH6WPA/F2D4Z0OH1AH6WPA.jpg&filename=7 - 1 - Mount Arduino.JPG)
![7 - 2 - Mount Arduino.JPG](/proxy/?url=https://content.instructables.com/FUY/QJKS/H19RT69T/FUYQJKSH19RT69T.jpg&filename=7 - 2 - Mount Arduino.JPG)
![7 - 3 - Mount Arduino.JPG](/proxy/?url=https://content.instructables.com/FDQ/BTZ7/H19RT69W/FDQBTZ7H19RT69W.jpg&filename=7 - 3 - Mount Arduino.JPG)
In this step, we will mount the Arduino to the lower platform. You will need the following parts and tools:
- Arduino (I used an Arduino Uno)
- Screwshield kit for Arduino (Solarbotics part number 51865)
- Four 1/4" round nylon #4 spacers.
- Four #4-40 x 3/4" machine screws
- Four #4-40 nuts
- Screwdriver
- Small pliers
- Soldering iron and solder (needed to assemble the ScrewShield)
- Mount the Arduino to the board using the machine screws, nylon spacers, and nuts as shown in the second and third photos. Gently tighten the screws using the screwdriver while holding the nuts with pliers. Do not over-tightened or the acrylic will crack.
- Assemble the ScrewShield according to the instructions that come with the kit.
- Attach the ScrewShield to the Arduino as shown in last photo. It's important to use the ScrewShield and not insert all the connecting the wires into the connector strips on the Arduino: using the ScrewShield for connecting all the wires to the Arduino will ensure that all connections are held tight and will not come undone after you've assembled the gizmo.
Mount the Color Changing LED Circuit to the Lower Platform
![8 - 0 - Mount RGB LED PCB.JPG](/proxy/?url=https://content.instructables.com/FO9/2E7G/H19RQY6G/FO92E7GH19RQY6G.jpg&filename=8 - 0 - Mount RGB LED PCB.JPG)
![8 - 1 - Mount RGB LED PCB.JPG](/proxy/?url=https://content.instructables.com/F4N/VGU4/H1AH6WQM/F4NVGU4H1AH6WQM.jpg&filename=8 - 1 - Mount RGB LED PCB.JPG)
![8 - 2 - Mount RGB LED PCB.JPG](/proxy/?url=https://content.instructables.com/F2V/TX6G/H19RT6C2/F2VTX6GH19RT6C2.jpg&filename=8 - 2 - Mount RGB LED PCB.JPG)
![8 - 3 - Mount RGB LED PCB.JPG](/proxy/?url=https://content.instructables.com/FTX/80LO/H19RV64L/FTX80LOH19RV64L.jpg&filename=8 - 3 - Mount RGB LED PCB.JPG)
In this step we will attach the color changing LED circuit board to the lower platform. In addition to the circuit board, you will need:
- #4-40 x 3/4" Round head machine screw
- #4-40 Nut
- 1/4" Round nylon #4 spacer
- 7" solid core black wire (I used #24 AWG)
- 4.5" solid core green wire (I used #24 AWG)
- Wire strippers/cutters
- Screwdriver
- Small pliers
- Attach the board to the lower platform as shown in the second and third photos. Only one screw is needed to hold the board in position. Gently tighten the screw and nut using the screwdriver and pliers. To avoid cracking the acrylic do not over tighten.
- Strip the ends of both wires.
- Attach one end of the green and black wires to the color changing LED circuit as shown in the fourth photo.
- Connect the other end of the black wire to the terminal strip and the other end of the green wire to pin 5 on the Arduino ScrewShield also shown in the fourth photo.
Assemble LEDs for Upper Platform
![9 - 1 - Assemble Top LEDs.JPG](/proxy/?url=https://content.instructables.com/FP2/MWIN/H1AH6I7T/FP2MWINH1AH6I7T.jpg&filename=9 - 1 - Assemble Top LEDs.JPG)
![9 - 2 - Assemble Top LEDs.JPG](/proxy/?url=https://content.instructables.com/F88/KOM0/H19RV68Q/F88KOM0H19RV68Q.jpg&filename=9 - 2 - Assemble Top LEDs.JPG)
![9 - 3 - Assemble Top LEDs.JPG](/proxy/?url=https://content.instructables.com/F5W/WF23/H19RV68S/F5WWF23H19RV68S.jpg&filename=9 - 3 - Assemble Top LEDs.JPG)
![9 - 4 - Assemble Top LEDs.JPG](/proxy/?url=https://content.instructables.com/FH9/LA0F/H19RT6FC/FH9LA0FH19RT6FC.jpg&filename=9 - 4 - Assemble Top LEDs.JPG)
![9 - 5 - Assemble Top LEDs.JPG](/proxy/?url=https://content.instructables.com/F8B/JRTF/H19RQY8J/F8BJRTFH19RQY8J.jpg&filename=9 - 5 - Assemble Top LEDs.JPG)
![9 - 6 - Assemble Top LEDs.JPG](/proxy/?url=https://content.instructables.com/FWS/XFVU/H19RV6NH/FWSXFVUH19RV6NH.jpg&filename=9 - 6 - Assemble Top LEDs.JPG)
![9 - 7 - Assemble Top LEDs.JPG](/proxy/?url=https://content.instructables.com/FZL/LDIX/H1AH6WVW/FZLLDIXH1AH6WVW.jpg&filename=9 - 7 - Assemble Top LEDs.JPG)
![9 - 8 - Assemble Top LEDs.JPG](/proxy/?url=https://content.instructables.com/FWC/K5I5/H19RV6NK/FWCK5I5H19RV6NK.jpg&filename=9 - 8 - Assemble Top LEDs.JPG)
![9 - 9 - Assemble Top LEDs.JPG](/proxy/?url=https://content.instructables.com/FI8/QI6A/H1AH6WW0/FI8QI6AH1AH6WW0.jpg&filename=9 - 9 - Assemble Top LEDs.JPG)
![9 - 10 - Assemble Top LEDs.JPG](/proxy/?url=https://content.instructables.com/FPN/2RS5/H19RHIX9/FPN2RS5H19RHIX9.jpg&filename=9 - 10 - Assemble Top LEDs.JPG)
![9 - 11 - Assemble Top LEDs.JPG](/proxy/?url=https://content.instructables.com/FAI/3QUA/H1AH6I8R/FAI3QUAH1AH6I8R.jpg&filename=9 - 11 - Assemble Top LEDs.JPG)
There are eight large red LEDs on the upper platform that race around in circles when an RFID tag is read. In this step you will attach the LEDs to their current limiting resistors and long wires that in an upcoming step will be attached to the Arduino and Terminal Strip. You will need the following parts and tools for this step:
- 6" 3/32" black heat shrink tubing
- 6" 1/16" blue heat shrink tubing
- 8 360 ohm 1/4 watt resistors (Radio Shack part 271-1315)
- 8 Large red LEDs (T2-1/2 LHR3930 Jameco part 119634)
- 8 6" lengths of thin black stranded wire (I used #26 AWG)
- 8 6" lengths of thin blue stranded wire (I used #26 AWG)
- Wire cutters/strippers
- Soldering iron and solder
- Heat gun or other source of directed heat
-
For the blue wires:
- Strip approximately 1/4" of insulation off one end of each wire. Using the soldering iron and solder, tin the end of the wire. This will make it easier to insert the wire into the ScrewShield.
- Strip 1/2" of insulation off of the other end - do not tin this end.
-
For the black wires:
- Strip 1/2" of insulation off both ends. Tin one end and leave the other end as is.
- Wrap the untinned end of the black wire around the resistor as shown in the first photo.
- Solder the black wire to the resistor and the resistor to shorter lead on one of the LEDs. Cut off excess wire from the resistor. See the second and third photos.
- Cut a length of black heat shrink tubing that will cover the exposed wire and resistor. Slip the tubing onto the wire and cover the exposed areas as shown in the fourth and fifth photos.
- Apply heat using a heat gun or other source of heat to the tubing to shrink it around the wire and resistor as shown in the sixth photo.
- Wrap the untinned end of the blue wire around the long lead on the LED as shown in the seventh photo.
- Solder the wire to the LED as shown in the eighth photo.
- Cut a length of blue heat shrink tubing sufficient to cover the exposed wire as shown in the ninth photo.
- Slip the heat shrink tubing onto the wire (see tenth photo) and apply heat to shrink the tubing as shown in the eleventh photo.
Glue LEDs to Upper Platform
![10 - 1 - Install Top LEDs.JPG](/proxy/?url=https://content.instructables.com/F7Q/3HP5/H19RV6TE/F7Q3HP5H19RV6TE.jpg&filename=10 - 1 - Install Top LEDs.JPG)
![10 - 2 - Install Top LEDs.JPG](/proxy/?url=https://content.instructables.com/F1K/V4AO/H19RHJ1U/F1KV4AOH19RHJ1U.jpg&filename=10 - 2 - Install Top LEDs.JPG)
![10 - 3 - Install Top LEDs.JPG](/proxy/?url=https://content.instructables.com/FZM/5FPL/H19RT6O6/FZM5FPLH19RT6O6.jpg&filename=10 - 3 - Install Top LEDs.JPG)
![10 - 4 - Install Top LEDs.JPG](/proxy/?url=https://content.instructables.com/FJL/KS2T/H19RHJ1X/FJLKS2TH19RHJ1X.jpg&filename=10 - 4 - Install Top LEDs.JPG)
![10 - 5 - Install Top LEDs.JPG](/proxy/?url=https://content.instructables.com/F58/DG24/H19RV6TI/F58DG24H19RV6TI.jpg&filename=10 - 5 - Install Top LEDs.JPG)
![10 - 6 - Install Top LEDs.JPG](/proxy/?url=https://content.instructables.com/FCM/YRGP/H19RHJ1Z/FCMYRGPH19RHJ1Z.jpg&filename=10 - 6 - Install Top LEDs.JPG)
![10 - 7 - Install Top LEDs.JPG](/proxy/?url=https://content.instructables.com/F9W/KTWW/H19RV6TJ/F9WKTWWH19RV6TJ.jpg&filename=10 - 7 - Install Top LEDs.JPG)
![10 - 8 - Install Top LEDs.JPG](/proxy/?url=https://content.instructables.com/F5X/JI5W/H1AH6XCX/F5XJI5WH1AH6XCX.jpg&filename=10 - 8 - Install Top LEDs.JPG)
It's time to glue the LEDs to upper platform. In addition to the upper platform and LED assemblies you made in the previous steps, you'll need 5 minute epoxy and something to apply it with (I used a small screwdriver that I wiped off after applying the epoxy.)
One additional step after the epoxy has completely bonded. Identify the LED that will be almost covered by the RFID reader and bend the wires as shown in the fifth photo. By bending the wires as shown you will not have any problem mounting the RFID reader.
- Mix a very small amount of the epoxy according the directions that come with it.
- Apply the epoxy to the sides of the LED that will come into contact with the sides of the holes in the platform.
- Place the LED into the mounting hole on the upper platform and hold it in place for 5 minutes. This is tedious and time consuming but if you don't hold it in the proper position until the epoxy sets, the LEDs will be at odd angles and your gizmo won't look good. A glued LED is shown in the third photo.
- Repeat for each LED. This will process will take about 40-50 minutes in total.
One additional step after the epoxy has completely bonded. Identify the LED that will be almost covered by the RFID reader and bend the wires as shown in the fifth photo. By bending the wires as shown you will not have any problem mounting the RFID reader.
Install the RFID Reader
![11 - 1 - Install RFID Reader.JPG](/proxy/?url=https://content.instructables.com/F5I/SLB5/H1AH6XL3/F5ISLB5H1AH6XL3.jpg&filename=11 - 1 - Install RFID Reader.JPG)
![11 - 2 - Install Top LEDs.JPG](/proxy/?url=https://content.instructables.com/FJG/7UJ1/H1AH6ITJ/FJG7UJ1H1AH6ITJ.jpg&filename=11 - 2 - Install Top LEDs.JPG)
![11 - 3 - Install RFID Reader134.JPG](/proxy/?url=https://content.instructables.com/FLE/O200/H1AH6XLY/FLEO200H1AH6XLY.jpg&filename=11 - 3 - Install RFID Reader134.JPG)
![11 - 4 - Install RFID Reader.JPG](/proxy/?url=https://content.instructables.com/FG0/PLN6/H19RV6YB/FG0PLN6H19RV6YB.jpg&filename=11 - 4 - Install RFID Reader.JPG)
![11 - 5 - Install RFID Reader.JPG](/proxy/?url=https://content.instructables.com/FOJ/PKU8/H1AH6ITM/FOJPKU8H1AH6ITM.jpg&filename=11 - 5 - Install RFID Reader.JPG)
![11 - 6 - Install RFID Reader.JPG](/proxy/?url=https://content.instructables.com/FYI/8MPI/H19RHJ49/FYI8MPIH19RHJ49.jpg&filename=11 - 6 - Install RFID Reader.JPG)
![11 - 7 - Install RFID Reader.JPG](/proxy/?url=https://content.instructables.com/FW3/65GY/H19RT6XA/FW365GYH19RT6XA.jpg&filename=11 - 7 - Install RFID Reader.JPG)
In this step, we will install the RFID reader on the upper platform. For this step, the following parts and tools are required:
- Serial RFID card reader (Parallax part number 28140)
- Four #6-32 x 1/2" Round head machine Screws
- Eight #6-32 Nuts
- Four 12" Male-Female Jumper wires (Sparkfun part PRT-09385). You'll need a red, black, yellow, and green.
- Screwdriver
- Small pliers
- Place each of the machine screws in the holes on the top of the upper platform and secure with nuts as shown in the second photo. Use the screwdriver and pliers to ensure the screws and nuts are tight but do not over-tighten.
- Place the RFID card reader onto the screws as shown in the third photo. Make sure to place it so the components on the card are facing down: that way you will be able to see the the "enable" LED on the reader change from red to green and back as the gizmo is working.
- Secure the RFID card reader with the remaining four nuts as shown in the fourth photo. Use the pliers to tighten the nut but don't over-tighten. The RFID card reader and upper platform will look like the fifth and sixth photos.
- Slide the female ends of the jumpers onto the pins on the RFID card reader. It is very important to follow the color coding - if you don't, at best the reader won't work, at worst you will damage or destroy it. See the last photo.
- Red - VCC (positive)
- Yellow - Enable
- Green - SOUT (serial output)
- Black - GND (ground)
Install RFID Upper Platform in Case
![12 - 1 - Prepare Case.JPG](/proxy/?url=https://content.instructables.com/FQ7/MN9M/H19RHJ66/FQ7MN9MH19RHJ66.jpg&filename=12 - 1 - Prepare Case.JPG)
![12 - 2 - Prepare Case.JPG](/proxy/?url=https://content.instructables.com/FQQ/OXI2/H19RT714/FQQOXI2H19RT714.jpg&filename=12 - 2 - Prepare Case.JPG)
![12 - 3 - Prepare Case.JPG](/proxy/?url=https://content.instructables.com/FMT/N1ZU/H19RT715/FMTN1ZUH19RT715.jpg&filename=12 - 3 - Prepare Case.JPG)
![12 - 4 - Install RFID Platform.JPG](/proxy/?url=https://content.instructables.com/FGK/I0TW/H19RHJ69/FGKI0TWH19RHJ69.jpg&filename=12 - 4 - Install RFID Platform.JPG)
![12 - 5 - Install RFID Platform.JPG](/proxy/?url=https://content.instructables.com/F41/56J5/H19RV70R/F4156J5H19RV70R.jpg&filename=12 - 5 - Install RFID Platform.JPG)
![12 - 6 - Install RFID Platform.JPG](/proxy/?url=https://content.instructables.com/FEI/LNXB/H1AH6IWH/FEILNXBH1AH6IWH.jpg&filename=12 - 6 - Install RFID Platform.JPG)
![12 - 7 - Install RFID Platform.JPG](/proxy/?url=https://content.instructables.com/F3W/630Q/H19RV70S/F3W630QH19RV70S.jpg&filename=12 - 7 - Install RFID Platform.JPG)
![12 - 8 - Install RFID Platform.JPG](/proxy/?url=https://content.instructables.com/FVO/ODB6/H19RHJ6C/FVOODB6H19RHJ6C.jpg&filename=12 - 8 - Install RFID Platform.JPG)
![12 - 9 - Install RFID Platform.JPG](/proxy/?url=https://content.instructables.com/F7V/2V8F/H1AH6XTP/F7V2V8FH1AH6XTP.jpg&filename=12 - 9 - Install RFID Platform.JPG)
In this step, the upper platform with the RFID card reader will be mounted into the case. You will the following parts and tools for this step:
- Four #10-32 x 3" round head machine screws
- Sixteen #10-32 nuts
- Sixteen #10 flat washers
- Phillips head screwdriver
- Small pliers
- Install each of the machine screws in the case and lock in place with nuts as shown in the second photo. Tighten the nuts.
- Place washers on top of the nuts as shown in the third photo.
- Slide the upper platform onto the machine screws as shown in the fourth photo.
- Add a washer to each machine screw, add a nut and tighten as shown in the fifth photo. A top view of the upper platform in place looks like the sixth and seventh photos.
- Place nuts onto each machine screw approximately 3/4" from the bottom of the screw as shown in the eight photo.
- Add washers as shown in the ninth photo.
Attach LED Wires to Arduino and Ground Terminal Strip
![13 - 1 - Wire LEDs.JPG](/proxy/?url=https://content.instructables.com/FBQ/J9UE/H1AH6YJE/FBQJ9UEH1AH6YJE.jpg&filename=13 - 1 - Wire LEDs.JPG)
![13 - 2 - Wire LEDs.JPG](/proxy/?url=https://content.instructables.com/F03/0JC7/H1AH6N40/F030JC7H1AH6N40.jpg&filename=13 - 2 - Wire LEDs.JPG)
![13 - 3 - Wire LEDs.JPG](/proxy/?url=https://content.instructables.com/FTE/YOYE/H19RV7IQ/FTEYOYEH19RV7IQ.jpg&filename=13 - 3 - Wire LEDs.JPG)
![13 - 4 - Wire LEDs.JPG](/proxy/?url=https://content.instructables.com/FCG/YTIT/H19RV7IR/FCGYTITH19RV7IR.jpg&filename=13 - 4 - Wire LEDs.JPG)
![13 - 5 - Upper Platform LED Wiring Diagram.png](/proxy/?url=https://content.instructables.com/F3B/YAQR/H19RV7IT/F3BYAQRH19RV7IT.png&filename=13 - 5 - Upper Platform LED Wiring Diagram.png)
It's time to start connecting the wires to all the right places. In this step, the wires for the LEDs on the upper platform will be connected to the ground terminal strip and the Arduino. You'll need a very small screwdriver for this step - the head of the screwdriver needs to be able to turn the small screws on the Screw Shield.
- Place the lower platform and the enclosure on your workbench as shown in the first photo. This will allow you connect all the wires and at a later step easy lift the lower platform, flip it and lower it on to the case machine screws.
- Now turn the case on its side as shown in the second photo.
- Attach all the black wires from the LEDs to the terminal block as shown in the fourth photo. It doesn't matter which screw you attach them to but it'll be easier if you attach no more than two per screw.
- Now attach the blue wires from the LEDs to Arduino pins 6 to 13 by inserting them into the Screw Shield and tightening the screws. The order is important or the LEDs will not light in sequence. You should attach them as shown in the diagram. It doesn't really matter which one LED you start with for pin 6: what matters is that they are attached in a consecutive sequence (6, 7, 8, ...) not some random order.
Attach RFID Card Reader Wires to the Arduino
![14 - 1 - Wire RFID Reader.JPG](/proxy/?url=https://content.instructables.com/FGG/7F6P/H1AH6N8B/FGG7F6PH1AH6N8B.jpg&filename=14 - 1 - Wire RFID Reader.JPG)
![14 - 2 - Wire RFID Reader.JPG](/proxy/?url=https://content.instructables.com/FUU/VIP0/H1AH6N8C/FUUVIP0H1AH6N8C.jpg&filename=14 - 2 - Wire RFID Reader.JPG)
![14 - 3 - Wire RFID Reader.JPG](/proxy/?url=https://content.instructables.com/FFN/FPNV/H1AH6N8D/FFNFPNVH1AH6N8D.jpg&filename=14 - 3 - Wire RFID Reader.JPG)
In this step, the wires from the RFID card reader will be attached to the Arduino. You'll need the fine tip screwdriver from the last step for this step.
- Insert the red (power) and black (ground) wires to the 5V and GND connections on the Screw Shield and tighten the screws as shown in the first photo.
- Insert the green SOUT (serial out) wire to the pin 3 on the Arduino Screw Shield and tighten the screw as shown in the second photo.
- Insert the yellow Enable wire to pin 4 on the Arduino Screw Shield and tighten the screw also shown in the second photo.
Attach USB Cable to the Arduino
![15 - 1 - Attach USB to Arduino.JPG](/proxy/?url=https://content.instructables.com/FDV/ZRGW/H1AH6YM8/FDVZRGWH1AH6YM8.jpg&filename=15 - 1 - Attach USB to Arduino.JPG)
Attach a USB cable (Male A plug with male B plug) into the Arduino's USB port as shown in the diagram below.
Congratulations! All wiring is now complete!
Congratulations! All wiring is now complete!
Install Arduino Board and Lower Platform in the Case
![16 - 1 - Install Arduino Board in Case.JPG](/proxy/?url=https://content.instructables.com/FNF/U4WS/H1AH6NII/FNFU4WSH1AH6NII.jpg&filename=16 - 1 - Install Arduino Board in Case.JPG)
![16 - 2 - Install Arduino Board in Case.JPG](/proxy/?url=https://content.instructables.com/FOF/69O3/H1AH6YMC/FOF69O3H1AH6YMC.jpg&filename=16 - 2 - Install Arduino Board in Case.JPG)
![16 - 3 - Install Arduino Board in Case.JPG](/proxy/?url=https://content.instructables.com/FDN/VR9I/H19RT7SO/FDNVR9IH19RT7SO.jpg&filename=16 - 3 - Install Arduino Board in Case.JPG)
![16 - 4 - Install Arduino Board in Case.JPG](/proxy/?url=https://content.instructables.com/FCE/FEVX/H1AH6YMD/FCEFEVXH1AH6YMD.jpg&filename=16 - 4 - Install Arduino Board in Case.JPG)
Almost done! Time to put the lower platform into the case and lock it in place.
- Carefully and gently turn over the lower platform and set it into the four machine screws attached to the case.
- Place washers on each of the screws and thread the nuts onto the screws and tighten. Do not over-tighten. See the first two photos.
- Gently push the wires into the body of the case. Be careful not block the color changing LEDs or have any wires poking out the top of the case. See the second two photos.
Close and Seal the Case
![17 - 1 - Seal Case.JPG](/proxy/?url=https://content.instructables.com/FGE/W1IV/H19RV7OB/FGEW1IVH19RV7OB.jpg&filename=17 - 1 - Seal Case.JPG)
![17 - 2 - Seal Case.JPG](/proxy/?url=https://content.instructables.com/FBR/B44L/H19RHK0E/FBRB44LH19RHK0E.jpg&filename=17 - 2 - Seal Case.JPG)
![17 - 3 - Seal Case.JPG](/proxy/?url=https://content.instructables.com/FX2/OSED/H19RT7UT/FX2OSEDH19RT7UT.jpg&filename=17 - 3 - Seal Case.JPG)
![17 - 4 - Seal Case.JPG](/proxy/?url=https://content.instructables.com/FX3/2VNC/H19RV7OX/FX32VNCH19RV7OX.jpg&filename=17 - 4 - Seal Case.JPG)
![17 - 5 - Secure Cables.JPG](/proxy/?url=https://content.instructables.com/FXS/YF66/H19RQZEH/FXSYF66H19RQZEH.jpg&filename=17 - 5 - Secure Cables.JPG)
![17 - 6 - Secure Cables.JPG](/proxy/?url=https://content.instructables.com/F2V/3GFB/H19RV7P4/F2V3GFBH19RV7P4.jpg&filename=17 - 6 - Secure Cables.JPG)
This is the last assembly step for the hardware. You'll need a screwdriver, needle nose pliers, and two four inch plastic wire ties for this step.
- Place the bottom piece of the case on the top piece. Make sure that the two USB cables are positioned in the cutout on the back of case (see second photo.) Be careful not snag any wires in the process. Don't pull on the USB cable for the color changing LED circuit - it's soldered but you could easily damage it and then you'd have to take it apart to repair it.
- Attach the bottom and top of the case together using the screws you saved from the first step. The sealed case should look like the first four photos.
- Now attach the wire ties to the cables and the case as shown in the last two photos. To get the wire ties in and out of the case, I slipped one end of the tie into the case and used a small needle nose plier to grab the end and pull it out. These wire ties will prevent damage to the gizmo from pulling on the cables.
Label the RFID Tags
![18 - 1 - Prepare RFID Tags.JPG](/proxy/?url=https://content.instructables.com/F1Q/AI04/H19RQZEQ/F1QAI04H19RQZEQ.jpg&filename=18 - 1 - Prepare RFID Tags.JPG)
![18 - 2 - Prepare RFID Tags.JPG](/proxy/?url=https://content.instructables.com/F7R/4FD3/H19RQZER/F7R4FD3H19RQZER.jpg&filename=18 - 2 - Prepare RFID Tags.JPG)
For this step, you will need a bunch of 50mm Round RFID tags that match the RFID card reader (Parallax part 28142): these are EM4100 family tags that have a 125 kHz activating frequency. You will also need a color printer (inkjet or laser), self adhesive labels suitable for use in a printer, scissors, and of course artwork.
- Find artwork that you want to use to represent the web site you want to associate with tag.
- Using your favorite software, print the artwork onto the labels (I used Avery labels and their online label printing software.)
- Cut out the labels and stick them on the tags as shown in the second photo. You can put the sticker on either side of the tag.
Installing the Software
![19 - 1 - python.png](/proxy/?url=https://content.instructables.com/FMX/Y7GR/H1JU3QBJ/FMXY7GRH1JU3QBJ.png&filename=19 - 1 - python.png)
![19 - 2 - pyserial.png](/proxy/?url=https://content.instructables.com/FMA/8I9F/H1JU3QBK/FMA8I9FH1JU3QBK.png&filename=19 - 2 - pyserial.png)
![19 - 3 - 7-Zip.png](/proxy/?url=https://content.instructables.com/FBL/ONO9/H1JU3QBL/FBLONO9H1JU3QBL.png&filename=19 - 3 - 7-Zip.png)
![19 - 4 - Arduino.png](/proxy/?url=https://content.instructables.com/FDU/XSK1/H1KH9C6G/FDUXSK1H1KH9C6G.png&filename=19 - 4 - Arduino.png)
The following software will need to be installed on your computer: Python, the Python pySerial library, Arduino development software, and a utility called 7-Zip. I developed the gizmo's software on a computer running Windows 7. All of this software will run on Windows XP, Windows Vista, and Linux.
-
Python is used to run the program that will monitor the USB port for data from the Arduino in the gizmo. I used Python version 2.7.2 for this program. Any version of Python 2.7.x should work fine. I have not tested the Arduino Internet Gizmo on Python 3.2.x.
- To install Python 2.7.x, download the Python 2.7.x Windows installer software from http://www.python.org/download/.
- After the download is complete, run the installer. The installer asks where you want to install Python - I had it install it at c:\Python27. All of the following instructions assume that's where it's installed. You can install it in a different folder, but you will need to adjust the instructions accordingly.
-
pySerial is a library for Python that allows it communicate over a serial communication link like USB. Install pySerial as follows:
- Download pySerial from http://pypi.python.org/pypi/pyserial - click on pyserial-2.6.tar.gz to download the library.
- Download and install 7-Zip from http://www.7-zip.org/. This software is required to open the pyserial tar.gz file.
- Run 7-Zip (Start -> All Programs -> 7-Zip -> 7-Zip File Manager).
- Open the pyserial-2.6.tar.gz file with 7-Zip (File -> Open).
- Double click the "dist" folder.
- Single click on the "pyserial-2.6.tar" file and click the "Extract" button at the top of the window. When asked where to put the file, specify c:\Python27\Lib\site-packages\pyserial-2.6
- Exit from 7-Zip
-
Now that you have downloaded pySerial, install it:
- Open a command window (Start -> All Programs -> Accessories -> Command Prompt) and type into the command line: cd c:\Python27\Lib\site-packages-\pyserial-2.6
- Install pySerial by typing this command: c:\Python27\python.exe setup.py install
- Download and run the Arduino development software installer from http://arduino.cc/en/Main/Software.
- Download the "arduino-internet-gizmo v1.py" file to "c:\Python27" folder.
- Download the "arduino_internet_gizmo_v1.ino" to a folder of your choice.
How the Software Works
![20 - 1 - Arduino Internet Gizmo Software.PNG](/proxy/?url=https://content.instructables.com/FGC/BUJE/H1JUI84F/FGCBUJEH1JUI84F.png&filename=20 - 1 - Arduino Internet Gizmo Software.PNG)
![20 - 2 - Arduino Internet Gizmo Software.PNG](/proxy/?url=https://content.instructables.com/F2H/IYPP/H1JUI7M8/F2HIYPPH1JUI7M8.png&filename=20 - 2 - Arduino Internet Gizmo Software.PNG)
![20 - 3 - Arduino Internet Gizmo Software.PNG](/proxy/?url=https://content.instructables.com/FLT/AAMR/H1KH9QA3/FLTAAMRH1KH9QA3.png&filename=20 - 3 - Arduino Internet Gizmo Software.PNG)
![20 - 4 - Arduino Internet Gizmo Software.PNG](/proxy/?url=https://content.instructables.com/F7F/3UDU/H1KH9QA4/F7F3UDUH1KH9QA4.png&filename=20 - 4 - Arduino Internet Gizmo Software.PNG)
![20 - 5 - Arduino Internet Gizmo Software.PNG](/proxy/?url=https://content.instructables.com/FDQ/6LJ2/H1JUI7M9/FDQ6LJ2H1JUI7M9.png&filename=20 - 5 - Arduino Internet Gizmo Software.PNG)
![20 - 6 - Arduino Internet Gizmo Software.PNG](/proxy/?url=https://content.instructables.com/FM1/8V8W/H1JU3Q7U/FM18V8WH1JU3Q7U.png&filename=20 - 6 - Arduino Internet Gizmo Software.PNG)
![20 - 7 - Arduino Internet Gizmo Software.PNG](/proxy/?url=https://content.instructables.com/FSI/3MWN/H1JUI7MA/FSI3MWNH1JUI7MA.png&filename=20 - 7 - Arduino Internet Gizmo Software.PNG)
![20 - 8 - Arduino Internet Gizmo Unknown Tag.png](/proxy/?url=https://content.instructables.com/FYG/WYHE/H1KH9QA6/FYGWYHEH1KH9QA6.png&filename=20 - 8 - Arduino Internet Gizmo Unknown Tag.png)
The Arduino gizmo software turns on the color changing LEDs, then goes into a loop reading RFID tags, making the LEDs on top of gizmo race in circles when a tag is read, and then sends the data to the PC. An overview of of the sections of the programs follows - there are detailed comments in the code that explain each line. The program is shown in the first three diagrams.
- Line 8 allows the program to use the SoftwareSerial library that the program uses to communicate with the RFID reader
- Lines 10 - 16 define the Arduino pins used by the program
- Lines 18 - 23 define the variables used by the program
- Lines 28 - 36 are run when the Arduino is first powered on or reset. This code turns on the color changing LED circuit, initializes the connection to the PC and the RFID card reader, and initializes the LEDs on top of the gizmo.
-
Lines 41 - 71 are the main loop for the program. This loop will run until the Arduino is powered off or reset. The first thing done in the loop is to check whether the RFID reader has read any data and whether the data read indicates the beginning of a tag. If so:
- Lines 44 - 53 read data from the RFID reader until the tag has been completely read.
- Lines 55 - 63 send the data to the PC. Three datum are sent: the count of tags read so far, the time that the tag was read, and the tag ID that was read. The count and time are not used by the program on the PC but are there for debugging purposes and are useful if you want to use this code for other Arduino RFID projects.
- Lines 64 - 68 temporarily turns the RFID card reader off, makes the LEDs on top of the gizmo race around, and then sleeps for a short time. The RFID reader is turned back on and the program loops back to the top.
- Lines 74 - 88 are a subroutine that makes the LEDs on top of gizmo illuminate in sequence and appear to race around in circles. The input to the subroutine is the number of times to race around and the the number of milliseconds to keep each LED illuminated.
- Lines 90 - 98 are a subroutine that initializes the pins for the LEDs and sets them to be output pins.
- Lines 12 - 15 import the libraries for creating and writing to files, communicating with the Arduino, parsing the data sent from the Arduino, and controlling the web browser.
- Lines 20 - 34 are the table (dictionary in Python terms) used to associate the tag IDs with web sites. Each line has the ten character RFID tag ID and a HTTP link to the web site. Note that the first tag has "quit" for the web address. If this tag is read, then the program will end. New tags can be added by duplicating the last line and replacing the tag ID with the new tag and putting in the web site you want for the tag.
- Line 37 defines what COM port the program will use to communicate with the Arduino. This is the same COM part that is used by the Arduino development software to load the compiled program into the Arduino. You should change this to match your system.
- Line 42 is the name of the file that the program creates when an unknown tag is read. This file is created in the directory where you installed Python. In my case, it was "c:\Python27".
- Lines 45 - 54 use the pySerial library to connect to the Arduino. Messages will be displayed in the Python window indicating whether the connection was made or not.
- Line 56 checks to see whether the connection was successful. If the connection was made, processing will continue otherwise the program will end.
- Line 58 sets a variable that is used to determine whether a duplicate tag has been read. The idea is to prevent the same web site from being opened in the browser if the RFID reader happens to read the tag more than once when it placed over the reader.
- Lines 62 - 63 use the "pySerial" library to read the data from the Arduino.
- Line 66 checks to see if data has been read.
- Lines 68 - 74 use the "shlex" library to break the data from Arduino into three parts: the count, the time, and the tag ID.
- Lines 76 - 78 call a function to lookup the web site based on the tag ID. The tag ID and web site in the Python are displayed in the Python console window for debugging purposes.
- Lines 81 - 82 check to see if this is the special tag used to stop the program and if so, the program exits the loop and the program ends.
- Line 86 checks to see if the tag just read is the same as the previous one. If so, it loops back to the top.
- Line 87 uses the "webbrowser" library to start the browser if not running and then open a new tab for the web site.
- Line 88 saves the tag just read to prevent duplicate sites from being displayed. The program then loops back to wait for another tag.
-
Lines 90 - 104 are the function that is used to lookup the web sites associated with the tag ID:
- Line 93 checks to see if the tag ID is in the dictionary
- Line 94 returns the web site if the tag ID was in the dictionary.
- Lines 98 - 100 build the HTML for the error message for the unknown tag.
- Lines 101 - 103 use the "sys" library to create a HTML file, write the HTML to the file, and close the file. If the file happens to already exist, the HTML in the file is overwritten with the new HTML.
- Line 104 returns the name of the file. Back in the main program, the web browser will open this file rather than a web site and display the error message.
- Lines 107 - 111 allow you run this program from the command line and pass in the name of the COM port as a parameter rather than modifying the program. See the next step for details on how to use this.
Operating the Arduino Internet Gizmo
![21 - 1 - Gizmo Python Window.png](/proxy/?url=https://content.instructables.com/FK4/OVJH/H1JU3QIP/FK4OVJHH1JU3QIP.png&filename=21 - 1 - Gizmo Python Window.png)
![21 - 2 - Arduino Internet Gizmo Unknown Tag.png](/proxy/?url=https://content.instructables.com/FZJ/V9HH/H1JUE0ZT/FZJV9HHH1JUE0ZT.png&filename=21 - 2 - Arduino Internet Gizmo Unknown Tag.png)
![21 - 3 - Gizmo Python Window.png](/proxy/?url=https://content.instructables.com/FJS/W0VU/H1JU3QIQ/FJSW0VUH1JU3QIQ.png&filename=21 - 3 - Gizmo Python Window.png)
The first step to operating the Arduino Internet Gizmo is to compile and download the gizmo's program to the Arduino.
Next, start the Python program on the PC:
The third photo shows what is displayed by the Python program in the command window when tags are read. The first line for each tag is the data read from Arduino and the second line is the tag and associated web site. Note that sometimes the RFID reader will read a tag multiple times when it's placed by the reader - that's why the Python code looks for duplicates and ignores them.
Enjoy your Arduino Internet Gizmo!
- Navigate to the folder where you installed the Arduino development software and start the program (arduino.exe).
- Plug the USB power adapter for the gizmo into a power outlet.
- Plug the gizmo's USB cable in to your computer. If you get error messages about drivers not found, see the documentation on the Arduino web site.
- Load the gizmo's software: File->Open, go to the folder where you stored it, and open "arduino_internet_gizmo_v1.ino"
- Set the board to Arduino Uno: Tools -> Board -> Arduino Uno (or what version of Arduino you are using)
- Set the COM port: Tools -> Serial Port -> COM6 (this was the setting for my system, the Arduino software documentation will show you how to find what port your to which your Arduino is connected.
- Click the upload button (the circle with the arrow) right below the edit button in Arduino development software window.
- The program will compile and download. You'll see one of the LEDs on the top of gizmo flash a few times as the software is being loaded.
- The red-blue-green color changing LEDs behind the grill should illuminate and start changing colors. This is your indication that the gizmo is now operational.
Next, start the Python program on the PC:
- Open a command prompt: Start -> All Programs -> Accessories -> Command Prompt
- Change the directory to the Python directory: type cd c:\Python27
- Start the program by typing: python.exe arduino_internet_gizmo_v1.py
- The program will connect to the gizmo and you should see the messages indicating the Arduino was connected like in the first photo. If you get an error message that the program can't connect, you are most likely using the wrong COM port. Double check and try again. If you're using a different COM port than the one in the Python program, you can either change line 37 in the program or specify the COM port when you run the program like this: python.exe simple_internet_gizmo_v1.py COM7
- Read a tag and when you get the error message in the browser about an unknown tag, copy the tag ID, paste it into the table in the python program and update the associated web site. The second photo shows an example of an unknown tag error page.
- Repeat this for all of your tags. Don't forget to use one of your tags as the "quit" tag.
- Restart the python program and you'll be ready to have the gizmo bring up web sites on your command!
The third photo shows what is displayed by the Python program in the command window when tags are read. The first line for each tag is the data read from Arduino and the second line is the tag and associated web site. Note that sometimes the RFID reader will read a tag multiple times when it's placed by the reader - that's why the Python code looks for duplicates and ignores them.
Enjoy your Arduino Internet Gizmo!
Complete Parts List
![22 - 1 - Complete Parts List.JPG](/proxy/?url=https://content.instructables.com/FUW/C14V/H1JU3QL4/FUWC14VH1JU3QL4.jpg&filename=22 - 1 - Complete Parts List.JPG)
Each step in this instructable lists the parts and tools required. This step contains a consolidated list of all of the parts, tools, and software required to make the Arduino Internet Gizmo.
Electronic/Electrical Parts:
Electronic/Electrical Parts:
- 1 Arduino (I used an Arduino Uno)
- 1 Arduino Screwshield kit (Solarbotics part 51865)
- 1 Serial RFID card reader (Parallax part 28140)
- Bunch of 50mm round RFID tags (Parallax part 28142)
- 5 Red Blue Green color changing LEDs
- 8 Large red LEDs (T2-1/2 LHR3930 Jameco part 119634)
- 5 Resistors - 100 ohm 1/4 watt (Radio Shack 271-1311)
- 8 Resistors - 360 ohm 1/4 watt (Radio Shack 271-1315)
- 1 4-Pin optcoupler Lite-On LTV-817 (Jameco 878243)
- 1 Screw terminal (Jameco 2094485)
- 1 Adafruit Perma-Proto Quarter-sized Breadboard Printed Circuit Board (Adafruit PRT-589)
- 1 4-Position dual row barrier strip (Radio Shack 274-658)
- 1 USB cable with a male type A connector on one end
- 1 USB AC power adapter
- 4 12" Male-Female jumper wires (Sparkfun PRT-09385) - red, black, yellow, and green
- 48" Stranded black wire (#26 AWG)
- 48" Stranded blue wire (#26 AWG)
- 7" Solid core black wire (#24 AWG)
- 4.5" Solid core green sire (#24 AWG)
- 18" Solid core any color (#24 AWG)
- 6" 3/32" Diameter heat shrink tubing - black
- 6" 1/16" Diameter heat shrink tubing - blue
- 9 1/4" round nylon #4 spacers
- 6 #6-32 x 1/2" Round head machine screws
- 10 #6-32 Nuts
- 5 #4-40 x 3/4" Round head machine screws
- 5 #4-40 Nuts
- 4 #10-32 Round head machine screws
- 16 #10-32 Nuts
- 16 #10 Flat washers
- Power supply from a PC (preferably an ATX case)
- 4 Vinyl bumpers (rubber feet)
- 2 4" plastic wire ties
- 2 6" x 6" 1/8" thick sheets of acrylic (I used transparent blue and fluorescent red)
- Self adhesive labels suitable for use in a color printer
- 5 Minute Epoxy
- Goo Gone or similar adhesive remover
- Soldering iron and solder
- Phillips head screwdrivers
- Precision (fine tip) flat head screwdriver
- Wire strippers
- Wire cutters
- Small pliers
- Needle nose pliers
- Small knife or box cutter
- Heat gun or other suitable heat source for heat shrink tubing
- Epilog laser cutter or saw and drill for cutting acrylic
- Color printer (laser or inkjet)
- CorelDraw or Adobe Illustrator (optional)