Zbotic Logo Zbotic Logo
  • Home
  • Shop
  • Sale
  • 3D Print Service
  • PCB Service
  • B2B
  • Blogs
  • Contact Us
0 0

View Wishlist Add all to cart

0 0
0 Shopping Cart
Shopping cart (0)
Subtotal: ₹0.00

View cartCheckout

  • Shop
  • About Us
  • Contact Us
  • Reseller
  • Blogs
020 69134444
1800 209 0998
[email protected]
Help Desk
Facebook Twitter Instagram Linkedin YouTube
Zbotic Logo Zbotic Logo
0 0

View Wishlist Add all to cart

0 0
0 Shopping Cart
Shopping cart (0)
Subtotal: ₹0.00

View cartCheckout

All departments
  • 3D Print Service
  • 3D Printer
  • Batteries & Chargers
  • Development Boards
  • Drone Parts
  • EBike parts
  • Sensor Modules
  • Electronic Components
  • Electronic Modules
  • IoT and Wireless
  • Mechanical Parts and Workbench Tools
  • Motors & Drivers & Pumps & Actuators
  • DIY and Robot Kits
  • Show more
  • Home
  • Shop
  • Sale
  • 3D Print Service
  • PCB Service
  • B2B
  • Blogs
  • Contact Us
Return to previous page
Home Home Automation & Smart Devices

Automated Pet Feeder with ESP32 and Servo Motor India

Automated Pet Feeder with ESP32 and Servo Motor India

March 11, 2026 /Posted byJayesh Jain / 0

An automated pet feeder with ESP32 and servo motor is a brilliant weekend project for Indian pet owners who travel frequently or have irregular schedules. With cats and dogs increasingly becoming beloved household members across Indian cities, ensuring timely feeding when you’re stuck in traffic or on a business trip has real practical value. This project uses an ESP32 to control a servo motor that dispenses food on a schedule — all manageable from your smartphone.

Table of Contents

  • Project Overview
  • Components and Shopping List
  • Mechanical Design and Food Hopper
  • Wiring Diagram
  • ESP32 Code with WiFi and Scheduling
  • Blynk App Integration
  • Home Assistant Integration
  • Frequently Asked Questions

Project Overview

This automated pet feeder has several key features:

  • Scheduled feeding times (up to 8 per day)
  • Remote manual feed trigger via app
  • Adjustable portion size via servo angle
  • Low-food level sensor using ultrasonic distance measurement
  • Feeding log with timestamps
  • Optional camera for live pet monitoring

Total project cost: ₹1,200–₹2,000. Commercial auto-feeders in India cost ₹3,000–₹15,000.

Components and Shopping List

  • ESP32 DevKit V1 (38-pin)
  • MG995 or MG996R servo motor (high torque, 11 kg·cm)
  • HC-SR04 ultrasonic sensor (food level detection)
  • PVC pipe (75mm diameter, 300mm length) — food hopper
  • 3D printed auger/dispenser wheel or plywood cutout
  • 5V 3A power supply (servo draws significant current)
  • DS3231 RTC module (for accurate time even without WiFi)
  • Small OLED display (optional, 0.96″ I2C type)
  • Project box or repurposed plastic container
Recommended: DC5V/8-80V ESP8266 WiFi Relay Module 2 Channel — Add a relay-controlled water dispenser alongside your ESP32 pet feeder for a complete automated pet care station.

Mechanical Design and Food Hopper

The dispensing mechanism is the most important part of the feeder. Two popular designs work well with Indian pet food (both dry kibble and pellets):

Auger Design (Most Reliable)

A spiral auger screw inside a tube rotates to push food forward and drop it into the bowl. Print the auger in PLA or PETG. The servo rotates the auger a fixed number of turns per feeding, giving consistent portion sizes. This design handles both small kibble and larger dog food pellets.

Rotating Disc Design (Simpler)

A disc with holes sits below the food hopper. Rotating the disc aligns a hole with the hopper outlet, dropping a measured portion. Simpler to build but less consistent for irregular-shaped food pieces.

Food Hopper

