How can I get full 360deg rotation angle of this kind of dial?
I can detect the blob and get the rotation angle between 0-180 deg. When the dial is pointing upper half the angle has 180 deg error.
General discussion about topics related to OpenMV.
2 posts • Page 1 of 1
- dial.PNG (32.24 KiB) Viewed 868 times
Um, there's no way mathematically to get a better angle than 0-180 with our code by default. The cross-correlation doesn't have the ability to be 0-360. However, if you add some extra info you can get the full 360. For example, can you detect if the arrow is to the left or to the right (or pointing up versus down) and add 180 to the output of rotation? This should be as simple as just looking to see if the bounding box is outside a threshold.
Who is online
Users browsing this forum: No registered users and 1 guest