Adam K Dean

Notes on software, systems, engineering, and things

2.4 The sensors

The fourth research topic is the sensors: which readings are worth having, and what each one can and can't tell me. It doesn't depend on the fan, so it ran alongside 2.2. ChatGPT got a brief with the plan and the findings from 2.1, on GPT-6 at the Pro setting, and worked for about 37 minutes.

The short version: build a small room-monitoring pod first, before the filter exists, with a particle sensor, a VOC sensor, and temperature and humidity. Measure the filter's airflow with a calibrated inlet and a differential pressure sensor, not from the fan speed. Detect tray use with a load cell under each tray. And don't buy an ammonia sensor yet: the affordable ones can't see the levels a room like this is likely to have.

Three questions, not one number

"Does it work" splits three ways, and each needs different evidence:

So there won't be a single "filter health" percentage on the dashboard.

The set

Part Price Interface Tells me Doesn't tell me
Sensirion SPS30 particle sensor about £36 I²C or UART, 5 V When dust goes up, rough PM levels, and how fast the room recovers The mass of all the litter dust, or the smell
Sensirion SGP40 VOC sensor, on a breakout £13.40 I²C A broad gas signal to drive the fan's automatic mode How much ammonia or MMB there is, or what the carbon removes
Sensirion SHT45 temperature and humidity about £12 I²C The room's conditions, and compensation for the SGP40 Anything about the filter
Sensirion SDP810-125PA across a calibrated inlet about £28 I²C The real airflow through the filter Airflow without calibrating the inlet first
Sensirion SDP811-500PA across the particle stage about £30 I²C The particle filter's resistance at a known airflow Whether the carbon is used up
Load cell and HX711 under each tray £15 to £35 a tray GPIO When a cat arrives and leaves, and which tray Whether it was a wee or a poo
The fan's tach output included GPIO Whether the fan is running or stalled The airflow

The pod's three sensors come to about £61. The whole set, with both pressure sensors and two trays, is about £150 to £195, before the ESP32, the power supply and the plumbing. Sensirion's SEN55 (about £31) combines particles, VOC, temperature and humidity in one module, and would make a simpler pod. Separate parts let me put the gas and humidity sensors where I want them.

Particle sensors

Sensor Channels Size Notes
Sensirion SPS30 PM1, PM2.5, PM4, PM10, counts 41 × 41 × 12 mm ±5 µg/m³ + 5% for PM2.5 below 100 µg/m³. Life over 10 years. My choice
Sensirion SEN55 As SPS30, plus VOC, NOx, T, RH 52 × 43 × 22 mm Good value all in one, less flexible to place
Plantower PMS7003 PM1, PM2.5, PM10, counts 48 × 37 × 12 mm About £22. The budget option. About 3 years' life
Panasonic SN-GCJA5 PM1, PM2.5, PM10 37 × 37 × 12 mm No longer made. Avoid

None of them is a reference instrument. The PM4 and PM10 numbers are worked out from the fine particles they actually see, and none of them sees the big debris from digging. They're good for timing events and comparing one event with another.

Gas sensors can't name the smell

The cheap gas sensors are metal-oxide parts that respond to a broad mix of gases. None of their makers shows them measuring MMB, indole or skatole. The SGP41's second channel is for NOx, not ammonia. Bosch shows the BME688 classifying hydrogen sulphide, which is interesting, but hydrogen sulphide isn't MMB. And a "TVOC in ppb" figure from a part like the ENS160 is an estimate, not a measurement of these compounds.

That's fine for the fan. "Something changed, clean harder" doesn't need "there's 83 ppb of this compound". The automatic mode, as a starting point:

The thresholds will come from the baseline data, not from these guesses.

Ammonia: not yet

Sensor Range The problem
Alphasense NH3-B1, electrochemical 0 to 100 ppm Zero can be off by about 10 ppm. Needs a bias circuit. Hydrogen sulphide drives its reading strongly negative
Membrapor NH3/CR-50, electrochemical 0 to 50 ppm Resolution under 0.3 ppm. 20 ppm of hydrogen sulphide reads as about 7 ppm of ammonia
Winsen ZE03-NH3 module 0 to 100 ppm 1 ppm steps. No UK stockist found; about $80 to $120 abroad
Winsen MQ-137, metal oxide 5 to 500 ppm Responds to amines too. Needs 48 hours to warm in
Figaro TGS2444 and TGS826 from 10 and 30 ppm Hard to get now

The only room study ChatGPT found was a diet study from 1993: a 23 m³ breeding room housing ten cats in cages, measured with detector tubes two hours after the ventilator was shut. It read 13 to 28 ppm. That says nothing useful about two cats in a WC. My room could be anywhere from below 0.1 ppm to a few ppm, and I don't know which.

