How to make an awesome media center all under $100

My housemate and myself have come up with a sweet media center setup that’s easy to use and just pure awesome. With a press of a button on an iPhone, iPad, Android or web browser, the media center, projector and sound system automatically turn on, and in a matter of seconds a fully function media centre experience.

No messing around finding the right remote, or turn equipment on manually, and no wasted power.

Power Board

Most of the magic of this system relies on a power board, a crucial piece of hardware. Why is it so important in this case? Well this power board controls the power for the PC, projector and sound system via IP. Right now your thinking that this is some sort of expensive network connected power rail, but it’s not. It’s simply a eco friendly load sensing power board.

These power boards are designed around saving power on home entertainment systems. How they are designed to work is quite simple and works well with our media center design. They have a master port which always has power turned on, and a series of slave ports. The power board monitors the master port for a change in load. When the load is high it switches on the slave ports. Incredibly handy design for our purpose, and only costs $10 or $20 more than a normal power board. I found mine in KMart.

Now the great part about this is that we can plug the PC into the master port and turn on Wake on LAN (WoL), connect the projector and the sound system to the slave ports, and with any luck, when you turn the PC via Wake on LAN or via the power button, your whole system will turn on.

Display (Projector)

As I mentioned above, our setup uses a projector as a display. This gives us a large bright screen. The projector in our setup was obtained by accuring 3 broken projectors from companies throwing them out, and reassembling them into a single working projector. It’s a little old, so not the greatest resolution, but for our purpose it does the job well for the right price.

Sound

In our case, we just recycled a sound system that wasn’t being used. Just connects to the PC via a RCA to 3.5mm jack, also home made (cutting up two cables and joining them together). Nothing really fancy about it.

Computer and Software

The computer was also recycled IT equipment, nothing flash in terms of hardware. The software is what brings this all together.

XBMC (XBox Media Center) is a lovely open source media center application that runs on GNU Linux systems, and unlike the title suggests, it’s actually designed for more than the XBox and is really nice software.

To make it a thousand times nicer and easier OpenELEC has rolled all the software up into an easy to use distribution . They have built it from the ground up, so no extra bloat and boots in a few seconds.

In our setup, we just pointed XBMC to our NAS, and we were pretty much done.

Remote

To finish it all off, we pretty much installed XBMC remote applications on any device we had Wi-Fi on. My favorite was Constellation which is designed for iPad and iPhone which does a beautiful job of displaying all the media and content, and has a very pretty remote control page.

Nearly every single one I’ve tried has a Wake on LAN function that allows for easily turning on the media center.

How to set Verbatim mode as default on Google Chrome

Google recently released verbatim mode for it’s search products, which is great for people like me that can’t stand googles fuzzy search. So if your the type of person that likes to actually get results, rather than vague connections to other sites this should work well for you. I’m sure a similar thing can done to Firefox and the like.

The idea of this is to add &tbs=li:1 to the end of your search query.

In Chrome you simply need to edit your search defaults.

  1. Right click the URL bar and select “Edit Search Engines”
  2. Under “Other search engines” type in the following fields.
    1. “Add new search engine” – Google Verbatim
    2. “Keyword” – Verbatim
    3. “URL with %s in place of query” - {google:baseURL}search?{google:RLZ}{google:acceptedSuggestion}{google:originalQueryForSuggestion}{google:searchFieldtrialParameter}{google:instantFieldTrialGroupParameter}sourceid=chrome&ie={inputEncoding}&q=%s&tbs=li:1

And there you have it, you should have search that actually provides you with results that you want.

Royal Canin

While you cat food specifically formulated for Siamese cats tastes wonderful, and the easy seal on the bag is awesome, it appears you have deceived me into purchasing cat food in which the bag has been specifically designed to be hard to pour.

The way the bag tapers up on both sides forcing the cat food to the middle makes it annoying to pour, and increases the chance of over filling. I suggest you go back to the design department and investigate removing the supporting structure on one side.

 

Kind regards,

 

Michael Wheeler.

SyncML and Funambol

