💾 Archived View for taoetc.org › running_my_blog_on_solar_power › index.gmi captured on 2023-04-27 at 07:29:32. Gemini links have been rewritten to link to archived content

View Raw

More Information

⬅️ Previous capture (2022-04-28)

-=-=-=-=-=-=-

Running my blog on solar power

I'm planning to run my blog on solar power. Initially I'm migrating only my blog (https://blog.taoetc.org/) to a solar-powered server, but the goal is to eventually migrate my Gemini capsule (gemini://taoetc.org/) as well. These are some notes on the project, currently in progress.

Hardware

I'm using an old Raspberry Pi Zero W that I had at home. I added a new SD card with 128 GB, and installed Debian on it. I've been using Debian since their 2.0 release, in 1998, and I always admired the project philosophy and integrity. It's my go-to distribution for servers.

The Pi is currently running connected to a Poniie PN1500 Watt Meter so I can measure how much power it needs, in order to dimension the solar panel and battery that I'm going to use. So far I've seen the Pi run consuming around 0.8W, but I want to run my website for a week to get a better estimate.

Poniie PN1500 Watt Meter

Once I have the data on power consumption I want to look at weather data to figure out the number of consecutive cloudy days I should expect where I live. With information I can choose a battery based on my desired uptime, and a solar panel that can keep it charged.

I recently learned about Nickel-iron batteries. They can last for decades, have a smaller environmental impact, and are more resilient to discharges. Unfortunately they are very expensive (though they should pay off on the long run): the cheapest battery I could find costs $1000, too much for a small project like this. Because of this, I'll probably use a standard lead battery.

Nickel-iron batteries

Networking

Currently the Pi is connecting to the internet via WiFi, but I'm planning to have it connected via a 4G connection. I have a Google Fi plan on my phone, and I have a couple SIM cards that are data-only associated with my account. I'm not expecting data usage to be high, but if that happens I might consider using the WiFi as the main connection and 4G as a backup.

To connect to 4G I'm using a KuWFi 4G WiFi Router Dongle. It works great with Linux: it plugs via USB, creating both a hotspot as well as an ethernet interface. I tested an older model and it works fine, but the reception was poor. I ordered the linked model since it has a connector for an external antenna, and I'm hoping that I'll get a better signal with it.

KuWFi 4G WiFi Router Dongle

In order to give the Pi a fixed, unfiltered, IP address I'm using a WireGuard commercial provider called hoppy. I've been using them for a few months and I really like the product: for $8 a month you get a real IPV4 address that's trivial to set up in Linux.

WireGuard commercial provider

I'm using NNCP to transfer files to the Pi. I learned about NNCP reading the article Building an airgapped bitcoin node with NNCP, and loved the concept. It's also perfect for the unreliable communication link with my solar Pi.

NNCP

Building an airgapped bitcoin node with NNCP

Now, when I publish my site the engine will call nncp-file for each modified file, queuing it to transfer to the Pi. It also calls nncp-exec at the end, queuing a command that copies the modified files to the web directory. Every hour my laptop then runs nncp-call, trying to send the files and command to the Pi.

Software

The Pi is running nginx to serve the static files from my blog. Once I have the blog fully migrated I want to install a lightweight Gemini server, and also host the contents of my capsule there.

I found a project called solarshed that has a Python script to monitor a cheap Renogy solar panel controller. I'm planning to buy the same controller, and have the Pi collect data on the battery and the solar panel.

solarshed

One of the things I want to do is to display the current data on my blog, similar to how LOW←TECH MAGAZINE does. Since my blog is static I'm planning to run a script periodically, generating a CSS file that I can include on my site to show the battery level.

LOW←TECH MAGAZINE

Tags

computer

linux

nefelibata

raspberrypi

Categories

STEM

About

Published on 2021-11-14 23:42:26+00:00 by Beto Dealmeida <roberto@dealmeida.net>.

Go back to the main index