Kit-Cat Clock's Eyes Follow You

by bekathwia in Circuits > Arduino

3350 Views, 51 Favorites, 0 Comments

Kit-Cat Clock's Eyes Follow You

KitCatClock.00_04_24_10.Still001.jpg

Today we’re modifying a Kit-Cat Klock to make the eyes follow you around the room.

The idea is simple– make the cat’s eyes follow you. The clock’s eyes and tail movements are controlled by a long lever arm.

So I needed to insert my own control over this lever arm. I used a servo motor, hot glue, and zip ties to affix the lever arm to the servo and the servo to the clock, then severed the connection between the part of the lever arm connected to the eyes and the part connected to the tail.

Supplies

01_Product.jpg

Materials:

Tools:

I first tried out the DFRobot Huskylens vision board for this project, which is super easy to use and has a built-in screen. But because I wanted to get the camera into the nose of the Kit-Cat Klock, and there’s no need for a screen nor a lot of room for one, I opted to use the Seeed Grove AI Vision board instead, along with a Xiao RP2040 board. Regardless of the vision board, a camera with a long cable is required to feed into the tight space that is the cat’s nose. The DFRobot and Seeed vision boards use the same camera as each other, and I found replacements with longer cables available on Amazon. I bought the wide-angle version and tried that out first. But I ended up switching back to the normal viewing angle camera after trying it out.

Watch Video

This Clock's Eyes Follow You

This is my project for this year’s Makers Secret Santa, which I’ll be making for my friend Xyla Foxlin.

Installing the Camera in the Nose

06 punch.jpg
07 step drill.jpg
05 camera closeup.jpg
04 camera install.jpg
08 painters tape.jpg

To fit the camera in the nose, I used a center punch to make a divot in the center of the nose, then a small drill bit to make a pilot hole. I only have one clock so this helps avoid cracking it.

Then I used a step drill on my drill press to make the appropriate-sized hole and hot glued it in place from the inside, being careful not to get any on the eyes.

This was the trickiest part of this project, and I ended up using some painter’s tape to help hold it in place from the front, some tweezers to hold it in place from the back, and some canned air to rapidly cool the hot glue. I didn't permanently install the camera until I was happy with its field of view (after the next step).

Circuit and Code

09 inside.jpg
10 eye test.jpg
11 code addition.jpg
12 seeed.jpg
16 swinging tail.jpg

This vision board is designed to work with the Xiao board footprint, so my little RP2040 board fits right in. Then I went and added some wires for the servo motor, and I accidentally lost one of the passive components during soldering. After a clumsy attempt to reattach it, I decided to stop and test that it still worked before I made it even worse.

First I loaded up a test sketch to control just the motor, and that worked fine. I adjusted the servo positions to match the observable range of the eyes without over-extending to one side or the other. Next, I fired up the object recognition Grove AI Vision example code for Arduino, and it successfully connected to the camera module, so I guess that capacitor wasn’t so important after all.

Then I added the one line of code I had to write for this project– setting the motor position relative to the X position of the detected object. It worked a little too well. The eyes darted to their new position way too fast. So I wrote a few more lines of code to have the servo move in timed increments to its new position, so it animates there at a controlled speed.

To see what the camera sees, you can plug in an additional USB cable to the vision module and load up this special site that communicates with it over serial. I noticed that my wide angle capturing windows and lights impeded its ability to detect people. I adjusted the camera angle but it was still not working as well as I’d like, so I decided to switch back to the regular viewing angle camera. The wide-angle one would be great for projects that are close up to your head, not projects that need to see you from across the room.


Final Thoughts

15 complete.jpg
14 UV.jpg
17 packaging.jpg

One thing I learned after fiddling with the camera repeatedly is that the white paint on the front is alcohol soluble. I used alcohol to release the hot glue bond for replacing and repositioning the camera, but after I figured out why there was paint on me all of a sudden, I was a little more careful with my application.

After I was happy with the camera position, I glued it permanently using some UV gel nail polish.

The object detection still gets distracted by big windows, so I had to try a few different mounting locations before I found one that tracked me consistently. But it works! It’s just the right combo of creepy and cute. And it doesn’t connect to the internet, so it’s safer to put up in your home than any security camera.

I thought I could let the tail animate as it was originally intended, which is driven by an electromagnet inside the clock base. But since I disconnected the top half, the bottom half isn’t as balanced anymore, so the swinging tail swings farther and hits the sides of the body. I taped the tail post in place so the tail doesn’t do anything now, and Xyla can untape it if she wants the tail to wag later.

I packed up the modified Kit-Cat Klock in its original box and included a long USB cable and AC adapter for plugging it in. I left the clock circuit, powered by two batteries, alone so it can function separately if desired. I included some video instructions since it doesn’t boot right up– maybe that capacitor I lost is to blame, but the reset button has to be pressed after the board already has power for the vision module to boot up. I hope she likes it! Go see her open it on her channel.