Automatic feeder for cats.
- Web control panel.
- Anti-stuck system.
- ~1 litre tank for cat food.
- Feeding schedule.
- Feeding amount in grams.
- Worldwide control via MQTT protocol.
- Android/IOS app for controlling the feeder.
- 1x ATmega328P (arduino nano)
- 1x ESP8266
- 1x DVR8825 (driver)
- 1x NEMA17 (stepper motor)
- 1x RTC DS1307 (real time clock)
- 1x DC plug 2mm
- 2x 220Ω resistors
- 2x 3mm leds
- 1x v7805 (voltage regulator)
- 3x 470µF 16v capacitors
- 1x 10µF 6.3v capacitor
- 1x HDR-2.54 female 1x4
#define WIFI_SSID "wifi_network_name"
#define WIFI_PASSWORD "wifi_password"
Replace wifi_network_name with your wifi network name and wifi_password with your password.
Note
You can connect to web control panel by entering ESP's IP address into your browser. Here is an instruction how to find ESP's IP address:
- Connect ESP to a computer via USB.
- Open serial monitor.
- Restart ESP and you should see IP address being printed in serial monitor.
#define SM_IMPULSE_DELAY 30
#define SM_FORWARD_STEPS 100
#define SM_BACKWARD_STEPS 94
#define SM_MICRO_STEPS MICRO_STEPS_32
#define SM_DIRECTION CLOCKWISE
SM_IMPULSE_DELAY - delay in microseconds before sending signal to driver. (Speed of motor)
SM_FORWARD_STEPS and SM_BACKWARD_STEPS - these are used for anti-stuck system. Intead of rotating all the time forward motor makes SM_FORWARD_STEPS steps forward and SM_BACKWARD_STEPS steps backward. This makes motor vibrate (if frequency (AKA SM_IMPULSE_DELAY) is small enough and motor is in microstepping mode), so pieces of cat food can't be stuck.
Caution
Make sure that SM_FORWARD_STEPS > SM_BACKWARD_STEPS
SM_MICRO_STEPS - number of microsteps per one full step. Enum values:
enum MOTOR_MICRO_STEPS {
FULL_STEP,
MICRO_STEPS_2,
MICRO_STEPS_4,
MICRO_STEPS_8,
MICRO_STEPS_16,
MICRO_STEPS_32
};
SM_DIRECTION - direction of motor rotation. Enum values:
enum MOTOR_DIRECTION {
ANTI_CLOCKWISE,
CLOCKWISE
};
Tip
If motor rotates in wrong direction (screw moves cat food towards motor) then just reverse motor direction in code!
Note
Photos were took while development so, circuit is assembled on a breadboard, not on PCB.