[PROSV5]how to set vision?

I read the document and did not elaborate on how to set up VISION.

I set the ball as the first signature, but I don’t know where to find the parameters generated by it.
How do I get the parameters in the following picture?
The parameters in the picture are input by myself.

What I did was create a C++ Pro project and it give it to you in the robot config file.

This is correct information for VCS, but PROS does things a bit differently.

The Vision Sensor saves all of the signatures that you configure in the Vision Utility Application on the Vision Sensor itself, so there is no need to set the signatures in your PROS program.

That being said, we understand that it can often be easier to configure signatures with their parameters in the code. The next set of changes on our roadmap for release will add the ability to get and set signatures programmatically like you are trying to do here.

So is there a way to do color codes in PROS?

This functionality is also on our roadmap for our next release.

Can you give me an example program?

Any guess as to when we can expect to see this functionality?


The test is valid, but I can’t define a ball or cap and recognize him.
He seems to be identifying by default.

Where in the documentation does it say that?

I have not found anything that says the camera stores the signatures. My preliminary testing using PROS and trying to use signatures I defined on the camera doesn’t seem to point to that either.

This help article says the signatures are saved in the code. Not the camera.


After a little digging I found that the vision signatures that you define in the VCS Vision utility can be seen if you unpack the .tar file that VCS generates when you save the project. That .tar file has a .JSON file in it that contains a JSON object with the signature definitions.

I was able to create a vision signature object definition and assign all the values to the fields, but I still can’t seem to get the camera to function with PROS.

@johnfogarty If you use Robot Mesh Studio, it pastes the constructor for the signature straight into your code, e.g.:

vex::vision::signature sig_TARGETBLOB(1,101,3217,1659,-4681,-3869,-4275,2.3,0);

We are currently using Pros.

Can anyone tell me what I might be doing wrong to get no feedback at all from my call to the distanceToBiggestFlagInches function we defined.

Function line 89.

I try to read the value in opmode through a print statement to the LCD but I don’t ever see any value printed…not even a 0. I’ve tried using this code with signature definitions in the code, and signature definitions supposedly defined in the camera. Neither have shown any results.

pros::lcd::print(6, "Distance to flag INCHES: ", distanceToBiggestFlagInches());

I’m not certain our project is updated to the latest PROS kernel. I think I saw 3.1.3 last night, I’ll try updating tonight and see if anything works then.

1 Like


functions similar to


in that it requires you to tell what types of values are to be included and where. For example, to display a float, you would use

pros::lcd::print(6, "Distance to flag INCHES: %f", distanceToBiggestFlagInches());

. Notice the


; this tells the function where to insert the value. For integer values, use


. Look here for a full list.

Ah! Thats a silly mistake. Thanks for pointing that out.