Xbox Live Traffic Lights
The best time to play Xbox Live is when all your friends are online, but whats the best way of checking, you could turn on the Xbox, log on to the website or use the iPhone app, but this requires effort and you can still miss when your friends come online.
So I came up with the Xbox traffic lights, now at a glance you can see when the best time to play Xbox. An Arduino with Ethernet shield checks every five minuets to see if anyone is online.
The biggest problem I had was getting the user data off Xbox Live, as it is a frustratingly closed system, but eventually I found a usable api from xboxleaders.com, the only problem is that it only has public information, so it wont work with your friends that have hidden online status. ( Hidden status will always show a “1” in the api call, giving you a false green light).
The Arduino then loads the API for each player, then using the text finder library it finds the online status( a “1” or “0”), if the player is online it incenses the online status variable by one. At the end of the loop the Arduino will turn on one of the lights using that veriable: Zero players online = RED light, One player online = ORANGE light, Green = two or more players online = GREEN light. obviously this can be changed to suit.
Once it was all working on my EtherTen I build a more permanent solution using WIZnet W5100, it has the same chip as the official Ethernet shield but ½ the cost. So I don’t fell so bad putting it in permanent projects.
Download code: here
I wanted to use my Kinect sensor as a input for my Arduino for some up coming projects, I think its one of the best sensors out there, its a pity there isn't a Arduino Shield available for Kinect. So for now I have to use my computer, however I could not find easy/good ways of doing it. I wanted something very simple and Arduino user friendly
and no windows involved. After much searching and frustration I came across the simplest way for the Arduino and Kinect to be friends.
Kinect output of X,Y and Z left and right hands displaying on 20x4 Arduino powered LCD.
Using Processing, OpenKinect, and this tutorial and library it was very easy for a Arduino novice. The Arduino IDE is based off Processing, so it’s very easy to go from one to the other. Geting Processing and the Arduino to talk was easier than expected using this tutorial and a line of code in Processing like this:
myPort.write(“/¼/”+ handX +“/”);
With similar lines on the Arduino end:
int X= serialdata;
Now that the Arduino has the X, Y and Z values you can control any real world elements, such as a your lights, or a servo etc. You can even get Processing to calculate the angle between your hands, so when your turn your hands (like when driving a car) it will send a 0-360º value to the Arduino for added control.
Cordless Rotary Phone, Version One
After coming across some of my old rotary phones I wanted to get them working again, but one of the biggest problems with the old phones is they take so long to dial a number that the phone line will go dead or dials the number before you have finshed entering the number.
I needed the ability to dial the number only when the full number hand been entered. This was solved by using a cordless phone, as they usually only dial the number once you press send, this also made it posible to easily make the phone cordless. Using an Arduino for the rotary decoding and my old cordless phone for the rest solved the problem.
First things first was decoding a rotary number, rotary phones send a number of pulses out depending on the number selected, this was done very easy by using this code found on instructables, I then edited the code to turn on the corresponding digital output of the Arduino every time it detected a number input.
The hardware side was a bit tricky, but the easiest way of doing this was geting the Arduino to “press” the cordless phones buttons. This was solved by using an optocoupler for each button I wanted to press on the cordless phone. This isolated the Arduino from the phone, and the output of the optocoupler would act like a switch.
By soldering wires to the buttons on the phone and then to the output pins of the optocoupler, the Arduino could simulate pressing the buttons by turning on the optocoupler.
I mounted the old hanger micro switch onto my new control board and used it to send/start a call when lifted and hang up when down, this way you can input the numbers slowly on the rotary pad, and not have the phone disconnect because you are taking too long.
All together it works very well, how ever I still need to make the bells work, and install a battery for full portability.