freedombox for a solar powered house

I'm swinging on the front porch shade, with happy wifi bars lit up on my laptop. A good network makes for a happy home, isn't that how the saying goes? (Maybe not yet.)

Typically that's easy to achieve -- here it wasn't. The house is solar powered, the only connection to the outside is a phone line. So I needed a computer that would work in that environment, using minimal (12 volt) power, and getting the most out of the limited bandwidth while providing those happy wifi bars.

At DebConf we learned that the name for these little home servers we have been building for years is "FreedomBox". All right then, here's my latest FreedomBox build.

A typical inexplicable tangle of computer bits.
  • Computer: NSLU2. There are faster choices than the "Slug", but on dialup, speed doesn't much matter, and there are not many lower-powered choices. And with the NSLU2, I can take advantage of years of development and experience, that has resulted in great support for running eg, Debian on it, and deep available knowledge of hardware hacks. It's proven, cheap, highly reliable hardware, and I had it lying around.
  • Power: The NSLU2 is a 5 volt computer. There are some highly (90%) efficient 12 volt to 5 volt converters, which I covet. But the cheap and easy option is a automotive USB power adapter. So power is coming in to the NSLU2 on a USB cable. It's possible to just plug that into its usb port and it will run. But that wastes a port. Instead, I made the other end of the usb cable have a NSLU2 power socket on it. So, no wasted ports. The system has available as many amps as the voltage converter supplies. Not many. Booting it with too many usb gadgets attached could be an issue. (If I need to run an external usb hard drive, it had better have its own power supply.)
  • Wireless: ZyDAS 2501 USB dongle. Not my first choice, just one I had lying around. This device cannot run in AP mode. It is, by the way, possible to use some USB dongles in AP mode with a modified hostapd, but the few I know that work are out of stock. No problem; this house won't have many visitors, and I can tell them the details for connecting using Ad-Hoc wireless mode.
  • Storage: 64 gb thumb drive I had lying around. Hmm, last time I touched a NSLU2, I had only 1 gb drives lying around. Progress.
  • Modem: My NSLU2 is modified to have an external serial port, so I can use an external modem if desired. But I suspect a USB modem will use slightly less power, even though this third USB device means I need a USB hub too. I was doubtful about finding a USB modem dongle that works with Linux, but it was actually no problem, the USR5637 Just Works.
  • Software: Debian Linux of course. For the first time I'm using the polipo web proxy cache, and it works marvelously on dialup and on this low-spec system. Combined with dnsmasq, this makes web browsing over dialup actually not painful.

Since the solar house is in the sticks, the result is a server I call "stick".

Posted
solar day 2

End of the second day in the off-grid house. Three things strike me about being here: quiet, rhythm, and awareness.

In the city, I am constantly annoyed by noise. Here, there's a empty, echoing feeling to the quiet. It's not lack of noise exactly -- I can hear cicadas and birds right now -- but it's still quiet. At first I wanted to fill it, but now I can feel my hearing instead expanding outward. Catching a faint engine noise, or a dog barking in the distance.

Here there's a rhythm to the day driven by the sun. Get up, connect the batteries to the solar panels. (Only necessary because the charge controller is broken.) Check and record the battery levels, make sure the panels are producing well. Think about adjusting them at solar noon. Check the cooler to see how the ice is holding out. Do weekly chores: Refilling the kerosine lanterns and replacing the rock salt used to control the humidity, which is the downside to a earth-sheltered house that stays 70 degrees cool on a 90 degree day. In the evening, watch the sun go down, disconnect the solar panels, record battery levels, and light lanterns. That's the shape of the day.

Besides being aware of distant sounds and time time of day, being here brings to the fore awareness of consumables. Until I get a fridge sorted out, I have a cooler full of ice that I have to monitor. There's propane for the stove, and kerosine for the lanterns. And of course always the state of the batteries. So far, the first battery bank seems likely to last longer than the ice. I'll know better tomorrow.

Unfortunatly I burned out the 5v power supply I was using to run my NSLU2 in a wiring mishap, so I have to run that on an inverter for now, and the batteries, though not low, can barely power both the inverter and my laptop. This has made staying online tricky. But I'm finding dialup surpisingly tolerable, and it helps to generally slow down, too. Despite all the above, I got about as much real work done today as I normally would.

sunny day

I'm back in town. After approximatly 4 full days of use, the first battery bank dropped to 9 volts, my cutoff point for safe use. Which turned out to be below the safe use point of my laptop power adapter, which burnt out while I was busy listening to music and adding power-saving caching stuff to my mpd setup. Irony not appreciated, world.

I decided to come back while the other bank is still relatively full.

my modest PV array

Hurrying downtown to grab lunch in between work on Branchable, I noticed it was a beautiful sunny day, and I realized that this makes such days even better, because besides enjoying them, I know I'll be enjoying the yield on chilly nights sometime later.

