vision auto-aim

I already did a similar but we haven’t been able do it.

1-Copy, paste the rectangle example to the vision.( We some error with the global variable)

2-Post data on dashboard(don’t know how to do)

3-Auto-aim with pid output to motor


ps.Can we put a cross-hair on the vision dashboard

First, use the instructions below to incorporate the vision tracking code into your robot project.

  1. Create a copy of the “Rectangular Target - 2013” folder that can be found in your LabVIEW program files (let me know if you need help finding it).
  2. Move this copied version of the folder into your project folder
  3. Open up your project
  4. Right click on Vision and click “replace,” then select the Vision Processing VI in the “Rectangular Target - 2013” folder that you just copied.
  5. Follow the prompts. You’ll be told that there are conflicts. For all of them, select the file that was in your original project - not the one that is in the “Rectangular Target” folder.
  6. The final prompt will ask again if you want to use the new Vision Processing VI instead of your original one. Confirm that you want to use the one in the “Rectangular Target - 2013” folder.

Once you save the project, go into the new Vision Processing VI and search for the broken wires. You will have to create a new global variable to replace the one that you told it not to reference anymore.

Once you have done that, you can use the global variable “Target Info” to track a target. You will have to parse the data in the global variable (it’s a cluster of a few different arrays) to have to narrowed down into the target that you want (example: use the target info from the target with the highest Y coordinate, aka the 3 point goal). Once you know which target to track, you can use its X coordinate to turn the robot left or right. Let me know if you need help with that.

We have successfully added the target rectangle in our project and we just added a robot mode in from an old project in this project. We are stuck where we have to find only the third target (the highest). And how we put the target info on the dashboard ?

PS: how do we do the PID?