James Bowman's Chicken Coop Gets an IoT Upgrade From a Raspberry Pi Pico and LoRa Module

Solar-powered monitoring system tracks lighting battery level, temperature, and whether the door is open or shut.

Engineer James Bowman has given his chicken coop an Internet of Things (IoT) upgrade — adding a Raspberry Pi Pico and LoRa module to keep an eye on the charge levels of its solar-powered lighting system as well as environmental conditions.

"Our coop, home to about 30 chickens, is solar powered," Bowman explains. "A small panel charges a lead-acid battery which runs the 12V lights. I'd like to keep an eye on the battery state, and my spouse has had a long-standing request for a confirmation each night that the coop door is closed."

The solution: an IoT coop monitor, powered by the Raspberry Pi Pico development board and its RP2040 microcontroller. To this, Bowman added three sensors — one to monitor the voltage of batteries connected to the coop's solar panels, one to monitor the temperature inside the coop, and a magnetometer to detect whether the coop door is open or closed — and a LoRa wireless communication module to report data.

"Every ten seconds the Pico wakes up, reads the sensors, and sends a JSON packet over LoRa," Bowman explains, "which the house server records and graphs. Instead of using a switch for the door sensor, the whole assembly is mounted on the coop door, and the magnetometer senses the board's orientation."

Data gathered from the system is graphed on sparklines, designed for a minimalist appearance: "I ended up plotting all the data as a 24-hour sparkline with min and max values highlighted," says Bowman. "There's no scale, or even current value, because the minimum and maximum are the important functional elements. Assembling these charts into the house dashboard gives an all-business display of the current state of our homestead."

More details on the project are available from Bowman's newsletter.

Gareth Halfacree
Freelance journalist, technical author, hacker, tinkerer, erstwhile sysadmin. For hire: freelance@halfacree.co.uk.
Latest articles
Sponsored articles
Related articles
Latest articles
Read more
Related articles