Automatic Laser Cat Toy
January 24, 2022
Automatic Laser Cat Toy
This was my first full Arduino Project that I have attempted to do. I bought my first Arduino Diecimila probably 15+ years ago to learn on because I wanted to use it on an ROV but never got that far with it besides making some LED’s blink. After making a few projects with Pi’s and everyone telling me I should have just used an Arduino I finally decided to give a project a try with one. This Christmas I looked into buying one of those Automatic Laser Cat Toy’s you see on Amazon but all the reviews I read didn’t inspire confidence in purchasing one so I decided… how hard could it be to make my own?
I already had all of the major parts on hand that I needed. I had plenty of servo’s from my R/C days, the Arduino Nano was salvaged from a cheap laser engraver/cutter that I changed the control board on to use better software, and the laser I had laying around from a firearm project.
The first step was to hook everything up using a bread board to try and figure out how to code to make the servos move at random positions and speeds.
After a little help from Google I was able to figure out the code to make the servos do what I wanted to do.
The Code
With the code working I then designed the actual mechanics of the actual laser setup in CAD. (Fusion 360)
Few more design pictures.
The overall design.
Next it was just a matter of 3D printing all of the parts of the housings and servo mounts. I tried to keep things as simple as compact as possible.
The first step in assembly was to mount the Pan servo using a couple of 2-56″ screws. There are holes in the bottom of the base to allow access for the hex wrench to tighten the screws.
Next it was time to mount the Nano. Being a knock off Nano it doesn’t have mounting holes in the board so I just designed notches the board can slide into.
The other end of the board will be retained with this clip and screws.
Here you can see the mounted Nano. It is mounted upside down so I marked the pins that I will be using with a bit of paint.
Next a servo horn for the pan servo was slid in and super glued to the tilt servo mount.
That tilt mount/servo horn is then secured to the pan servo using a small screw.
The tilt servo can now be secured to the mount, again using 2-56″ screws.
The cover for the tilt servo is held in place with magnets. I did this encase anyone tried to lift the finished toy by the cover piece it will come off instead of putting undue stress on the servo horn holding it all together.
Now the Laser mount can be slide onto the tilt servo horn. (this is friction fit only)
The laser module is also just friction fit into the mount.
After feeding all of the servo wires into the housing I rewired the power wires of both of the servos into single DuPont connectors so they can connect to the single pins on the nano.
Then I just had to connect all of the wires to the correct pins of the Nano. The positive + servo wires (red wires) connect to the 5V pin, The negatives – (brown wires) to GND, and the signal (Yellow wires) connect to pins D9 & D10.
The laser draws hardly any power so it gets connected to the Nano too using the 3.3V pin and the other GND pin.
Time for a quick test.
The cover is is secured with magnets (not shown).
The last thing I did was to add rubber feet to the bottom to keep it from sliding around if the servos move to fast.
I planned on powering this whole setup with just a phone charger type power bank but…
… I guess the whole setup doesn’t draw enough power so the power bank won’t stay on for more than 30 seconds. I think peak was .35A at best but it only stays there for a second while a servo is moving before dropping to an avg. of .07A. I could probably throw a resistor in the mix somewhere but for now I’ve just been using a larger power bank with two outputs and charging my phone at the same time.
The Finished Project.
Rear View
Left Side
Front View
Quick GIF of it in action until I get some footage of the cat’s reaction.
All Information, Pictures, and Material is copyright © 2022 by Stephen Thone and may not be used for any personal or commercial purposes without the consent of the author. All rights reserved. The Author makes no guarantees or warranties as to the accuracy or completeness of, or results to be obtained from accessing and using the Information herein.