Inspiration
As a dog owner, I wanted to build something that would keep my dog engaged and get him up and moving when I was out of the house.
What it does
It's all in the name - the Automatic Dog Treat Dispenser detects when your dog approaches the unit and dispenses a treat. The owner can set the interval at which they want their dogs to receive a treat for any amount of time from 0 seconds to 1 hour via the dashboard.
When the ultrasonic monitor detects a distance of less than 50 and the last treat was dispensed longer ago than the set interval, the LED will turn green and a servo motor will turn a piece of the casing that pushes the treat into the dispensing tube. If it has not been enough time since the last treat, the LED will turn red.
These actions are reflected on the Adafruit dashboard which displays the number of treats dispensed in the last 8 hours, the current delay interval (and the slider to change it), and the LED color from the last attempt.
How we built it
Design Process / Iterations
I first built the casing and moving pieces out of cardboard in order to test the code and perfect the measurements. Once that was working, I had the final pieces laser cut to create the device. The RGB LED was also a final iteration addition as I noticed it was difficult to tell whether the device was not working or whether the time interval was in effect.
Technology Description
Parts used:
- Adafruit Feather Huzzah
- Ultrasonic sensor
- RGB LED
- 2 resistors
- Servo motor
- Arduino Uno
- Breadboard
- Wires
- External power source & connecting cables
- Lasercut casing
- Vinyl tubing
Please see the photos for a schematic and Github for the code.
Challenges we ran into
One major challenge was adequately powering all of the components. Because the Feather board could not provide enough power for the servo motor, I tried using the 9V battery and power module. That provided very inconsistent results and the motor would stop running for no reason. Eventually, I switched to powering the motor using the Arduino Uno (with no code uploaded, just as a power source) and that yielded somewhat more consistent results.
Building the casing and aligning the moving pieces was also challenging, especially figuring out how to create a holder for the treats before they are dispensed that would not lead to the device getting jammed. I figured out that a long narrow container that left the treats stacked on top of each other was the way to go and used card stock to create it.
What we learned
- Inconsistency in function can stem from power sources - even when the software and hardware are setup correctly.
- Adafruit dashboards can be used to transmit data back to the device and can write to feeds, not just display their values.
Next steps
If I were to continue working on this, I would want to add a weight sensor that detects whether the treat container is empty and to find a more reliable power source for the servo motor.
Log in or sign up for Devpost to join the conversation.