When you don’t have a Google account it makes using an Android based phone very hard. One for the most annoying issues is that lack of alternative ways to sync calendar and contact details. Previously I used vCards and used Androids built in vCard importer (which is very handy and works well), however this is only for contacts and is only one way.

After some Googling and complaining I came across SyncML and Funambol Server. SyncML is a standard protocol / spec for syncing data, in particular personal information such as contacts and calender.

The Funambol server runs on Java, however it seems to run on a fairly small foot print, and hasn’t started nom’ing on RAM yet. It’s a simple install and only takes a small amount of configuration to get up and running.

Funambol also provides a few clients (I use the Microsoft Outlook one, along with the Android client), however other clients are supported (I use sync-ui and syncevolution).

In general the whole system works very well, and I’m yet to find an issue with the system.

Why tabbed browsers should die.

I currently use a browser with tab support – Chrome. I also use tabs quite a bit. However I don’t believe there should be a place for tabs in browsers. Where tabs do belong is in the OS. My terminal has tabs, my browser, my mail client, my text editor and even my file browser. Yet because every app does their tabs their own way, I can’t mingle programs together.

Where tabs belong is in the Window manager. Using the Windows Manager allows tabs to mingle, and the user create groups of Applications for different work flows.

One of my favorite implementations is the Haiku OS Prototype , however I am yet to see a decent use of these ideas within Linux Windows Managers.

Making the cloud your bitch.

So I have my dedicated server setup with all my cloud replacement apps and services. Email, pictures, status.net, jabber and blog, which is great, but how do I ensure that my data is safe from failure. One of the great advantages of using web services in the cloud is that they promise to keep your data safe from corruption, or loss. When you move away from these apps, you can also loose this safety net. Previous to this post, I was performing nightly rsync’s to a remote server using SSH. It worked ok, but had some disadvantages.

  • Costly in terms of hardware
  • Costly in terms of bandwidth
  • Is that storage medium that safe?
  • Requires a lot of effort to make snapshots

Having a second server sitting there just for backups isn’t really the cheapest solution, or the most robust. I went looking for a “service” on the internet yo play with. FTP hosts seemed to be too expensive, and backup providers were either geared towards home users, or fairly expensive. I then read up on the Amazon S3 cloud. Amazon S3 cloud is a cheap fast storage solution.

Amazon allows you to store as much as you want, and they’ll only charge you for what resources you use, at ludicrously cheap rates. Now you can rush off and get Amazon S3, and use a tool called s3cmd to sync your data with the cloud, however there are some draw backs.

S3cmd contains encryption, however you can only use it when you use the “put” command, and not the “sync” command. So if you want to use encryption (through GPG), it requires doing a full backup each time. The other issue is that it provides no snapshotting features.

The other option is s3fs which is a FUSE module to mount the S3 cloud as if it were a real disk. It works great however no encryption.

Eventually I can across some well hidden software called Duplicity which can backup to multiple sources including S3. It uses GPG for encryption and librsync to provide incremental updates. Duplicity will backup everything into 25MB GPG encrypted compressed tarballs and fire them off to S3. The advantage off this is that provides low bandwidth usage, and also low requests (every 1000 requests to S3 costs $0.01). Care must be taken to ensure you have a copy of the GPG key used for the encryption located elsewhere though. Duplicity allows you to restore data from a certain time or date, and only ever uploads data that has changed.

The disadvantage is that you cannot easily see the backups tree structure, and that you need to backup a GPG private key, however I believe this is a small price to pay for such good backups.

After the cloud

Just a short post and update of things I’ve changed, don’t like or forgot about when leaving the cloud.

So far I haven’t died being “off the grid”, but a few of my habits have changed (possibly for the better). Being off the cloud isn’t as bad as you think,  and you won’t die. Now and then I got a link to something on Facebook or an 18+ YouTube video that I simply had to disregard. I also had to create a GMail account for Android Market place to Root my phone, but the account was deleted straight away and F-Droid installed.

I had to make some hard decisions on what was acceptable data to hand out to everyone, and what I wanted self hosted. I ended up with a few accounts left outside my control:

  • Gravatar/libravatar
  • Github
  • Reddit
  • Linkedin

