Garden Railroad controlled with a #RaspberryPi and Wixels / @Raspberry_Pi

Martin Sant has been developing a way to control the points in a garden railroad such that he can use an Android app to determine the route a train will take. I’ll let him describe the set-up:

“The technology behind this is based on the Raspberry Pi, which can be configured as a web server and the Wixel, which is a small wireless microprocessor board from Pololu. The web server will serve up HTML5 pages to the tablet and then communicate with a master Wixel that can control up to 64 slave Wixels. Each slave can be programmed to control 6 R/C style hobby servos which, with some waterproofing and an enclosure, I was planning to use to actuate my turnouts. Oh yeah, each slave can also send back 3 analog inputs and 2 has two more digital i/o pins.”

His plan is to make the whole thing waterproof so that it will survive being outside in the garden.

For more details, please read the Railroad Wixels page at MartinSant.net.

 

Need a quick HTTP server? Try Python on the #RaspberryPi

If you need to start up a quick-and-dirty HTTP server on the Pi, try the following at the command prompt:

python -m SimpleHTTPServer 8000

This will start up a server on port 8000. You can only server HTML pages without further work, but if you just want to stick something up quick, it’s a simple method.

You can also start up a server programmatically within Python:

import SimpleHTTPServer
import SocketServer

PORT = 8000

Handler = SimpleHTTPServer.SimpleHTTPRequestHandler

httpd = SocketServer.TCPServer(("", PORT), Handler)

print "serving at port", PORT
httpd.serve_forever()

#RaspberryPi measures visibility in Central London / @Raspberry_Pi

shard

The Shard is located in London and, at 310 metres (95 storeys), is the tallest building in the European Union. The price of apartments and condos in the building reflect the views they give across the UK capital and are rumoured to crest at $80 million for a two-floor penthouse.

A tourist trip to the top of the Shard costs £24.95.

In order to tell whether the price of the trip is worth it, and to quantify whether the owner of such a penthouse is getting their money’s worth, Willem at The Secret Batcave has created a project to measure how cloudy the view is.

The project is called the Shard Rain Cam. It combines a Logitech 9000 webcam with a Raspberry Pi and a USB thumb drive (for storage) and uses Motion, Python and OpenCV to take pictures and then do analysis to determine how cloudy the day is. The Rain Cam captures a time-lapse set of images which are then analysed by OpenCV which works out the cloudiness.

Anyone can see the results by going to the hyper-catchy website www.whatcaniseefromtheshard.com. This website gives a qualitative statement of whether the tourist fee of £25 is worth it. Right now, it says “Quite far, but not 25 quid far” which I had to chuckle at.