Measuring what the ammonia stage removes is harder still. The removal is

η=1−CoutCin\eta = 1 - \frac{C_{\text{out}}}{C_{\text{in}}}

If 100 ppb goes in and 50 ppb comes out, and each sensor is good to ±10 ppb, the 50% removal is only known to about ±11 percentage points. A sensor that reads in 1 ppm steps can't see that at all. At a steady few ppm, a carefully calibrated electrochemical sensor could work, but nothing cheap does it at the low end.

So the first step is to find out what the room's ammonia level actually is, with a calibrated instrument or sampling tubes that cover the right range, and decide on a sensor after that. Hydrogen sulphide has a better sensor (Alphasense's H2S-B4 has about 1 ppb of noise with the right circuit), but hydrogen sulphide isn't MMB, so it stays out of the first build too.

Measuring the airflow

The fan speed doesn't give the airflow, because that depends on the resistance the fan is working against. The recommendation is a fixed inlet with a pressure sensor across it, calibrated once for the assembled unit:

Q=KΔPρQ = K \sqrt{\frac{\Delta P}{\rho}}

where KK comes from the calibration and ρ\rho is the air density. A design target of 10 to 20 Pa at 36 m³/h becomes 28 to 56 Pa at 60 m³/h, because the pressure goes with the square of the flow. That fits the SDP810's ±125 Pa. It also adds resistance, which goes into the fan's budget in 2.3.

The calibration needs a reference: a flow hood, or a proper traverse across the outlet, at several flows. A single anemometer reading at the outlet won't do. Done carefully at home, ±10% is realistic, and ±5% with a good reference. And 36 and 60 m³/h are 600 and 1,000 L/min, so the small flow sensors made for 200 L/min won't take the whole stream.

Pressure across the stages

Every stage gets a flush pressure tap in the space on each side. The SDP811 sits across the particle stage permanently, and the taps around the carbon get checked now and then. A pressure reading only means something with its airflow next to it: a lower pressure could be a cleaner filter, less air, or a leak. And pressure can't tell me how much carbon is left. For the carbon, the evidence is the sniff scores and the recovery times getting worse, checked by swapping in a fresh cartridge of just that stage.

Placement

Tray events and the sniff test

A load cell under each tray gives arrival, departure and which tray, so it's the main event signal. A motion sensor only shows something moved in the room, and the gas signal confirms an event rather than defining it, since cleaning products and people using the WC trigger it too.

Sensors don't measure what I smell, so I'll score that too, the same way every time:

No leaving trays dirty to test it, and no leaning over a tray to sniff.

The baseline

The pod runs for a day or two to settle, then logs for one to two weeks before the filter exists:

Signal Read Keep
SPS30 About every second All channels and its status
SGP40 Once a second, as Sensirion's algorithm expects Raw signal and VOC Index
SHT45 Every 1 to 5 seconds Temperature and humidity
Load cells About 10 times a second One-second summaries, and arrivals and departures
Door switch On change Every change

One row a second for 14 days is about 1.2 million rows, which is nothing for a database. Alongside it go notes: tray cleans, litter changes, the door, people using the WC, cleaning products.

The comparison is the peak above baseline, the area under it, and the recovery time, for similar events. Later there'll be three runs to compare: no filter, the fan running through an empty case, and the full filter. The empty case separates cleaning from just stirring the air.

For a feel of the numbers: 36 and 60 m³/h move the room's air 10 and 16.7 times an hour. In the ideal well-mixed room from 2.1, with a perfect filter and nothing still giving off smell, 90% is gone after

t90=ln⁡10nt_{90} = \frac{\ln 10}{n}

hours, which is 14 minutes at 10 air changes an hour and 8 minutes at 16.7. The tray keeps giving off smell, so the real recovery will be slower.

What changes in the plan

What I checked

I had Claude check nineteen of the claims against the data sheets, papers and shop pages. I worked through the arithmetic myself.

These held up: the particle sensors' specifications, the SGP41 having no ammonia channel, the BME688's sulphur detection, the VOC Index behaviour, every ammonia, hydrogen sulphide and pressure sensor specification, the cat room study's figures, and the prices from The Pi Hut and DigiKey.

These needed correcting, and the post above uses the corrected versions:

The rest, including the automatic mode thresholds, the airflow accuracy targets and the sniff test, are ChatGPT's engineering suggestions, and weren't checked claim by claim.

Still open

Sources

Paper:

Sensor makers:

Shops (prices on 13 October 2026):