WPILibC++ 2024.3.2
RobotState.h
Go to the documentation of this file.
1// Copyright (c) FIRST and other WPILib contributors.
2// Open Source Software; you can modify and/or share it under the terms of
3// the WPILib BSD license file in the root directory of this project.
4
5#pragma once
6
7namespace frc {
8
9/**
10 * Robot state utility functions.
11 */
13 public:
14 RobotState() = delete;
15
16 /**
17 * Returns true if the robot is disabled.
18 *
19 * @return True if the robot is disabled.
20 */
21 static bool IsDisabled();
22
23 /**
24 * Returns true if the robot is enabled.
25 *
26 * @return True if the robot is enabled.
27 */
28 static bool IsEnabled();
29
30 /**
31 * Returns true if the robot is E-stopped.
32 *
33 * @return True if the robot is E-stopped.
34 */
35 static bool IsEStopped();
36
37 /**
38 * Returns true if the robot is in teleop mode.
39 *
40 * @return True if the robot is in teleop mode.
41 */
42 static bool IsTeleop();
43
44 /**
45 * Returns true if the robot is in autonomous mode.
46 *
47 * @return True if the robot is in autonomous mode.
48 */
49 static bool IsAutonomous();
50
51 /**
52 * Returns true if the robot is in test mode.
53 *
54 * @return True if the robot is in test mode.
55 */
56 static bool IsTest();
57};
58
59} // namespace frc
Robot state utility functions.
Definition: RobotState.h:12
static bool IsAutonomous()
Returns true if the robot is in autonomous mode.
static bool IsTeleop()
Returns true if the robot is in teleop mode.
static bool IsEStopped()
Returns true if the robot is E-stopped.
static bool IsEnabled()
Returns true if the robot is enabled.
static bool IsTest()
Returns true if the robot is in test mode.
static bool IsDisabled()
Returns true if the robot is disabled.
RobotState()=delete
Definition: AprilTagPoseEstimator.h:15