Using OpenMV Cam M7 for Measuring Object Translation

Discussion related to "under the hood" OpenMV topics.
pwbell125
Posts: 1
Joined: Mon Aug 27, 2018 5:20 pm

Using OpenMV Cam M7 for Measuring Object Translation

Postby pwbell125 » Mon Aug 27, 2018 5:36 pm

Hello - I've read lots in this forum that gets close to answering this question, but haven't seen this particular scenario. I am looking to measure the movement of a cylindrical pin in one axis (translation). I plan to mount the camera in a fixed location looking down on the pin, so the camera will see a circle that moves in either X or Y. I know I can detect that circle using find circles, and I have done that successfully, although the current pin is unpainted aluminum, so not RGB. The term frame sequencing sounded promising to me - Would this allow taking multiple sequential images and measuring the translation of the pin with regard to it's position in the first image? Or is there some better way to accomplish this goal? I'm looking to measure small changes, likely less than a couple of mm at a time. Thanks in advance for any help!

Best
User avatar
kwagyeman
Posts: 2286
Joined: Sun May 24, 2015 2:10 pm

Re: Using OpenMV Cam M7 for Measuring Object Translation

Postby kwagyeman » Mon Aug 27, 2018 5:44 pm

Um, basically what you need to do is all standard python code. Once you've got the position of the pin you just have to keep track of where the pin is in the image.

Um, you have the x and y position. So, compare the current to the previous value and accumulate the distance.
Nyamekye,

Return to “Technical Discussion”

Who is online

Users browsing this forum: victagayun and 8 guests