4 ms·
I attempted to do this with a module for an arduino that measured distance with ultrasound and controlled a stepper motor (didn't have a servo motor that would
by dylan604 6y ago
I attempted to do this with a module for an arduino that measured distance with ultrasound and controlled a stepper motor (didn't have a servo motor that would have worked better). As a PoC, it worked in that if focus was set to a background object and then someone stepped in the direct line of the ultrasound, the stepper would turn in the correct direction to bring in focus. It was crazy telling the arduino where infinity was on the lens and then where near field focus limit was, and then keeping track of how many steps were moved. it was also complicated in that a focus lens is not a linear scale to get to infinity.
all in all, it was a fun project to ultimately understand why CineTape[0] systems are so expensive.
[0]https://cinemaelec.com/products/cinetape_measure https://cinemaelec.com/products/cinetape_measure
- seg_lol 6y agoCould you have someone walk towards the camera with a focus test card and form a map between the sensor and the focus data from the lens itself (FFT, etc)? It would be something analogous to the 'learned indexes' paper. You could then provide any tweening function to give you that focus feeling you need. http://www.vldb.org/pvldb/vol13/p1162-ferragina.pdf http://www.vldb.org/pvldb/vol13/p1162-ferragina.pdf https://arxiv.org/abs/1712.01208 https://arxiv.org/abs/1712.01208
- dylan604 6y agoThe problem was that the stepper motor was too slow to do anything worth messing with like this, so I ultimately wound up taking it all apart and reusing the components in other projects. I build different rigs for timelapse motion control so the steppers are perfect, but live action motion really needs the speed a servo can provide. I did take what I learned from that to building a motion control focus puller for time lapse that used the stepper from this test. This rig doesn't need to arbitrarily adjust focus and does a "dumb" move focus ring from point A to point B in predetermined amount of time. Much easier to program.
- seg_lol 6y agoThat sounds really great. I'd like to do that this winter with Rust on Arduino or Rust on a soft-core RISC-V. I have hacked up some PID loops in the past, but nothing using _actual_ math.