A Cheaper Home Automation Solution

A while back I set up a little home automation using a USB 433Mhz transmitter to control some RF sockets I had lying around. The primary aim was to replace the timer I used to run my lamps, which needed constant changing throughout the year.

Byron Remote SocketIt worked, and I even made a couple of tweaks to update the timer so that it automatically came on around sunset, thereby switching itself on at an appropriate (ish) time without any interaction from me.

The project wasn’t particularly expensive, using a Telldus TellStick that cost about £55. I also needed a computer to trigger it, which I already had. The two combined make it quite expensive if you wanted to start from scratch, and the TellSticks aren’t easy to find (in the UK at least). Other alternative USB transmitters are dearer still.

With the arrival of the Raspberry Pi I could solve the issue of an expensive computer, plus reduce the power required. I started looking around and thought I could use a cheap 433Mhz transmitter and use the Pi’s GPIO pins to drive it. And so my quest began.

Initial Failure

As I said, I had done my research. Google and the Pi forums proved my friend and I soon decided to grab a small 433Mhz transmitter from Amazon, this one in fact. Which cost a rather pricey £5.59 (for this sort of transmitter anyway, see below).

433Mhz transmitterI also picked up some jumper wires, figuring I could simply attach them onto the GPIO pins and the pins on the transmitter. That didn’t go so well. I eventually gave up and purchased a GPIO starter kit off eBay (doesn’t look like it’s on eBay any more, but you can still buy direct from Smart-Elex, plenty of others are available too).

For £9.50, the kit provided me with a some LEDs, switches, resistors, a heap of jumper cables and, more importantly, an 830 point breadboard, a cable and a GPIO breakout kit (like the Cobbler). This made working on things much easier.

I tried a lot of different libraries (rf-bitbanger, RCSwitch-pi, and others) but couldn’t get it work, so gave up and figured I would some back to it later, hoping someone would develop an easier solution.

In hindsight, I had two problems:

  1. It appears I didn’t have my transmitter wired up correctly (there isn’t anything on the pins to indicate what does what aside from the antenna).
  2. I didn’t have a receiver to allow me to capture the signals from my handset, so I had to rely on what others had found.

A Second Go

It came back around to me thinking about the project again (thanks to this post) and I started yet more research. I liked the look of pilight (although I found it hard to install, with apt-get failing on me, got there with a git clone). Around this time I figured out my transmitter had been hooked up wrong so was excited to try this new option. Continue reading…

My Media Centre Overhaul

Since installing my HD card, live TV (HD channels) has never really worked. After a period of time the sound would begin to stutter and eventually disappear altogether. Stopping and restarting the channel would solve it, but only for a while.

I’ve looked for solutions before, such as increasing the size of the buffer pool (assuming it was when the buffer was full and it needed to start overwriting that the problem occurred). Nothing fixed it, so recently I decided on a complete rebuild, switching to Windows 8 at the same time.

Continue reading…

Disappearing Menus on Archive Pages in WordPress

Having recently been building a new site using WordPress, which utilised the handy custom post type functionality, I came across a couple of problems when building my theme. I’m posting the solutions here in case they prove useful.

Getting Custom Post Types to Appears in the Archives

You can use a custom page to display an archive of you custom post types, but I just wanted a single template (it’s a simple enough site). The problem is, only regular content types are included by default, so I used the code from CSS-Tricks:

function namespace_add_custom_types( $query ) {
if( is_category() || is_tag() && empty( $query->query_vars['suppress_filters'] ) ) {
  $query->set( 'post_type', array(
   'post', 'your-custom-post-type-here'
  ));
  return $query;
  }
}
add_filter( 'pre_get_posts', 'namespace_add_custom_types' );

That all worked lovely (modified to my data, obviously), but then I stumbled across a problem on the archive pages: my menu was disappearing. The Menu function is another I’m a fan of, due to the ability it provides to control your navigation, yet still access it via the control panel. Continue reading…

The Changing Landscape of Printing Costs

I wrote some tips a while back on buying a printer. The basic lesson was that for volume printing you wanted a laser printer and, if printing a fair amount, spend more on the hardware initially so you get the option for high capacity toner.

We’ve all seen the stories of inkjet printers that cost almost nothing, but soon seem less of a bargain when you come to buy new ink cartridges, which can cost more than the printer itself. The same is usually true for low-end laser printers.

The Changing Inkjet Market

Inkjet ink makes the price of crude oil look paltry (be very thankful you don’t use it to fill your tank), it’s expensive even compared to vintage Champagne. Added to that, a typical cartridge will only cover around 300 pages, and that’s without the repeated cleaning printers perform if you don’t print often enough.

There’s the old gotcha of tri-colour cartridges too, where only one colour needs to run out before you’re forced to replace the whole thing.

There are ways to drop the cost, whether that be aftermarket/re-manufactured cartridges, syringe refills or external tanks. Looking for printers that have separate colour cartridges and offer high capacity versions can also save you a lot too.

I’ve long shied away from recommending inkjets, but having spent a lot of time researching printers recently, I’m starting to change my view.

At the bottom end of the price bracket are printers that offer high costs per page (and for mono printing I’d class that as any over 1p per page), but many of the printer manufacturers are starting to fight back against the lowering costs of laser printers with improved ink prices and higher page counts per cartridge.

Separate colours are becoming a bit more standard and high capacity, which used to mean 500 pages instead of 300, can now mean several thousand pages, which pushes the cost per copy on a mono page to below 1p. Print speeds are up too, nearing laser rates. Continue reading…

Review of the Nexus 7

I was lucky enough to receive a Nexus 7 as a Christmas present, so having had it for a few months I thought it worth a quick write-up.

Nexus 7

I wrote a while ago that I didn’t think 7″ tablets were worth it, and for a while I wasn’t interested in them. I owned an iPad in any case. I did start to find I wanted to look things up while in a different room to my computer or the iPad and so having an extra tablet would be useful.

The improvements in tablets of that factor and the cost helped sway my desire. Then it came down to a choice of which one. The iPad Mini had not long been announced, the Kindle HD was coming to UK shores and there were offerings from B&N and Samsung as well as others.

I wasn’t interested in a cut-down Android experience, which ruled many of them out (the thought of rooting them didn’t appeal) and hence I hinted on my desire for the Nexus, as it came with an unfettered version of the latest release. Continue reading…