Updated ftclib.

Debugged LimelightVision.
This commit is contained in:
Titan Robotics Club
2024-09-25 01:52:25 -07:00
parent 0a4f94692f
commit 394a9319f7
2 changed files with 7 additions and 4 deletions

View File

@ -223,7 +223,10 @@ public class FtcTest extends FtcTeleOp
case VISION_TEST: case VISION_TEST:
if (robot.vision != null) if (robot.vision != null)
{ {
exposure = robot.vision.vision.getCurrentExposure(); if (robot.vision.vision != null)
{
exposure = robot.vision.vision.getCurrentExposure();
}
// Vision generally will impact performance, so we only enable it if it's needed. // Vision generally will impact performance, so we only enable it if it's needed.
if (robot.vision.aprilTagVision != null) if (robot.vision.aprilTagVision != null)
{ {
@ -603,7 +606,7 @@ public class FtcTest extends FtcTeleOp
break; break;
case LeftBumper: case LeftBumper:
if (testChoices.test == Test.VISION_TEST && robot.vision != null) if (testChoices.test == Test.VISION_TEST && robot.vision != null && robot.vision.vision != null)
{ {
if (pressed) if (pressed)
{ {
@ -615,7 +618,7 @@ public class FtcTest extends FtcTeleOp
break; break;
case RightBumper: case RightBumper:
if (testChoices.test == Test.VISION_TEST && robot.vision != null) if (testChoices.test == Test.VISION_TEST && robot.vision != null && robot.vision.vision != null)
{ {
if (pressed) if (pressed)
{ {