An IoT-inspired smart office energy monitoring platform built with FastAPI, React, ESP32 (Wokwi), WebSockets, and a Discord Bot. The system provides real-time device monitoring, energy usage analytics, automated alerts, and interactive dashboards for efficient office energy management.
- 📊 Real-time Power Monitoring
- 💡 Live Device Status Monitoring
- 🏢 Room-wise Energy Summary
- 📈 Power Consumption History
- 📜 Device Activity History
- 🚨 High Power Usage Alert
- 🕔 After Office Hours Alert
- ⏱️ Long Running Device Alert
- 🤖 Discord Bot Integration
- 🖥️ Interactive Office Layout
- ⚡ ESP32 Hardware Demonstration (Wokwi)
- 🔄 Random Device Simulation
- 🗄️ SQLAlchemy + PostgreSQL
- React.js
- CSS3
- Chart.js
- FastAPI
- SQLAlchemy
- SQLite
- ESP32 DevKit
- Relay Modules
- Light & Fan Simulation
- ACS712 Current Sensor (Concept)
- Wokwi Simulation
- Discord Bot
- REST API
- Git
- GitHub
office-energy-monitor
│
├── backend/
├── frontend/
├── discord_bot/
├── hardware/
│ └── wokwi/
│ ├── diagram.json
│ └── sketch.ino
│
├── docs/
│ └── images/
│ ├── dashboard.png
│ ├── system_architecture.svg
│ ├── backend_architecture.svg
│ └── hardware_architecture.svg
│
├── README.md
└── requirements.txt
- Device Simulator
- Device Repository
- Device History
- Power History
- Room Summary
- Alert Engine
- Discord Notification Service
- Hardware Demonstration
Triggered when total power consumption exceeds the configured threshold.
Triggered when devices remain ON after office hours.
Triggered when a device stays ON for a long period.
!status
!usage
!rooms
!room Drawing Room
!room Work Room 1
!room Work Room 2
!alerts
!ping
The project includes a representative ESP32-based hardware simulation using Wokwi.
Components used:
- ESP32 DevKit
- Relay Modules
- LED-based Light Simulation
- Fan Output Simulation
- ACS712 Current Sensor (Concept)
- WiFi Communication (Architecture)
The hardware demonstrates how the software architecture can be integrated with a real IoT deployment.
cd backend
python -m venv .venv
# Windows
.venv\Scripts\activate
pip install -r requirements.txt
uvicorn app.main:app --reloadcd frontend
npm install
npm run devcd discord_bot
pip install -r requirements.txt
python bot.pyThe project includes:
- Modern React Dashboard
- Live Office Layout
- Power Usage Monitoring
- Room-wise Summary
- Device History
- Power History Chart
- Alert Dashboard
- Discord Bot Commands
- Wokwi Hardware Demonstration
- MQTT Integration
- Real ESP32 Deployment
- Smart Meter Integration
- Mobile Application
- AI-Based Power Consumption Prediction
- User Authentication
- Cloud Database Support
✅ Real-time Monitoring
✅ Interactive Dashboard
✅ Room-wise Analysis
✅ Alert Engine
✅ Discord Integration
✅ Hardware Demonstration
✅ Modular Backend
✅ REST API Architecture
Md. Meherab Hossain Talukder
- GitHub: https://github.com/meherabmehu
- LinkedIn: https://www.linkedin.com/in/meherab-talukder-5046a141b/
- Kaggle: https://www.kaggle.com/mdmeherabhossain
This project was developed for academic and hackathon purposes.
Please consider giving the repository a ⭐ on GitHub.
