X-Git-Url: http://challenge-bot.com/repos/?p=3501%2F2017steamworks;a=blobdiff_plain;f=src%2Forg%2Fusfirst%2Ffrc%2Fteam3501%2Frobot%2FRobot.java;h=e6ad60d6482c586bd9221e7aa1f42db1b6d17ed4;hp=c446a8687b22642a025abafecabfa9ecaf167717;hb=1782cbadb12ad13d30eab7597f656cbe17f48df2;hpb=ac77a7b890c794f807b764221ff72d9044791fab diff --git a/src/org/usfirst/frc/team3501/robot/Robot.java b/src/org/usfirst/frc/team3501/robot/Robot.java index c446a86..e6ad60d 100644 --- a/src/org/usfirst/frc/team3501/robot/Robot.java +++ b/src/org/usfirst/frc/team3501/robot/Robot.java @@ -6,8 +6,10 @@ import org.usfirst.frc.team3501.robot.subsystems.Shooter; import edu.wpi.cscore.UsbCamera; import edu.wpi.first.wpilibj.CameraServer; +import edu.wpi.first.wpilibj.DriverStation; import edu.wpi.first.wpilibj.IterativeRobot; import edu.wpi.first.wpilibj.command.Scheduler; +import edu.wpi.first.wpilibj.smartdashboard.SmartDashboard; public class Robot extends IterativeRobot { private static DriveTrain driveTrain; @@ -56,11 +58,19 @@ public class Robot extends IterativeRobot { @Override public void teleopInit() { - } @Override public void teleopPeriodic() { Scheduler.getInstance().run(); + updateSmartDashboard(); + } + + public void updateSmartDashboard() { + SmartDashboard.putNumber("angle", driveTrain.getAngle()); + SmartDashboard.putNumber("voltage", + DriverStation.getInstance().getBatteryVoltage()); + SmartDashboard.putNumber("rpm", shooter.getShooterRPM()); + SmartDashboard.putNumber("motor value", shooter.getCurrentShootingSpeed()); } }