Embedded systems and stuff

Stepper motor controlled zoom and focus of the Raspberry Pi High Quality camera telephoto lens (work in progress)

Project status: This is a work in progress. Please support me on Patreon if you’d like to see me continue to work on it: https://www.patreon.com/chrislaplante

This project is something that I started in September 2020. My original intent was to use the High Quality camera, telephoto lens, and a handful of 3D printed parts to make a “cheap” bird feeder cam. Long story short, 4 months into the project I got impatient and ended up buying an off-the-shelf camera (the excellent AXIS P1448-LE).

Nevertheless, I think many in the community would be interested in the project so I do have interest in continuing it. Here’s a brief overview of what I’ve accomplished so far:

  • Created Fusion 360 models for the telephoto lens and High Quality camera.
  • Designed 3D printed spur gears that fit around the zoom and focus wheels of the lens, and 3D printed worm gears to drive the spurs.
  • Designed a small PCB with QRE1113 infrared reflectance sensors – the intention is for these to encode the position of the spur gears (which would have some black lines drawn on them using a Sharpie).
  • Designed an assembly that mounts the High Quality camera, lens, stepper motors (NEMA-8 size), and optical sensor PCBs.

Here’s a render of what the whole assembly looks like. A few screws are still missing, such as the ones that attach the optical sensor PCBs to the brackets. Click to enlarge.

Another view, showing how the optical sensor PCB is designed to sit just above the spur gears (click to enlarge):

Check out this gallery for more Fusion 360 renders:

All the parts are either 3D printed or come from McMaster-Carr.

Some of my most recent thoughts on the project:

  • I’m not convinced that the optical sensors are the best way of encoding position. An early design used cheap rotary encoders (Bourns EAW0J-C24-AE0128L) but I found they were too stiff for the stepper motors to drive and I really didn’t want to go bigger than NEMA-8. Here’s what it looked like:

I’m interested in coming up with a better solution for position encoding that doesn’t require manually marking each gear with a Sharpie.

  • For that matter I haven’t actually tested the optical PCB at all yet.
  • I have not decided yet whether to try and control all of this from a Raspberry Pi, vs. have another microcontroller in the middle that handles some tasks such as position encoding. I see benefits with both approaches.
  • My first choice for a stepper motor driver (Adafruit Stepper Motor Bonnet) tries to drive these steppers with too much current, causing them to overheat like crazy. I have purchased some Pololu motor drivers that feature current limiting but have not tested them yet.

So that’s where things stand.

If you’d like to see this project move forward, I could really use your support on Patreon! https://www.patreon.com/chrislaplante. I’m working on setting up a private Discourse server which will be a great place to discuss this project (and my others). Access to that Discourse server is unlocked by joining the second tier (or higher) of my Patreon. Thanks in advance for your support 🙂

P.S. You can check out my bird cam feeder stream here: https://www.youtube.com/watch?v=w87diZ7PfiI

2 responses to “Stepper motor controlled zoom and focus of the Raspberry Pi High Quality camera telephoto lens (work in progress)”

  1. Paul Rogers Avatar
    Paul Rogers

    nice idea, if the worm gear is narrower than the cogs you could print some spurs on the cogs that would work with those cheap chinese rotary encoders that have a light transmitter and receiver either side of a groove.

    1. Chris Laplante Avatar
      Chris Laplante

      Thanks for the tip! Do you have any specific parts in mind?

Leave a Reply

Discover more from Chris Laplante's blog

Subscribe now to keep reading and get access to the full archive.

Continue reading