Use a 75mm PVC pipe (available at any hardware shop in India for ₹80–₹120 per metre) as the food hopper. A 300mm length holds approximately 500g of dry cat food or 300g of dog kibble. Seal one end with a PVC cap. Drill the hopper mounting holes to align with your auger tube.

Wiring Diagram

ESP32 Connections:

Servo Motor (MG995):
GPIO 13 (PWM) → Signal (Orange wire)
5V external    → VCC (Red wire)
GND            → GND (Brown wire)

HC-SR04 (Food Level):
GPIO 5  → Trig
GPIO 18 → Echo
3.3V    → VCC (use voltage divider on Echo!)
GND     → GND

DS3231 RTC:
GPIO 21 (SDA) → SDA
GPIO 22 (SCL) → SCL
3.3V           → VCC
GND            → GND

OLED Display:
GPIO 21 (SDA) → SDA
GPIO 22 (SCL) → SCL
3.3V           → VCC
GND            → GND

IMPORTANT: Power servo from external 5V supply,
not from ESP32's 5V pin — motor draws 500mA–2A!
Recommended: ESP32 with OLED Display Module — This integrated ESP32+OLED module saves wiring complexity. The built-in OLED shows next feeding time, food level, and last feed log directly on the feeder.

ESP32 Code with WiFi and Scheduling

#include <WiFi.h>
#include <ESP32Servo.h>
#include <RTClib.h>
#include <Preferences.h>

const char* ssid = "YOUR_WIFI";
const char* password = "YOUR_PASS";

Servo feederServo;
RTC_DS3231 rtc;
Preferences prefs;

// Feeding schedule: hours and minutes (24h format)
int feedHours[] = {7, 13, 19}; // 7am, 1pm, 7pm
int feedMins[] = {0, 0, 0};
int numFeedings = 3;
int portionAngle = 180; // Servo angle for one portion

void dispenseFeed() {
  Serial.println("Dispensing food!");
  feederServo.write(portionAngle);
  delay(1000);
  feederServo.write(0);
  delay(500);
  // Log feeding time
  DateTime now = rtc.now();
  Serial.printf("Fed at %02d:%02dn", now.hour(), now.minute());
}

void checkSchedule() {
  DateTime now = rtc.now();
  for (int i = 0; i < numFeedings; i++) {
    if (now.hour() == feedHours[i] && 
        now.minute() == feedMins[i] &&
        now.second() == 0) {
      dispenseFeed();
    }
  }
}

void setup() {
  Serial.begin(115200);
  feederServo.attach(13);
  feederServo.write(0);
  rtc.begin();
  WiFi.begin(ssid, password);
  // Set up web server for manual trigger
  // ... (web server code)
}

void loop() {
  checkSchedule();
  delay(1000);
}

Blynk App Integration

Blynk provides a quick way to create a smartphone interface for your pet feeder. The free tier allows up to 2 devices which is sufficient for this project.

  1. Create a Blynk account at blynk.cloud
  2. Add a new device and note your Auth Token
  3. In the app, create:
    • A Button widget (Virtual Pin V0) — Manual Feed Now
    • A Gauge widget (V1) — Food Level %
    • A Value Display (V2) — Last fed timestamp
    • A Time Input widget (V3, V4, V5) — Set feeding times

The Blynk library handles reconnection automatically, essential in India where WiFi connectivity can be intermittent. When WiFi is unavailable, the DS3231 RTC ensures scheduled feedings continue locally.

Home Assistant Integration

For more advanced users, integrate the pet feeder with Home Assistant using MQTT:

# configuration.yaml
switch:
  - platform: mqtt
    name: "Pet Feeder Manual"
    command_topic: "petfeeder/feed"
    payload_on: "FEED"

sensor:
  - platform: mqtt
    name: "Food Level"
    state_topic: "petfeeder/level"
    unit_of_measurement: "%"

# automation: Alert when food is low
alias: Low Food Alert
trigger:
  - platform: numeric_state
    entity_id: sensor.food_level
    below: 20
action:
  - service: notify.mobile_app
    data:
      message: "Pet feeder food level is low! Please refill."
