Arduino Powered Foosball Table
April 15, 2013 6 Comments
Why Attach an Arduino to a Foosball Table?
- Because the foosball table is clear on the opposite side of the building.
- Because we can!
What are those parts?
- The gold disk is a piezo electric transducer, commonly known as an electric guitar pickup. It converts vibrations into electricity.
- The red circuit board is an Arduino with Ethernet. It uses the standard Arduino library to handle dhcp requests.
- The circuit board is soldered after the knock sensor tutorial on arduino.cc http://www.arduino.cc/en/Tutorial/KnockSensor
- They grey cables are Power Over Ethernet Injectors (POE). They are not required if your foosball table is in reach of a power outlet.
Where can I buy this stuff?
POE Cable – https://www.sparkfun.com/products/10759
Piezo Transducer – http://amzn.to/XDxBiT
1 Mega Ohm Resistor – Radio Shack
Circuit board – http://amzn.to/XDxHqM
Headers – https://www.sparkfun.com/products/116
Wire – Your local garbage can
How do I code it?
See the code on github.com/spudstud/Foosball . You will need an account on cosm.com to store your sensor readings. Replace the “Feed ID” with your feed Id, and the “Data-stream” with your data stream name.
You will need to generate a new Private API Key and replace the API key in the code with your own API key.
Once you have the webpage how you want it. You will need to create an ubuntu virtual machine and install apache to host the website. It does not need to be on the same network as your sensor.
I highly recommend setting up your ubuntu web server using vagrant. http://docs.vagrantup.com/v2/getting-started/index.html
How did you make the webpage so pretty?
The majority of the webpage was coded by a friend who does web development professionally.
The github and “i” icons are actually fonts, not images. http://bit.ly/1190Sjj
The green button is made entirely with css3 and gradients.
The graph is made with cosm’s graph builder http://bit.ly/1181kRM
Only the flat piezo elements work, speakers pulled from computer cases absolutely do not work. http://bit.ly/XOkrSu
What If I want to make my own awesome foosball table, but I have questions?
Leave a comment below
Ask your question on stack overflow and tag “cosm”
Go to the Arduino Forums
Any problems you discovered on the way?
I was going to use a raspberry Pi, but they don’t have analog sensors. Lady Ada has a great article of how to work around this: http://bit.ly/VHTEmS
Arduino Ethernet has 5 analog pins, but pins 4 and 5 are used by the ethernet shield. Pins 0 and 1 are also shared and shouldn’t be used.
What if I want to see pictures and a video of the table?
Here you are!