|
Re: Team Fusion's take on cRIO and LabView
Camera tracking was the hardest thing to get working. The Example programs look very complicated, so you hardly know where to start, let alone how to drive a robot with it.
I found out, through much experimentation, that you really only need two vision vi's, IMAQ Color Threshold and IMAQ Particle Analysis Report. You wire the image from the camera and wire the color range you want into the Color Threshold vi. This vi looks for the color you specify and removes any pixels that are not in the color range. You can then wire the resulting image into the particle analysis. The Particle Analysis vi will give you an array of particle reports for every particle mass it finds. You probably want to make a global for the particle reports so you can access them in autonomous. The report with the highest area is the object your looking for. You can get the center of mass from the report and use it to compute how much to turn.
Hope that helps. There's a lot there, I might have to make a tutorial if it doesn't make sense.
|