I did some research online and decided to create an "Automated Following Trash Can" myself. And now, I finally have my very own trash can that follows me wherever I go! It's amazing, whenever I need to dispose of something, the trash can is right there by my side, ready to take care of it.

The best part is that the project was super simple to make. I finished it in just half a day!

In this project, the main components I used were Raspberry Pi Pico and Arduino. Want to know how I did it?

Check out this DIY trash project (author is Elecrow) from the Elecrow project community!
https://www.elecrow.com/share-projects.html
Explore more projects, codes, tutorials and anything else here!

Supplies

Raspberry Pi Pico x1 --->I use it as the main controller

Buck Converter Module x1 --->Since the maximum voltage that all the hardware I'm using can withstand is 5V, and the battery I currently have is 7.4V, I have decided to use a voltage regulator module to help me provide a stable 5V power supply.

L9110 Motor Driver Module x1 --->This is a very useful module that helps me to drive the wheels.

Infrared Proximity Sensor-GP2Y0A21YK0F x2 --->I need to use two of these modules because I need to use them to detect if the person it's following is making a left or right turn. When a left turn occurs, the infrared module fixed on the left side will detect an object, while the one on the right will not. At this point, the main control chip will control the trash can to turn left.

HC-SR04 Ultrasonic Sensor Module x2 --->I use it to detect the distance between the trash can and the person it's following. When the distance exceeds 20cm, the wheels of the trash can start moving, trying to maintain a distance of 15-20cm from the person it's following.

Robot Car Chassis x1 --->If you want to make the trash can move, the easiest way is to give it a small car chassis!

Useless Box x1 --->This is just a random cardboard box I found, but you can use any small box of your choice. Any shape will do.

Battery x1 --->Since I only have a 7.4V battery, I have to use it as the power source for my entire project.

SG90 Servo Motor x1 --->This servo module helps me to open the lid of the trash can. It's very useful!

Switch Button x1 --->This switch is what I use to control the power on and off.

Breadboard x1 --->I also included a breadboard in my setup. While some may prefer to skip it for a messier setup, I find it very useful for wiring and organization. That's why I decided to use it.

Dupont Wires xN --->This is something we use very frequently, so please prepare more of them if possible.

Step 1: Make a Cardboard Box for Our Car

First, find a cardboard box that is roughly the same size as the robot car chassis. Then, use scissors to cut holes on the bottom of the cardboard box for the three wheels and motors of the car. This process requires extreme caution and attention to safety. It's best to measure and cut slowly, so as not to cut too much or accidentally damage the box.After making the box, we can place the robot car chassis inside it and use screws and nuts to secure the chassis to the cardboard box.

Step 2: Connect the Circuit According to the Circuit Diagram

If you take a look at the circuit diagram for this project, you'll see that it's actually pretty simple. You only need 5 modules, and there are only 14 wires to connect (not counting the power and ground connections). Once you've connected the wires, you just need to fix the modules in place.

I attached two infrared proximity sensor modules to the left and right sides of the cardboard box to detect if the object being followed is turning left or right. Then, I fixed the ultrasonic sensor module in the middle of the front of the cardboard box to detect the distance between the car and the object in front of it. I even made two holes in the box to make it look like a cute pig's nose!

I...

看更多 »