Liberty Games Labs SeriesLiberty Games Labs

Pool Table Scoring / Tweeting iPhone App

pool-table-with-appToday we’re continuing Liberty Games’ Labs Series with another pool table innovation. This time we’ve linked up two of our favourite things – pool tables (of course :)) and mobile phone apps. We love expanding the reach of tech, and now your iPhone (and soon Android and tablets as well) can speak to your pool table – and once it has worked out who has won it can even tweet the result for the whole world to see!

Ok so keeping score of who’s winning a game of pool isn’t the most difficult of things, but now we’ve overcome the most difficult part we think there are lots of possibilities – social media integration (we’ve already linked our app to Twitter), online league tables – even new types of games, (such as live online timed games).

Here’s a quick video of exactly how the system works:

Embed This Video

As you can see above we have used a colour sensor (available here) tied to our most favourite of gizmos the Raspberry Pi! For those not in the know the Pi is basically a credit card sized computer, which makes it super-useful for projects where normal PCs dare not tread.

Raspberry Pi in Pool TableFirstly we wrote a bit of code in-house, using Python to detect the different colour balls as they passed under the sensor, which involved modifying the pool table slightly so all the balls are funnelled past the sensor as they are potted. Luckily the sensor was not only really sensitive but came equipped with a built in LED so it could see in the darkness inside the table.

Once the Pi detects a ball, it makes an entry into a MySql database (also running on the Pi) – which we intend to use for game history and statistics in a forthcoming update to the app – there a PHP script picks up newly potted balls and using a websocket connection to an iPhone app displays a newly potted ball on the device. The app is able to keep track of which colour balls have been potted as well as if the black is potted before it should be – thereby ending the game.

When the game does end if the two players have entered their Twitter handles, the app connects back to the Pi which then uses the Twitter API to let the world know who won!

Pool Ball Colour SensorWe think it’s really cool to have a pool table connected up to the web like this, and we’re already buzzing with ideas for the next update to the app and a few general improvements to the system (including inserting individual sensors into the pockets to allow for quicker ball detection). This is a product we hope to have available for commercial availability in the very near future, but we’re so excited we thought we’d let everyone know about it now! We’ll also try and open source the code once it’s all cleaned up.

We’d love to hear any ideas about how you guys would like to see this tech used, so please let us know in the comments below.


Comments are closed.