【2024 DigiKey Creative Contest】Part 2: Getting Started with OPENMV
[Copy link]
First time using openmv
Download openmv IDE first
Then install
After the installation is complete, open the desktop shortcut
This is the routine that cannot be seen
Open the hardware OPENMV module and connect it to the USB port of the computer with a USB cable.
Click the icon
The Start button turns green
You can see the sample file in the file
Modify the color threshold
Test results, color recognition
Explanation of some procedures for color recognition
Sensor.snapshot() Explanation
img = sensor.snapshot(), captures the photo in the photosensitive element, stores the captured image in the auxiliary frame buffer storage area, and returns the parameter image object. At this time, the variable img is image, which can be understood as equivalent.
blob.elongation() explanation
The following sentence if blob.elongation() > 0.5:, the function of blob.elongation() is to see whether the pattern is like a circle. If it is more like a circle, the smaller the value, and if it is less like a circle, the larger the value.
|