Playing with the Pi

13 Flares Twitter 0 Facebook 0 LinkedIn 13 Filament.io Made with Flare More Info'> 13 Flares ×

I’ve been hacking around lately with a Raspberry Pi board. If you’re not familiar with it, it’s effectively a credit card sized, fully functional, programmable computer. Here’s a quick video to show you what it is. It is especially useful, due to it’s price and flexibility, as a classroom education tools, for young people to learn how to program computers.

My first encounter with a computer, at the age of 8, was with a remarkable ZX80 Spectrum. This beauty was programmable, could play games – Ghouls ‘n Ghosts anyone? – and most annoyingly you had to load them from a magnetic tape. Yes like the ones you made your mix tapes on. Those were the times!

So as you can tell, I had a nice time playing with the RasPi and getting it to do a couple of things I wanted it to do. It’s primary use right now is basically a media player. I’m running XBMC on it and have it hooked up to the TV via HDMI. It can output 1080p without any glitches and can run quite a few other processes at the same time. It’s a Debian flavour OS specifically modified for the Raspi’s hardware. This means the you can SSH to the box via your WiFi, you will however need a keyboard during the first startup to set it up. There are really good guides as to how to set it up. I opted for Rasbian OS and set up everything from scratch.

Now with regard to cost; It doesn’t really cost just £25 for the board. Realistically you’ll need a few other things as well. I got my Pi from the ModMyPi, and I’m very happy with the quality. They offer this bundle which includes everything you’s need to get set-up immediately. One more item that you’ll need is a USB disk, if you’re planning on using it as a media player. A 1TB drive will set you back approximately £60-70. I would also recommend a self-powered USB port extension, since if you connect the USB disk to the Pi it will draw power directly from it making it ever more difficult to power it self.

mypi
This is my set-up of the Pi. That’s the cased-Pi, the USD disk, and the USD port extension all strapped together behind the TV.

One advice I can give out is make sure you keep backups of your SD cards. They have a tendency sometimes to get corrupted, if you do something wrong to them, and then you’ll have to start from scratch. Before every big change I plugged the SD card into my Macbook’s SD card reader – on a side note the MCB Pro seems to have a manufacturing defect when it comes to inserting SD cards to it; once fully inside you have to retract it ever so slightly out again and then you’ll see it pop-up in your Finder window-. You’ll need to unmount the SD card before you can make a copy of it, so run this command in the Terminal:

diskutil list

This will show you all connected disks. You need to look for the capacity, and name that matches the SD card. Make a note of the device path. This will be something like /dev/diskX, where the X will be a number. You can unmount the disk with this command:

sudo umount /dev/diskX

Then you can use the following command to copy the contents of the SD card to a byte-for-byte image image on an external USB disk (in my case it’s My Passport disk connected via USB).

sudo dd if=/dev/diskX of=/Volumes/My\ Passport/RasberyPi_8GB.img bs=4m

If anything goes wrong the reverse command will re-imprint the backed-up image to the SD card reverting you back to a safe image.

sudo dd of=/dev/diskX if=/Volumes/My\ Passport/RasberyPi_8GB.img bs=4m

This method can also protect you from a failed RasPi. If something were to happen to it, all you need is a new bundle and just plug in a new SD card with you backup image.

The next step? Buying another Pi and setting it up as a virtual assistant, Siri-style!

13 Flares Twitter 0 Facebook 0 LinkedIn 13 Filament.io Made with Flare More Info'> 13 Flares ×