Nobody loses a house because the ventilation was off. They lose it because the ventilation was on and the gas was still there — the fans were sized for summer heat, the controller was on a timer, and the one sensor was on the wall, two metres from the animals, in the only place in the building where the air happens to be clean. Ammonia is lighter than air. It collects under the ridge, a metre above the highest pig's back. Hydrogen sulphide is heavier than air and sits in the slurry channel. Carbon dioxide follows the same low path. A room can hold three very different numbers at three heights at the same second.
<10 ppm NH₃ working target in the stock's own air |
3 heights ridge · pen · slurry one shed, one clock |
60 s sample interval, with a 5-minute sustain gate |
0 PLC two relay outputs drive the fans and the inlets |
A livestock house is a continuously operating chemical reactor whose feedstock is feed, water and bedding and whose exhaust is heat, moisture, ammonia, carbon dioxide and hydrogen sulphide. The ventilation system has two jobs that are not the same job: remove heat in summer, and remove moisture and gas in winter. In summer the fans are wide open and the gas problem disappears on its own. The problem lives in the other ten months, at the lowest fan speed that still keeps the litter dry — when the air change rate is set by how much water vapour has to leave the building, and the ammonia is a passenger that nobody counted.
Ammonia comes out of the slurry and the litter continuously. Its concentration in the air is the equilibrium between how fast it is released and how fast the ventilation dilutes it, and that equilibrium moves with temperature, humidity, stocking density, feed crude protein and how often the channel is emptied. Two identical houses on the same farm, run by two different stockmen, hold different numbers. This is the reason the page below measures instead of assuming.
A single wall-mounted sensor at 1.4 m returns a number that is real, current, and not the number that matters. Stratification in a still house is not subtle: ammonia generated at the slurry surface rises, and with the ridge closed and the inlets throttled it accumulates in the roof space until the outlet opens. The sensor reads the mixed layer in the middle of the wall, where fresh inlet air arrives. It is the one place in the building where the air is being washed.
The failure mode that follows is worse than blindness. The controller sees 6 ppm, decides the house is safe, keeps the minimum setting, and the gas keeps building above the stock because nothing is measuring there. A shed with no sensor at all is ventilated by a stockman who walks in, smells it and opens a window. A shed with one badly placed sensor is ventilated by a number that says everything is fine. The first is a habit. The second is a false record.
Three heights, because the three gases do not share a layer. The layout below is a cross-section of a naturally ventilated grow-finish house: ridge outlet at the top, inlet windows low on both walls, four pens either side of a central alley, slurry channel under the floor.
| # | Position | Height | What it is for |
|---|---|---|---|
| 1 | Central alley, over the stock | 1.5 m | The air the animals actually breathe, and the number that belongs in the barn's own record. This is the probe the welfare audit reads |
| 2 | Just under the ridge | roof void | The reservoir. A gap between point 2 and point 1 is the roof loading up before the outlet opens — the earliest sign that the next calm hour will be bad |
| 3 | Above the slurry channel | 1.9 m | H₂S and CO₂ are heavier than air and start here. This is also where a person works when they clean the channel, which is why it is measured and not assumed |
| Item | Specification | Why this, not another |
|---|---|---|
| Ammonia & CO₂ transmitters | Modbus-RTU, RS485 NH₃ 0–100 ppm · 1 ppm CO₂ 0–5,000 ppm · 10 ppm mains powered, 24 VDC | Electrochemical and NDIR cells need continuous power and a serviceable position. Putting them on the wired bus instead of a battery node is what keeps them at 1 ppm resolution in a house that runs below 10 |
| Hydrogen sulphide node | LW301, LoRaWAN H₂S to hundredths of a ppm battery, IP-rated, on the channel | No cable crosses a slurry channel that gets pressure-washed twice a week. A radio node is the only thing that survives there without a conduit |
| Air temperature & humidity | MG300 T and RH in one body, on the same 60 s clock | Temperature is the veto input for every ventilation decision in winter, so it has to be measured in the same second as the gas, not read off the wall hygrometer afterwards |
| Controller and uplink | FBox-4G-G 4G · COM1 RS232/485/422 · COM2 RS485 · COM3 RS232 2 DI · 2 relay out · 3× Ethernet · SD | COM2 polls both gas transmitters at two slave IDs; the two relay outputs switch the stage-1 fan contactor and the inlet winch directly. A shed does not need a PLC cabinet to hold a threshold |
| Actuation | Relay 1 → stage-1 fans Relay 2 → inlet winch open / close 2 DI → winch limit switches | The inlet position is the part that fails silently. The two digital inputs confirm the winch actually reached its end stop, so "open the inlet" becomes a verified action rather than a command |
| Platform | ZONEWU IoT, hosted or on-premise | History, alarm ladder and device health in one place. On-premise when the farm's data is not allowed to leave the site |
The obvious design — one threshold, fans on, fans off — is the one that breaks a house. Ammonia falls the moment the fans start, the controller sees a clean number and stops them, the litter keeps releasing, and the house hunts around the threshold all night with the inlet winch cycling. The loop below is staged, waits for a sustained reading before it acts, and gives temperature a veto over the whole ladder.
| Condition | Action | Sustained | Reset at |
|---|---|---|---|
| NH₃ > 10 ppm | Stage 1: inlet to 30 %, stage-1 fans on | 5 min | 7 ppm |
| NH₃ > 18 ppm | Stage 2: inlet to 60 %, stage-2 fans on | 3 min | 14 ppm |
| NH₃ > 25 ppm | Full open, Major alarm, both contacts notified | 2 min | 20 ppm |
| RH > 75 % with CO₂ rising | Minimum-ventilation floor lifted one step | 15 min | 65 % |
| Any stage vs. temperature floor | Stage held closed if inlet air would drop the house below setpoint | Continuous | +1 °C above |
| Transmitter offline or cell drift > 15 % | Alarm, hold last known good value 15 min, then flag the gap | Immediate | Manual |
The veto is not a comfort setting. In a winter house every cubic metre of cold inlet air has to be heated by the animals' own body heat, and a fan that opens to clear ammonia at −5 °C outside puts the same animals into a cold draught — which is how a gas problem becomes a pneumonia problem. The rule above resolves the conflict the way a good stockman does: open the inlet a little and run the fan slowly first, and only escalate when the reading holds above the band for longer than the house can afford.
Both gas transmitters are polled on COM2 every 60 s; the H₂S node and the T/RH sensor publish on the same interval. Everything is time-stamped by one clock and pushed over 4G to the platform, which means the three heights are comparable rather than merely co-located. The FBox buffers to its SD card whenever the link drops and back-fills in order, so a 4G outage on a farm with one weak cell appears as a timestamp gap and never as a flat line that reads like a healthy house.
The relay state is published alongside the readings, not only the commands. That distinction is the whole value of the record: "stage 1 was commanded at 02:14 and the winch limit switch confirmed open at 02:15" is a fact about the building, while "stage 1 = on" is only a fact about the controller's intention.
A shed-side controller answers what the gas is doing now. The platform answers which node is still reporting, how good its radio link is, and what the house looked like at 03:00 on the night the stockman was off.
Device Center, full page, English interface — the shed's nodes as the platform sees them. Each card carries the live value (H₂S 0.021 ppm, temperature 26.3 °C, humidity 59 % RH), the provisioning state and the radio quality of that specific node (RSSI −47 dBm, SNR 13.5 dB against −87 dBm on the furthest one). In a steel-roofed house the radio number is not housekeeping: it is the difference between a node that reports through the season and one that goes quiet the week the roof sheets were replaced. Click to open full size.
Four things it does that a shed controller does not:
Live at iot.zonewu.com — a demo account is available on request.
| Check | Pass criterion |
|---|---|
| NH₃ vs. reference | ±2 ppm or ±15 % of reading, whichever is larger, at 10 and 25 ppm |
| H₂S vs. reference | ±0.1 ppm at the working point over the channel |
| Threshold to relay | ≤ 1 minute from the sustained condition being met, with the limit switch confirmed |
| Radio margin | Every node at RSSI better than −105 dBm and SNR above 5 dB at the worst position in the house |
| Service interval | Gas cell span 6 months · cell replacement 18–24 months · H₂S node battery 12 months · filter and inlet cleaning 3 months |
Contact: Qui
Phone: 18146178586
Tel: 18146178586
Email: qui@zonewu.com
Add: 1501-3, Building F03, Phase III, Software Park, Jimei District, Xiamen City, Fujian Province, China