|
Re: No angle?
The sample code is always turning according to the gyro angle. If it identifies a target, that defines the angle to target, and the gyro setpoint is that angle. If it does not have a target identified, it assumes zero is your end of the field, and that is a reasonable guess as to where the target is.
If you manually place the target in front of the robot and look at the dashboard, is there a green mark around the target? The green box nearby is also giving the score of the target. Using this, you can test out where the camera code works and where it doesn't. You can decide if you want to tune it to accept smaller targets or ignore them because it is too far to kick anyway, etc.
Greg McKaskle
|