Dispense Dog Treats Around Your House Intelligently with This Autonomous Robot
John Klein's robot uses a suite of sensor modules to move within hallways and rooms to dispense dog treats wherever possible.
A simple premise
Even though tossing out treats for a pair of dogs can be fun at the start of the day, doing this repeatedly could become distracting and more of a chore than an enjoyable experience. To address this problem, John Klein on YouTube created a large robot that can autonomously move throughout the house and leave treats for the dogs to find, thus leaving the user free to perform other tasks.
Using SLAM for navigation
In order for the robot to move on its own, it first needs a method for finding its way around a space and remember where it has been. Klein based his system on this one from automatic addison, which uses a lidar module, a Jetson Nano, and the Hector-SLAM software module. In essence, the lidar module takes 5,000 distance readings per second by quickly spinning a laser emitter and timing how long it takes for the light to reflect off of a surface. From this generated point-cloud, the software is able to piece together a map that contains the areas which are free and those which have an obstacle in the way, such as a wall or table. This means the robot can roam around the house while continually picking up new data and storing it, therefore making the map grow more detailed over time.
The robotics platform
With the navigation system figured out, Klein then needed a way to dispense treats around his house. The platform he came up with is driven by a Raspberry Pi that is connected to the RPLIDAR module and runs the Hector-SLAM program as described previously. Mobility-wise, the robot has just two wheels that are independently driven by DC motor + encoder modules and a KS0377 Ketestudio Balance Car Shield that fits onto an Arduino Uno. When the Pi is done mapping the area and receives the "dispense" command, it tells the Uno how to move the motors.
Dispensing treats
The final step of this project was creating the treat dispensing mechanism that would be able to carefully drop a treat or two near a dog. Klein came up with a pair of "arms" that are each a single bucket that holds a few treats. When the command is sent to the Pi, it in turn sends a command to the PCA9685 PWM controller that rotates a servo to invert the bucket and dump the treats onto the ground. As seen in the video, the robot somewhat hilariously backs up with too much speed and tips over, although its mission could be considered a success.
Embedded Software Engineer II @ Amazon's Project Kuiper. Contact me for product reviews or custom project requests.