Field Oriented Turret

Hi, our team wanted to experiment with a field-oriented turret this year, is there a way to pull this off without having an additional gyro on the turret?

You can easily and accurately measure your robot-relative turret rotation using an encoder. Add this angle to your field-relative drivetrain angle to get a field-relative turret angle.

10 Likes

A great sneaky trick on turret feedback: 10 turn pot.

Its not too difficult to arrange to have the “less than 1 turn” of a normal turret map to “less than 10 turns” on the pot. MUCH easier than trying to map 1:1. Plus, the backlash on a single reduction is much lower than a multiple reduction.

2 Likes

With the layout of the 2020 field (with the port located on an endwall) it was useful to be able to point the turret toward that end of the field (using field oriented turret control), so that the vision system would only be able to see the goal you wanted to aim for (and not be pointed toward the other goal). But of course, that really only got you to the point where the goal was potentially in your vision system field of view (there were some locations on the field where you would not have the goal in view if you were pointed toward the right side of the endwall). So, the final pointing was done by the vision system, not by any sort of field orientation of the turret.

With the layout of the 2022 field where the hub is in the center of the field, field orientation of the turret does not get you very far. But, if you have decent odometry for both X and Y, you can use some simple math to estimate a direction between your current position and the hub (in field coordinates) and then orient your turret in that general direction. If your odometry is good enough, you may not need any sort of vision system to get the direction and distance to target for the turret and shooter settings. But more than likely, you would only want to use odometry to get a “general” direction between the robot and the goal so that you can point in that direction and let your vision system take over to fine tune the pointing and calculate the range.

If your vision system is able to continuously track the goal, you may never use the field oriented turret alignment. But it is nice to have it as a back-up if your vision system ever does lose sight of the goal.

You could use the range calculated by the vision system along with the field orientation of the turret relative to the robot gyro to provide periodic corrections to your odometry systems estimation of your position on the field.

1 Like

Thanks!