IoT Pet Feeder to Feed Your Pets Remotely With Your Phone
2817 Views, 17 Favorites, 0 Comments
IoT Pet Feeder to Feed Your Pets Remotely With Your Phone
We have two cats in the office. On weekends, some colleagues would go to the office to feed them. But what if they don't have time? So, in order to ensure our cats get fed every day, we made a cat feeder this time.
All the things we used are listed below, and the code for this project is also provided in this article, so let's give it a go!
If you like our projects and tutorials, you can follow us on Twitter, Facebook, and Youtube for more interesting STEM projects and ideas.
Supplies
Electronics:
1 × Future board
1 × USB-C cable
1 × Robotbit expansion board
1 × 2KG servo
1 × 3D printed part
Tools:
1 × Hotspot (phone/ router)
1 × Android phone
1 × Glue gun
1 × utility knife
Other things:
1 × Storage box/ jar
some LEGO bricks
your pets
Draw Mind Maps
Overall mind map and the technical mind map.
Collect Information - Amazon
Generally, we should collect information before we start to make the project so that we can complete our project more efficiently and perfectly! Many people would buy a pet feeder to feed their pets, so we can find information about it easily.
The first station of information collecting: Amazon!
As shown in the first picture, almost all the cat feeders are in the form of bin + plate. Now we know what should our cat feeder look like.
We can also click to view the promotional pictures or videos to figure it out.
As can be seen from the above figures, the machine makes use of the gravity of the cat food. There is a rotating structure at the bottom of the bin to stir and push the cat food out.
Now we have a basic idea of the machine's structure.
Collect Information - Thingiverse
The second station of information collecting: https://www.thingiverse.com/
Thingiverse is a global 3D model sharing website, which shares a variety of interesting and fun models. You can first go and see if there is a cat feeder model, then we don't need to model but just print it directly (Sometimes we can be "lazy" ;)
Many people have shared their models on the website, you do can print them directly, but the 3D printer we made before may not be big enough for them. Also, the models they share all include their special items, such as bottles with a strange shape, which we definitely do not have. So we decided to make a 3D model by ourselves.
From the website, it seems that the easiest structure of the cat feeder is of the screw form, so we will model according to this form.
Which 3D Modeling Platform Should I Use?
There are many 3D modeling platforms, within which Tinkercad may be the easiest platform to master for students. It has an enjoyable interface and is very useful if used for simple modeling or teaching.
However, for more complex projects, Fusion 360 may be a better option.
Fusion360 is a 3D modeling platform launched by Autodesk. This software is very popular and is free for personal (non-commercial) and educational users, so it has a very broad mass base.
If you have never tried this type of platform before, you can find various tutorials on Youtube about Fusion 360 like this one here.
Modeling Draft
Okay! Let's get started. First, we draw our structural sketch.
Fusion 360 Modeling
Then we model in the Fusion360 according to what we drew.
The attached 3D model file can be opened directly. One of the magical parts of Fusion 360 is that you can see the author's modeling process at every step, like a video player.
3D Printing
After exporting the model, we perform 3D printing. After one night of printing, we assemble the 3D printed parts, storage boxes, and Lego structural parts together.
Dig a Hole on the Storage Box
Use a utility knife to dig a round hole at the bottom of the storage box (55.6mm in diameter)
Glue
Mix AB glue to glue the printed parts.
Assemble Everthing
Assemble Future board, Robotbit, and 2KG servo together.
Register IoT MQTT Topic
- Log into the Kittenbot IoT server: iot.kittenbot.cn (It's in Chinese but don't worry! It's easy to use, just follow the instructions)
- Register a topic, my topic name is CatFeeder (You need to register another unique name)
- It's not that hard, right?
If you cannot get the same result, please check
- Whether the Future board has connected to WIFI, if so, the IP address will be shown on screen;
- Whether the 18650 battery of Robotbit is powered, and the switch has been turned on;
- Whether the name of the program is the same as that of the MQTT server applied.
Make a Flowchart of the Cat Feeder Program
It would be easier to write the program if we draw the flowchart first.
Write the Program
Write a graphical program with Kittenblock according to the flowchart.
You need to modify two things:
- Change your WIFI name and password
- Change the topic name (replace my CatFeeder)
Program Download:📎Cat Feeder Program.zip
Download the Program to Future Board
Choose Firmware → Connect → program → switch to coding → download
MQTT Send Message
The Kittenbot MQTT server also has function that can send messages directly through the webpage (the webpage is a sub-device of MQTT)
If nothing goes wrong,
- When you send 1 to the corresponding topic (CatFeeder here), the machine starts feeding!
If you cannot get the same result, please check
- Whether the Future board has connected to WIFI, if so, the IP address will be shown on screen;
- Whether the 18650 battery of Robotbit is powered, and the switch has been turned on;
- Whether the name of the program is the same as that of the MQTT server applied.
Kittenbot WeChat Mini Program Remote IoT Control
- Search "Microbit Controller" in Wechat
- Choose the IoT function
- Type in your topic name, and click "subscribe"
- Type in 1 in the topic content, then click "send"
Test It Out!
Check out the final effect!
Improvements
So many people have commented that their pets may knock down the feeder and get the food inside the box, so we made some improvements!
Here's the look.
Replace the Container
We replace the previous box with this jar because apparently, our pet cannot open this type of lid.
Make It Impossible to Be Knocked Down
As you can see in the picture, we add a black thing at the bottom. We don't know what it is although it's been put in the corner of our office for so long. We used it just because it's really heavy, so we stick the pet feeder to it. Now our cats are not able to knock it down.