By naxxfish on November 12, 2012
I like baking bread. I really do. I saw this link on mug bread on the twitters from Baking James. It’s an awesome recipe, which I fully indend to try next time I whip up a batch. But this sentence piqued my curiosity:
It is cheaper than buying bread. It requires less effort than popping to the shops to buy bread.
Uh. Oh. You know what this means now ….
Continue reading “Unnecessary Maths: Making your own Bread”
Posted in Baking, Random!, Tinkering |
By naxxfish on November 11, 2012
Ever since seeing the CurrentCost setup at 44kg (a particularly geeky student house whilst I was at uni) and Paul Mutton’s Jibble on the Matter, and then the subsequent posts about doing roughly the same thing, I decided that my new flat would need to have an electricity monitoring setup of some sort.
There are various energy monitors that you can get that will indeed measure how much electricity you’re using and display it on a screen. Some even come with a USB cable that lets you download the past data onto a computer to do what you want with. Some of them have Ethernet interfaces, that let you send the data into the cloud! There is even an Open Source Energy Monitor (emon) that you can build or buy which can do the job for you – and you can hack it’s firmware as well if you like (it’s Arduino based).
I decided that, given the past success with the device, and my lack of time and money, I’d go with the well proven, thoroughly understood CurrentCost EnviR – including the USB/serial cable that lets you hook it up to a PC (or, my my case, a Raspberry Pi)
Before going into detail about how I set up my monitoring, I need to explain a bit how the power distribution in my flat works, that’s a little non-standard. My flat only has electricity, and all of the heating is done by night storage heaters. The way these work is there is a separate Consumer Unit which the storage heaters are attached to, and this consumer unit (CU) is fed by a Radio Teleswitch. The teleswitch is controlled by data modulated onto the LW output of BBC Radio 4. The data contains: current date and time, on/off codes. Each teleswitch has it’s own set of codes to tell it to turn on or turn off. When it recieves one of it’s own codes, it will act upon it – either by turning on or off, or by waiting until a specified time before turning on or off.
When the teleswitch is enabled, it sends power to the night storage heater CU, and also sends a signal to the electricity meter to say that it should now log off peak usage instead of on peak usage.

Continue reading “Electricity Usage Logging with CurrentCost EnviR and a Raspberry Pi”
Posted in Code, Computing |
By naxxfish on November 4, 2012
I wanted my network to be awesome, and, one of the things that would make it awesome is properly configured DHCP/DNS. This was clearly a good job for my Raspberry Pi (running Raspbian). One of the things that I particularly like is the ability to address hosts by their name, even if they’ve got a dynamic IP. In the past, I’ve set this up using isc-dhcp and bind9, having it dynamically update a zone with the hosts as it gives out their leases. This is all find and good – however it does require a bit of faffing around with rndc keys.
As it turns out, dnsmasq does most of this all by itself! Hurrah! There’s a package for it, so it’s as easy as doing `sudo apt-get install dnsmasq`. Configuring dnsmasq to proxy DNS queries is super simple. All you need to do is set up your /etc/resolv.conf file properly, and it’ll work the rest out for itself. This is pretty cool – as I could provide IPv6 DNS servers as well as IPv4, and notably avoid my ISPs ones (which are a bit pants, if I’m honest!).
Read on if you want to know how I set it all up
Continue reading “Hi Pi, I’m home!”
Posted in Code, Computing, Personal, Tinkering |
By naxxfish on November 3, 2012

Annoyingly, the HomeHub 3 that comes with BT Infinity does not appear to have SNMP available on it. Or at least if it does, it won’t let you enable it in any straightforward way. That means I can’t just plug it into mrtg or some such other graphing engine and make pretty graphs to show my bandwidth usage.
However, it turns out that you can in fact get the raw transfer counters (in bytes) out of the web interface, after some jiggery and pokery.
My goal for this was to write a program that would suck the interface counters off the Home Hub automatically, which I could then hook up to a graphing engine running, allowing me to generate graphs of my bandwidth usage over time.
Continue reading “BT HomeHub 3 Stats Scraping”
Posted in Code, Computing |
By naxxfish on November 2, 2012
I recently received a Raspberry Pi from New IT (and notably not from RS Components, who, bless their hearts, tried for literally months to get one sent to me after some supply problems).

There are a number of little projects I’m working on around this little wonder, one of them being trying to resurrect my own personal Ceefax service using the composite out and a TV with Teletext support. I had to order a replacement remote for the TV, so I could push the TEXT button – so that was put on hold for a little while. There will be more on that later.
In the mean time, I decided that I wanted my RPi to act as a IPv6 gateway for my network (seeing as my BT HomeHub3 isn’t hackable enough to allow for that). For quite some time, I have got IPv6 Internet connectivity at home (and on some hosted VMs) via Hurricaine Electric tunnels. This is all very well when you’ve got one machine that you want to set up the tunnel on – but when you want every device on your network connected to the IPv6 Internet, it’s not so feasible. One thing I have done before is set up my PC as a IPv6 gateway – but that means powering a PC constantly, or you loose your tunnel. Not very efficient use of energy. However, the RPi does indeed have IPv6 support in it’s kernel – and more than enough oomph to serve as a router for a handful of IPv6 clients.
Continue reading “Raspberry Pi does IPv6″
Posted in Computing, Electronics |