The reasons I didn’t rush to move these accounts:

  • I want that data public and shared to everyone
  • Ease of use
  • Reddit, Github and libravatar are fairly opensource or open standards

Things I forgot about:

  • My blog posts referencing flickr images (I still have to fix a lot of these up)
  • Last.fm
  • LinkedIn
  • Android Market (F Droid is a great replacement)

Things I changed:

  • TinyTinyRSS ended up being a bit clunky, so I decided to goto a desktop client
  • plogger to Gallary3 (I’m still not sold on this and might go back to plogger)

Leaving the “cloud”

For the last week I’ve been attending Linux.conf.au (LCA) and have the pleasure of meeting, listening and seeing some cool people (Geoff Huston, Vint Cerf, Linus Torvalds). Two main topics were presented during the conference, IPv4 address space shortage, and freeing the cloud.

I hope to address IPv4/IPv6 in a latter post, but for now I would like to focus on freeing the cloud. Francois Marier gave a lovely talk on how we can free the cloud from the closed source baddies. Francois created the site and project Libravatar which is an AGPL implantation or clone of the Gravatar system.

Mark Pesce presented a keynote on the Friday of LCA, about the ways companies can exploit users data, and how storing everything in the “cloud” isn’t such a good idea in terms of privacy (potential to steal your social graph). He also explained mimesis, and how we will replicate what others are doing.

This has given me a few reasons to attempt to leave the “cloud”. The first reason was from Francois – Why should I be forced to use non free (as in freedom) software on the internet? – Why can’t I add, expand and change the software that I use everyday. What is my upgrade path to avoid bit rot.

The second reason also came from Francois – Why aren’t these services decentralised? – Francois worked to make avatar services customisable by using DNS SRV records. Status.net allows you add remote users.

The third reason was from Mark – It’s more likely that your friends will also… - Well if I start doing this, one of you guys might also give it ago…

and finally the forth reason, which was also contributed to by Mark – Where is my data, and what the fuck have you done with it? - Is it possible to keep data to your self these days?

What is my aim, while leaving the cloud?

  • Move to a fully opensource environment online
  • Find out if it’s possible to live with out the big companies (Facebook, Twitter, Flickr, GMail)
  • Keep care of my own data
  • Start pushing for open communication standards between platforms (why can’t Twitter users talk to status.net users?). Bring down monopolies.
  • See how hard configuring alternative services are.

Should you (the reader) do this?

  • Maybe?

I’m not pushing for anyone else to make these decisions. This software typically isn’t user friendly enough for everyone to switch or lacks key requirements of use. I still look at this project as an experiment. I may have to revert back to some services. What I do suggest however, is to think about it. It’s not that hard to switch. Experiment, learn, play and explore the FOSS world.

Where am I now?

All of the following has been achieved in less than 48 hours, and on a 3G connection.

Email

The world would be a far different world without email, and it’s something that you can’t live without in the real and internet world. Previous to this change, I used Google Apps (GMail for your own domain). Having your own domain name is an advantage, as it allows you to move between email servers without changing email addresses.

I’ve always been a lover of Postfix and even Eric Allman agree’s

If I had to choose a new MTA today, I’d use Postfix

Eric Allman

So Postfix was put straight on. Postfix by it’s self is ok, but I really need a way to get email on my phone, computer and laptop, and it’d be great if all synced up together. From previous experience I knew that Dovecot was the way to go. Dovecot provides IMAP and POP access. IMAP was what I was interested in, and with fairly little configuration I had that all working.

Now this setup works ok, but to really give it the flexibility of GMail I need a pretty web interface. Jack Scott had previously shown me RoundCube IMAP webmail. RoundCube is a php/mysql app which is fast to setup, beautiful to use and just plain easy.

All that was left is to get my GMail data out and into Dovecot. To facilitate this I used a utility called imapsync. Enable IMAP on GMail, run imapsync, and you’re done.

What’s left to do?

While email works, there are a few missing features I haven’t implemented yet. I’m yet to configure Spam filtering, so I’m getting about 3 or 4 spam emails an hour. I haven’t worked out a nice way to implement mail rules, and RoundCube doesn’t implement any form or labels or tags, only folders. I haven’t worked out a nice place for my Google Address book, and a way to sync it with my phone.

