Simple IoT Monitoring — Chicken Farm with ESP32 & MQTT

Created: August 2023

A simulation of an IoT monitoring system for a chicken farm environment, built during an Edspert intensive bootcamp. The system uses an ESP32 microcontroller with multiple sensors connected to a HiveMQ MQTT broker. On the server side, I built a custom backend from scratch in Go that acts as both an MQTT subscriber and an HTTP server serving a REST API and Web UI.


What I Built

I was solely responsible for the entire backend server, which handles:

  • MQTT Subscriber — connects to HiveMQ and listens for incoming sensor data published by the ESP32
  • HTTP API Server — exposes sensor readings over a REST API
  • Web UI — a simple real-time dashboard served directly from the Go server

The hardware schematic and Arduino firmware were handled by my teammate Muhammad Jumi'at Mokhtar.


Team

NameRole
Luthfi YufajjiruBackend server (Go) — MQTT subscriber, HTTP API, Web UI
Muhammad Jumi'at MokhtarHardware schematic & Arduino firmware
Nayaka BhagaskaraTeam member
Bagas IsadewaTeam member
Syarif HidayatullahTeam member
Hafid Syaidul AfnanTeam member

Stack

LayerTechnology
MicrocontrollerESP32
FirmwareArduino (C++)
Message BrokerHiveMQ (MQTT)
Backend ServerGo
SimulationWokwi
ProgramEdspert Intensive Bootcamp IoT

Architecture

ESP32 + Sensors
      │
      │ MQTT publish
      ▼
 HiveMQ Broker
      │
      │ MQTT subscribe
      ▼
 Go Server ──── HTTP API ──── Web UI

Links