Arduino Harmless Mouse Trap You Can Build at Home
by CrazyScience in Circuits > Arduino
560 Views, 2 Favorites, 0 Comments
Arduino Harmless Mouse Trap You Can Build at Home
Hey guys in this instructables i will show a way to solve most of our household issues that is caused by mouse.
It is a most common thing that one of us atleast once faced by this tiny creature, Issues like eating up your favourite thing or chewing up of valuable things is a most common instance we might have gone through.
There are plenty of ways to get rid of this mouse but most of them cause a harm to them! Keeping that in mind i have made this mouse trap which is harmless and after you catch these you can release them later to the safe place giving them a second chance.
This mouse trap that we are building today can be made with simple materials, it works fast and the cost involved in building this is very less compared to other expensive mouse traps.
It is powered by arduino and 2 micro servos and to sense the mouse i used IR sensor, This can be powered by any usb source and as soon as the mouse comes to eat the food the trap activates and thus catches the mouse.
Every creature deserves to live on this earth, Even if it destroys your things have a great heart to set it free and give a second chance to live again!
There are many other ways to build this device, I went through multiple designs and finalised this thinking it is the best suited for this purpose.
I have given detailed instructions on building this mouse trap, Circuit and codes are available for anyone and also a video tutorial on showing the same.
Supplies
Arduino Uno
IR sensor
2 micro servos
Base (i upcycled from PLA filament Holder) you can use cardboard or plexiglass too
Jumper wires
Hot glue
Usb cable
Arduino IDE
Place where you saw/suspect mouse
Time to build these
Arduino Codes and Circuit Diagram
Here is the circuit diagram that i will use to build this project, The circuit is not too complex and uses only 3 components
i will start to explain the circuit one after the other
There are 2 servos that i will be using here, Two servos serves the same purpose and shares the common vcc and gnd pins
The signal pins from both the servo are connected to the digital pins d10 and d9, As far you are using the same components which iam using there is no need to use additional PCB for the circuit only the pins on arduino will do the job
After the servos are connected to the board we can proceed to make connections with IR sensor, These modules come with 3 pins, 2 for the power supply and one for the signal.
The signal pin is connected to d2 on the uno whereas the power pins are connected to Gnd and Vcc
After you make these connections on the uno we can head over to uploading the arduino codes, Dont worry all you have to do is copy and paste the below codes on the arduino ide and click on upload.
If you face any issues at the time of upload, Double check if the libraries are installed on the ide, if not you can install them first and later proceed with the upload.
After the program is on the board you can test it instantly by placing the hand infront of the sensor
Downloads
Test the Electronics
There are 2 options to power this project, One is by the default USB programming cable via any power bank and the other one is by external power source.
External power source is via an adapter, Both the ways are equally as good and you can choose any one as per the resource availability.
If the servo are not installed with horns, Insert it and secure them with screws.
Now if you place your hand infront of the IR sensor, Adjust the pot screws on the IR board untill the sensing distance is between 1 and 3cm.
when the object(in our case im using my hands) is detected the servos should move and be in the same position untill the circuit is completely turned off and on again.
This circuit is calibrated with correct speed and you can use the same codes, if you have any other ways to furthermore increase the response time let me know in the comments.
We can now headover to building the right frame for this project. i chose to use lightweight but strong materials.
You also can simplify this circuit with a Simple small PCB, Complete your electronic projects in the best way from PCBWay
Why them? They have provided me with the best PCB and The quality is just amazing compared to other providers in the market, They also have Color PCB printing Try it out.
Check out their 7th project design contest where you have a chance to participate and win exciting prizes.
Check Here for Rigid-flex Pcbs with this your circuit becomes flexible! I have added the images to this step kindly check.
A revolutionary solution that combines the best of both rigid and flexible circuitry to elevate your electronic projects to new heights.
With their expertise in advanced manufacturing techniques, they offer a seamless integration of rigid and flexible components, ensuring enhanced reliability, durability, and space-saving benefits.
Assembling Electronics
Electronics that were tested will now be put to practical use in this step, I will start by adding the IR sensor to the base first you can use hot glue or double sided adhesive for this purpose.
For the strong body, I made use of my PLA filament roll, You can use other alternatives like plexiglass or wood for this purpose.
Hide the IR sensor below this, This is because when the mouse runs over this sensor the servo will be activated, So i would suggest you follow this placing.
Use a decent amount of hot glue to seal all the edges properly, After this is dry mark the area where you will be placing the servos.
The distance between the 2 servos depends on the size of the cup that will hold the mouse, Use hot glue to seal the servos to this base.
Hide the wires using the glue so that there will be no problem with the circuit while the mouse is caught and make some movements.
Mechanism
The mechanism behind the working is simple, There are total 2 servos that will contribute to closing the lid when mouse is detected.
Since the servo horns are too small i will extend those with popsicle sticks.
start by attaching the horns to these sticks and later connecting them to servo shafts, Repeat the same step for other servo also.
Now make ak arch using plastic sheet, This plastic sheet i recycled from my tool box kit, one added advantage here is the plastic sheet is flexible and on the other hand it is strong also.
Use hot glue to stick these to the popsicle sticks, allow it to dry completely and now cover the sides using same material until the cup is totally covered from all end and looks like a case.
Working
The working is simple all you have to do is select the favourite food of your mouse!
Keep it on the panel, The lid opens up automatically when you power on this device, I will be using a power bank to power this mousetrap.
Keep this trap on the area where you expect the mouse, The mouse when it comes to have the food will be trapped by the lid and now the trap remains closed till the uno reset button is pressed or when the power supply is turned off and on again.
I kept the lid transparent to have a look for you guys, You can also replace this part with some other materials depend on the size of the mouse!
Working Video
Complete tutorial of making this project along with tricks to make the mechanism work is included in this video, If you still have any questions ask me in the comments and I will give you a reply soon.
Thanks and have a great build