# Gerrit Niezen

Maker of open-source software and hardware.

## Outdoor enclosure for DIY air quality monitor

After completing my previous air quality monitor build, I realised that I needed a proper outdoor enclosure, as I wanted to mount it outside and the 3D-printed enclosure is not exactly watertight. I looked through Thingiverse and found a design that uses a junction box as a waterproof enclosure.

The junction box was available from a UK supplier for a reasonable price, with free next-day delivery. I immediately started printing the various inserts to hold everything in place.

When the box arrived the next day, I first screwed in the bottom insert, then attached the particle sensor, and then screwed in the top insert. I also had to attach the temperature and humidity sensor and take care of all the wiring. Finally I added the ESP8266 board on top.

Once everything was installed, I turned it on. I could connect to the ESP8266 over the network, but for some reason the particle sensor recorded 0 $\mu\textrm{g/m}^3$. I couldn't hear the fan of the sensor turn on, and then realised that one of my screws was too long and was preventing the fan from turning. After loosening the screw a bit, everything was working really well.

The previous owners of our house had a satellite dish, but as we are not using it, I decided to remove the dish and re-use the hole in the wall to install a USB cable to power the air quality monitor. I tried pushing a micro-USB cable through the existing hole, but even a cable with a small micro-USB connector would not fit.

I found a 1.8 metre long micro-USB cable that was stripped and tinned on the other side, to make it easier to push through the hole in the wall and then solder to an old USB cable on the inside. This turned out to be the trickiest part of the build, as soldering very thin USB cables takes a lot of patience. I also used some heat shrink to keep everything nice and tidy after soldering.

Have a look at the sensor data on the Luftdaten website.

## Building an air quality monitor

A while back I became interested in air quality data after noticing that our local city council installed sensors next to busy roads, and that the data is available online.

When I saw that Pimoroni had a new environmental sensor add-on for the Raspberry Pi, I started thinking about building my own monitor to get more local, finer-grained data than provided by the city's open data. The Enviro+ from Pimoroni does it all, but is a bit expensive at £45. I would also need to pay extra for the particulate sensor (£25), and get a Raspberry Pi Zero W (£13) to attach everything to. That's a setup cost of £83!

## Getting started with the OLED display on a TTGO ESP32 LoRa board

A while back I bought an ESP32-based LoRa board from my local hackspace during an evening LoRaWAN workshop, and haven't really had a chance to play with it yet. I thought getting the OLED display to work could be fun as a first attempt.

First I tried the Arduino route using Adafruit's SSD1306 library, with some modifications as described here, but could not get it to work at all.

Then I found an Instructable describing how to install MicroPython on the board and get it working that way. But nope, still no luck.

Using the pinout diagram and Arduino test code in this repo, I figured out that the I2C pins had to be set as follows:

i2c = machine.I2C(scl=machine.Pin(22), sda=machine.Pin(21))


Finally, I had it working in MicroPython! I went back to the Arduino code, changed it to pin 21 and 22 (instead of pin 4 and 15 as in the original tutorial) and lo and behold, it was working there too!

## Book review: Time and how to spend it, by James Wallman

I recently read James Wallman's “Time and how to spend it: The 7 rules for richer, happier days” after seeing a tweet from Tom Evans at Bleep Bleeps.

The first thing to understand about this book is that it talks specifically about how to spend your free time, not the time you spend at work. It does this using a mnemonic, STORIES:

## Expensive lessons learned from doing home improvements

We're having the back of our house re-rendered and roof repairs done at the same time. Here are some things I wish I knew before we started.

### Get a breakdown of the work to be done

If the job quoted for is more than £1000, insist on a breakdown of what work is to be done. It is not a breach of trust to ask for something that will be of use to both parties involved.

### Don't use MyBuilder, RatedPeople or similar marketplaces

The contractors who do the actual work don't have the time or money to pay for leads, so the ones on those sites usually sub-contract, or work the lead generation costs into their fees. Customers may be too intimidated to post negative reviews, so you only see good reviews. Rather try to get recommendations via word-of-mouth.

### Don't use builders with sub-contractors

While it may make things easier for you in terms of having a single point of contact, you may end up paying twice what you would've paid if you dealt with each contractor separately. There's no guarantee that the builder treats his sub-contractors well, and he's probably taking most of the profit for himself.

## Update on converting my bicycle into an e-bike

The original post is here.

I sent a couple of e-mails to Cyclotricity but didn't get any response, apart from an auto-reply that stated that they received my e-mail but “server issues” may prevent them from responding. I then called their technical support, which asked me to e-mail them pictures of what's going on. That's when they gave me an e-mail address that actually works.

It turns out that there are indeed screws missing from the pannier rack they sent me, so they will replace these. They will also send me a new controller housing, since the screw was seized on the first one they sent me. It also appears that I installed the pannier rack correctly even though the images in the instruction manual does not match my kit. Lastly, they indicated that the PAS sensor has to be installed with the black part facing outwards, so I'm going to check if that is indeed the case, and then try to figure out why it's still not working.

We currently have a 2009 Ford Fiesta that's causing us more trouble than it's worth. Every now and again something else breaks and it's another half a grand down the drain to fix it. Unfortunately we wouldn't be able to manage without a car, as the public transport network in Swansea isn't that great, and you can only cycle so far in the rain.

I would love to buy a second-hand electric vehicle, but we don't have any off-street parking, nor do we have any public charge points nearby. So it seems that buying a small second-hand car is the only viable solution.

I've trying to identify which cars are the cheapest to maintain and have the fewest breakdowns, and for some reason Suzuki comes out top every time. The Celerio seems very affordable and fuel-efficient. We only drive around 5000 miles each year, so I guess the main question is whether it's big enough to fit a child's car seat comfortably.

## Planting potatoes

For Valentine's Day I received two potato planter bags. We bought some seed potatoes and they have been sitting in an egg carton on our kitchen windowsill for the past two weeks. I finally got around to planting them this past weekend.

I first filled around a third of the bag with compost, then placed in the five chitted seed potatoes, and covered it in another 10 cm or so layer of compost. I then watered it really well using some rain water that I found in a container in the back yard.

Now I just have to wait until the first shoots start to appear, and then cover them with compost again. This is called “earthing up” the potatoes.

#GrowYourOwn

## 10 random things you can do to start fighting climate change

• Use an online carbon calculator to calculate your footprint
• Fly less and look for alternative ways to travel
• Find your local zero-waste shops
• Convert your bicycle into an e-bike if you need to get up hills
• Start a compost heap