. IoT Smart Energy Meter with Billing System(Arduino UNO Based | High-Tech | IEEE Level Project) ~ SmartElectronicsDIY

IoT Smart Energy Meter with Billing System(Arduino UNO Based | High-Tech | IEEE Level Project)

 

🎯 Project Objective

To measure real-time electricity consumption, calculate automatic billing, and send data to cloud/mobile using IoT. This system reduces manual meter reading and power theft.











🧠 Technologies Used

  • Arduino UNO

  • IoT (ESP8266 WiFi Module)

  • Embedded Systems

  • Cloud / Mobile Monitoring


🧩 Components Required

ComponentQuantity
Arduino UNO1
ESP8266 WiFi Module1
Energy Meter Module (ACS712 / PZEM-004T)1
16x2 LCD (I2C preferred)1
Relay Module1
Buzzer1
Load (Bulb/Fan)1
Breadboard1
Jumper WiresAs needed
Power Supply (5V)1

🔌 Pin Connections

🔹 Energy Sensor (ACS712)

  • VCC → 5V

  • GND → GND

  • OUT → A0

🔹 ESP8266

  • VCC → 3.3V

  • GND → GND

  • TX → D2

  • RX → D3

🔹 LCD (I2C)

  • SDA → A4

  • SCL → A5

🔹 Relay

  • IN → D7

  • VCC → 5V

  • GND → GND

🔹 Buzzer

    • → D6

  • – → GND


⚙️ Working Principle

  1. Energy sensor measures current consumption

  2. Arduino calculates power (W) and energy (kWh)

  3. Bill amount calculated automatically

  4. Data displayed on LCD

  5. Energy data uploaded to IoT cloud

  6. User monitors usage via mobile/web

  7. If bill limit exceeded → Relay cuts supply


🧮 Billing Formula

Power (W) = Voltage × Current Energy (kWh) = Power × Time / 1000 Bill = Units × Cost per Unit

💻 Arduino Code (Energy Meter + IoT)

#include <LiquidCrystal_I2C.h> #include <SoftwareSerial.h> LiquidCrystal_I2C lcd(0x27,16,2); SoftwareSerial esp(2,3); float current; float power; float energy = 0; float costPerUnit = 6.5; // ₹ per unit float bill; unsigned long lastTime = 0; void setup() { lcd.init(); lcd.backlight(); esp.begin(9600); Serial.begin(9600); pinMode(7, OUTPUT); pinMode(6, OUTPUT); lcd.setCursor(0,0); lcd.print("Smart Energy"); lcd.setCursor(0,1); lcd.print("Meter System"); delay(2000); } void loop() { int sensorValue = analogRead(A0); current = (sensorValue - 512) * 0.026; power = 230 * current; unsigned long now = millis(); energy += power * (now - lastTime) / 3600000.0; lastTime = now; bill = energy * costPerUnit; lcd.clear(); lcd.setCursor(0,0); lcd.print("Units:"); lcd.print(energy,3); lcd.setCursor(0,1); lcd.print("Bill:Rs "); lcd.print(bill,2); if(bill > 1000) { digitalWrite(7, LOW); // Cut supply digitalWrite(6, HIGH); } sendToCloud(); delay(2000); } void sendToCloud() { esp.println("AT+CIPSTART=\"TCP\",\"api.thingspeak.com\",80"); delay(2000); String data = "GET /update?api_key=YOUR_API_KEY&field1=" + String(energy) + "&field2=" + String(bill); esp.print("AT+CIPSEND="); esp.println(data.length()+2); delay(1000); esp.println(data); }




🌐 IoT Dashboard

You can use:

  • ThingSpeak

  • Blynk

  • Firebase

  • AWS IoT

Displays:
✔ Units Consumed
✔ Live Bill
✔ Monthly Report


🚀 Applications

  • Smart Homes

  • Electricity Board

  • Industries

  • Hostels & Colleges

  • Smart Cities

0 comments:

Post a Comment