Facebook / Twitter

If you are wondering why I have disappeared off your friends list on Facebook or Twitter, it’s because I a chose to delete my account, not because I have decided that I no longer like you.

I looked at how I actually used Facebook and Twitter. I didn’t post pictures, I had another service for that. I didn’t post videos, I had another service for that. All I really used Facebook and Twitter was to post fairly short messages. Longer messages in Facebook, shorter ones in Twitter. Heck, most of the time I didn’t even read or browse other peoples updates, as the signal to noise ratio was too low for me to care.

Even though I understand that barely anyone reads my Facebook statuses, I still wanted to a place to put short snippets that were too small to be a blog post, but required to let off steam, or share a funny link or two. I done some research and came across some software called status.net.

Status.net is basically a decentralised, opensource twitter. I installed it in single user mode, and within minutes I had a nice Twitter like microblogging page up.

What’s left to do?

Well I didn’t feel that I need to keep, backup or import data from Facebook or Twitter so I have let that data rot away. Unfortunately Facebook has a two week timer before account deletion, so I am still waiting for that to occur.

Flickr

Flickr is a great photo sharing site. It supports Creative Commons which is great, but for the purpose of this experiment, it’s still the cloud. Quite a bit of Googling latter, I found a nice opensource alternative called Plogger.

Plogger is a great little php app for organising photos and albums. Unfortunately to move all that data requires more than my little 3G connection so I haven’t had a chance to play with it to much, but it appears to perform the functions I need it to.

Most people won’t find Plogger a Flickr replacement, but it looks to work for me. It’s fast and simple.

Gravatar

Gravatar is a service that maps avatars to email addresses for the purpose of making blog comments look pretty. LCA introduced me to the Libravatar project which hopes to make the avatar service more open.

Well, I’m not going to lie to you, I haven’t setup my Libravatar server up. BUT, I have setup a Libravatar account up, and changed my blog to use Libravatar to grab avatars for comments. I don’t believe that Gravatar or Libravatar pose a risk to my privacy or social graph, however I do prefer the idea of using opensource web apps.

Blogger

I loved to WordPress quite some time ago from Blogger, when my needs expanding from the simple blogging service of Blogger. WordPress is free (as in freedom) and is really great software. If you aren’t using it for blogging, you probably should be, or at least Habari.

XMPP / Jabber

Along with my email, I also used Google Apps to host my XMPP. It was just another connivence. Google’s XMPP service isn’t anything flash, and can be replaced with any old XMPP server. In my case I just replaced it with jabberd, because it was in the Debian repo’s and just required apt-getting and registering an account. At no point did I do any configuration.

Google Reader

In short, Google Reader is my online life. With Google Reader I wouldn’t be informed with what’s hot or not in the IT world today. Google Reader took a bit of researching to replace. The first alternative was to jump to a desktop app, but that means I would loose some flexibility.

After doing some searching, I found some fairly out of date code and projects, but eventually stumbled upon Tiny Tiny RSS. It has the same look and feel and Google Reader and done a fairly decent job.

What do I have left?

  • Not a lot

I have two “cloud” services that I am yet to find a home for.

I didn’t have any decent videos, so I destroyed my YouTube and Google Video accounts, but I still want to find a video web app for when I do have content I want to share. At this stage I am thinking about using a simple HTTP drop box, and linking to it from my status.net page.

The other service I haven’t found a home for is LinkedIn. I want to remain visible to “that” crowd, so I will not be removing my LinkedIn profile. The advantage with LinkedIn, is that information stored there is fairly public regardless, and without knowing a great deal about social graphs, I can’t see it as being a huge issue.

Keeping it all running

All of these web apps and services are running on a Debian Linux server (single core CPU and some RAM). It’s nothing flash or fancy, but it works. I use lighttpd, and everything so far has only required PHP and MySql (the de facto standard).

Since everything is running on a single server that I maintain, I need to ensure that I have a recovery plan. For this I use a tool called rsync to backup every night my data. The last thing I want is to loose years of hard work.