2016-01-02 03:02:34 -08:00
|
|
|
/*----------------------------------------------------------------------------*/
|
2019-07-16 09:18:23 -05:00
|
|
|
/* Copyright (c) 2016-2019 FIRST. All Rights Reserved. */
|
2016-01-02 03:02:34 -08:00
|
|
|
/* Open Source Software - may be modified and shared by FRC teams. The code */
|
|
|
|
|
/* must be accompanied by the FIRST BSD license file in the root directory of */
|
|
|
|
|
/* the project. */
|
|
|
|
|
/*----------------------------------------------------------------------------*/
|
|
|
|
|
|
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(); }
|