Well, in theory. Actually, the very antique charge controller in the house was dead and bypassed, so I removed it. I called its manufacturer wondering if it could be refurbished, but they suggested it belonged in a museum. So I've ordered a new controller, a Xantrex C-35. Until that comes, pretty days like today will charge, or possibly over-charge the batteries, which will then drain back out at night.

Posted
MovieOS credit

In one scene of The Girl with the Dragon Tattoo), her laptop has been broken. These are the files that she needs to recover from it.

Yep, debconf templates files, debhelper md5sums, and generally /var/lib/dpkg/info/ -- in a film full of data, these are the first data that the plot turns on.

(PS, Even super-anti-heroes should probably make their backups before battle.)

Posted
DebCamp origin story

Richard Darst has been writing about DebConf organisation and wrote about DebCamp. Thought I'd give my story about where the idea for DebCamp came from, for some context.

DebConf2 in Toronto was my first DebConf. I had sadly missed DebConf1 due to EPASSPORT despite having sponsored tickets; something I still kick myself about. Things were not as well organised back then. Anyway, since Ottowa Linux Symposium was the week before DebConf, some of us were in Canada early for that, and needed to find something to do in the time between conferences.

My thought was, find someplace to camp. It'd be a cheap way to see more of Canada and decompress. I posted this plan to debian-private and Andreas Schuldei and I spent several days canoing around Algonquin park. Of course, we'd never met before. I'd met probably less than five European debian developers before that point. We experienced big scary lakes that challenged our limited canoe skills, portaged and camped, and even saw a moose.

Later during DebConf2, I distinctly remember mentioning our camping trip and saying "we could have a DebCamp before the next DebConf". And sure enough, before DebConf3 there was a DebCamp[1]. In the days we hacked on d-i and stuff. We camped out in the gym of a primary school in Oslo, and hung out through the long evenings out front. Some people even brought tents.

Since then, DebCamp has developed into the integral warmup for DebConf that Richard describes. I'd rather see it more ad-hoc and scruffy, but you can't argue with the purpose it serves.

So, are there any good places to camp near Banja Luka?

[1] Even then the DebConf orga team made it seem that easy.

Posted
solar charge controller adventure
Xantrex controller, temporarily badly installed

As planned I have installed the Xantrex C-35 charge controller in the offgrid house. This was a bit of an adventure..

First I had to wait around in town all day for the UPS man to deliver the thing. Of course he didn't until 4, so by the time I got over to the house it was almost dusk. Further delayed by necessary visiting with the nearest neighbor (a country thing), who claims there are "panthers" up this holler.. So by the time I was ready to work, it was nearly too dark.

First I checked the battery bank which I had left charging for a week without a controller or backflow diode. It had gained only half a volt (to 10.5v), so now I knew I really did need the controller in order for the sun to work for me while I am away.

Then, barely able to see, I swapped that bank to provide house power. By 10 pm, using just my laptop, I'd drained 1.5 volts from it and it was as low as it should go. I had 4 hours of laptop battery. This was a bit of a problem since I tend to stay up until 3 am on it.

Instead, I spent 2 hours, by kerosine lantern light, exposing, tracing, and testing wiring. I was able to find 2 wires that were clearly going to the battery bank and had current, and 2 others that were labeled as going to the panels, and, in the dead of night, had no current. Great, I thought, that's the wires I need, let's hook up the controller..

And I did, although only to the battery, since after all I couldn't be certain the other two wires were for the panels, without seeing voltage on them in the daytime. (This turned out to be probably wise, because in the morning, when I tried it, the controller reported no PV voltage. They turned out to be mislabled, and actually connected the battery to the breaker box.)


The problem with doing all that stuff at midnight is it took me quite a long time to wind down. I normally start winding down at 10 am and get to sleep at 3. Last night I got to sleep at 5.

My four hours of battery for my laptop were nursed all hours through the night. Mostly thanks to powertop and the improved power saving of the kernel these days. And to not having wifi or anything enabled. I do wonder if my recent use of redshift to redden the screen causes the it to use less power at night, as I have never gotten five hours out of this laptop before.


Anyway, to get the controller hooked up to the PV array and actually charging the batteries, I ended up having to rip lots of wiring out of the wall, until I simplified the mess to something I could understand. And at the moment I've bypassed the PV array's breaker, which is certainly a safety hazard. So more wiring to do, but I did get it working.

Finally, I hooked the house wiring up to the same battery bank that is being charged from the panel. This house had been using a 2 battery bank setup, because without a charge controller to moderate the PV voltage (17-25 volts), you can't also connect a load that expects 12 volts. The charge controller fixes that problem.

The other battery bank is sitting unused for now. Later, I will equalize and connect the two, in order to get one large(ish) battery bank.

Now, during the sunny fall daytime, I can use all the power I want; it's free from the sun. Battery bank shouldn't drain at all when I use power during the day, and the controller should charge them up and keep them topped off, so they'll be there for me at night.

Now to verify that it's working like it's supposed to!


(I posted some documents and more thoughts from this here).

Posted