Package org.firstinspires.ftc.teamcode
Class API
- java.lang.Object
-
- org.firstinspires.ftc.teamcode.API
-
public class API extends java.lang.Object
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
API.Direction
class
API.Gamepad
static class
API.GamepadIndex
class
API.HubIMU
class
API.Motor
static class
API.MotorBehaviour
class
API.Servo
-
Field Summary
Fields Modifier and Type Field Description API.Gamepad
gamepad1
API.Gamepad
gamepad2
API.HubIMU
imu
java.io.File
logFile
boolean
useLogFile
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
clear()
Clears the telemetryvoid
pause(double seconds)
Pauses for a given amount of seconds, with sub-millisecond accuracyvoid
print(java.lang.String s)
Prints a line to telemetryvoid
print(java.lang.String caption, java.lang.String value)
Prints a value to telemetry, formatted as "caption: value"
-
-
-
Field Detail
-
imu
public final API.HubIMU imu
-
gamepad1
public final API.Gamepad gamepad1
-
gamepad2
public final API.Gamepad gamepad2
-
useLogFile
public final boolean useLogFile
-
logFile
public java.io.File logFile
-
-
Constructor Detail
-
API
public API(com.qualcomm.robotcore.eventloop.opmode.OpMode mode, boolean useLogFile)
- Parameters:
mode
- the opmode to initialize withuseLogFile
- whether or not to log to a log file
-
API
public API(com.qualcomm.robotcore.eventloop.opmode.OpMode mode)
- Parameters:
mode
- the opmode to initialize with
-
-
Method Detail
-
pause
public void pause(double seconds)
Pauses for a given amount of seconds, with sub-millisecond accuracy- Parameters:
seconds
- the amount of seconds to pause for
-
print
public void print(java.lang.String s)
Prints a line to telemetry- Parameters:
s
- the text to print- See Also:
print(String, String)
-
print
public void print(java.lang.String caption, java.lang.String value)
Prints a value to telemetry, formatted as "caption: value"- Parameters:
caption
- the caption to printvalue
- the value to print- See Also:
print(String)
-
clear
public void clear()
Clears the telemetry
-
-