2020-12-26 14:12:05 -08:00
|
|
|
// Copyright (c) FIRST and other WPILib contributors.
|
|
|
|
|
// Open Source Software; you can modify and/or share it under the terms of
|
|
|
|
|
// the WPILib BSD license file in the root directory of this project.
|
2016-01-02 03:02:34 -08:00
|
|
|
|
2018-07-20 00:03:45 -07:00
|
|
|
#include "frc/RobotState.h"
|
2014-08-08 17:05:49 -04:00
|
|
|
|
2018-07-20 00:03:45 -07:00
|
|
|
#include "frc/DriverStation.h"
|
2014-08-08 17:05:49 -04:00
|
|
|
|
2016-11-01 22:33:12 -07:00
|
|
|
using namespace frc;
|
|
|
|
|
|
2014-08-08 17:05:49 -04:00
|
|
|
bool RobotState::IsDisabled() {
|
2018-07-08 15:41:31 -07:00
|
|
|
return DriverStation::GetInstance().IsDisabled();
|
2014-08-08 17:05:49 -04:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
bool RobotState::IsEnabled() {
|
2018-07-08 15:41:31 -07:00
|
|
|
return DriverStation::GetInstance().IsEnabled();
|
2014-08-08 17:05:49 -04:00
|
|
|
}
|
|
|
|
|
|
2019-07-16 09:18:23 -05:00
|
|
|
bool RobotState::IsEStopped() {
|
|
|
|
|
return DriverStation::GetInstance().IsEStopped();
|
|
|
|
|
}
|
|
|
|
|
|
2014-08-08 17:05:49 -04:00
|
|
|
bool RobotState::IsOperatorControl() {
|
2018-07-08 15:41:31 -07:00
|
|
|
return DriverStation::GetInstance().IsOperatorControl();
|
2014-08-08 17:05:49 -04:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
bool RobotState::IsAutonomous() {
|
2018-07-08 15:41:31 -07:00
|
|
|
return DriverStation::GetInstance().IsAutonomous();
|
2014-08-08 17:05:49 -04:00
|
|
|
}
|
|
|
|
|
|
2018-07-08 15:41:31 -07:00
|
|
|
bool RobotState::IsTest() { return DriverStation::GetInstance().IsTest(); }
|