Recommended: Uno WiFi R3 with ESP8266 — A beginner-friendly alternative to ESP32 for this project if you’re more comfortable with Arduino IDE. The built-in ESP8266 handles WiFi connectivity for Blynk and MQTT.
Recommended: 8 Channel Solid State Relay Module — Expand your pet care automation centre — control water heater for tropical fish tank, UV lamp timer, and ventilation fan all from a single ESP32 controller.

Frequently Asked Questions

What type of pet food works best with a DIY auger feeder?

Dry kibble (8–12mm diameter) works best with both auger and rotating disc designs. Larger dog food (15mm+) may require a wider tube and auger diameter. Avoid wet food entirely — it will clog and harbour bacteria.

How do I calibrate portion size?

Run the servo through its full range and measure the amount dispensed at different angles. For example, 90° rotation might dispense 25g and 180° dispenses 50g. Mark these calibration values in your code for consistent feeding.

What happens if WiFi goes down?

The DS3231 RTC module maintains accurate time independently of WiFi. Your scheduled feedings continue even during internet outages. The device reconnects to WiFi automatically when it becomes available.

Can I add a camera to watch my pet?

Yes. Use an ESP32-CAM module mounted above the food bowl. Stream video to your phone via the ESP32’s built-in web server or integrate with Home Assistant’s camera entity. This lets you verify your pet is eating normally even when you’re away.

Is it safe to leave this running for 2–3 days while travelling?

Yes, with proper setup. Use a quality 5V power supply (not a cheap charger), ensure the food hopper has enough capacity, and test the system for 1–2 weeks before your trip. Consider adding a backup power notification to alert you if power goes out.

Shop Home Automation at Zbotic →

Tags: automated pet feeder, blynk, ESP32, pet automation, servo motor, smart home India
Share Post
  • Facebook
  • Linkedin
  • Whatsapp
Photoresist PCB Making at Home...
blog photoresist pcb making at home uv exposure and developer 598034
blog profibus vs modbus vs ethercat industrial bus comparison 598058
PROFIBUS vs Modbus vs EtherCAT...

Related posts

Svg%3E
Read more

MQTT for Home Automation: ESP32 + Mosquitto + Home Assistant

April 1, 2026 0
MQTT is the backbone protocol of professional home automation systems. If you are building a smart home with multiple ESP32... Continue reading
Svg%3E
Read more

Curtain and Blind Automation: Stepper Motor Controller

April 1, 2026 0
Curtain automation is one of the most satisfying smart home upgrades you can build. Imagine your curtains opening automatically at... Continue reading
Svg%3E
Read more

Smart Doorbell with Camera: ESP32-CAM Video Intercom

April 1, 2026 0
A smart doorbell with a camera lets you see who is at your door from your phone, even when you... Continue reading
Svg%3E
Read more

Blynk IoT Platform: Control Arduino and ESP32 from Mobile

April 1, 2026 0
The Blynk IoT platform is the fastest way to control your Arduino and ESP32 projects from your mobile phone. Instead... Continue reading
Svg%3E
Read more

PIR Sensor Automatic Light: Save Electricity with Motion Detection

April 1, 2026 0
PIR sensor automatic lights are the simplest and most effective way to save electricity in Indian homes. By automatically turning... Continue reading

Add comment Cancel reply

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

Facebook Twitter Instagram Pinterest Linkedin Youtube

Get the latest deals and more.

Download on Google Play Download on the App Store

Call us: 020 69134444 / 1800 209 0998

Monday - Saturday 09:30 AM - 06:00 PM
For Technical Supports Email: [email protected]
For Sales / Enquiries Email: [email protected]

  • My Account

    • Cart

    • Wishlist

    • Checkout

    • My Orders

    • Track Order

    • My Account

  • Information

    • FAQs

    • Blogs

    • Career

    • About Us

    • Contact Us

    • Payment Options

  • Policies

    • Privacy Policy

    • Terms & Conditions

    • GST Input Tax Credit

    • Shipping Return Policy

    • E-Waste Collection Points

    • Our Sitemap

© Zbotic.in is registered trademark of Moxie Supply Pvt Ltd – All Rights Reserved
Login
Use Phone Number
Use Email Address
Not a member yet? Register Now
Reset Password
Use Phone Number
Use Email Address
Register
Already a member? Login Now