An IoT Chicken Door


We got chicken and some chicken coop a while ago. This of course immediately created the need to be able to remotely open and close the chicken door when we are away, say, for dinner, and the chicken have entered the coop because it is getting dark and it is predator time.

So I designed a little aparatus hooked to the vertical sliding door of the coop. The core is an ESP32 microcontroller that runs an web page allowing us to open and close the door, plus some bells and whistles.

The ESP32 is hooked up to a BME280 climate sensor (not needed, just for fun) as well as a BH1750 light sensor, as well as a DC motordriver connected to a 30 cm DC actuator to open and close the door.

The specs:

  • 3 modes (manual-, time-based, light-based operation), independently selectable for opening and closing (e.g. open every morning at 8am, but close at night when the light is low).
  • This obviously requires a light sensor. This one has a BH1750. You can also set a delay. If the light has been below or above threshold for a certain number of minutes, the door moves.
  • BME280 for temperature, humidity and pressure
  • Manual opening and closing with two buttons at the device.
  • A INA219 current sensor that notices when the built-in end stops of the actuator have switched the device off, so the system knows when the door is fully open or closed.
  • Web interface for the settings and sensor readings.
  • Linear actuator with 30 cm range of operation, IP66 approved for outdoor application.

More technicalities as well as all the code and the board layout are on the project’s GitHub page.

And the control board


Leave a Reply

Your email address will not be published. Required fields are marked *