public abstract class LightningOpMode
extends com.qualcomm.robotcore.eventloop.opmode.LinearOpMode
LightningOpMode
is a customized version of LinearOpMode
that should
be the superclass for all op modes written using Lightning SDK.Modifier and Type | Field and Description |
---|---|
private boolean |
isInitialized
Determines if the op mode has be fully initialized.
|
Constructor and Description |
---|
LightningOpMode() |
Modifier and Type | Method and Description |
---|---|
protected void |
initializeOpMode()
Initializes the robot.
|
protected abstract void |
main()
Executes the 'main procedure' of the op mode.
|
void |
runOpMode() |
init_loop, init, loop, opModeIsActive, sleep, start, stop, waitForNextHardwareCycle, waitForStart, waitOneFullHardwareCycle
private boolean isInitialized
initializeOpMode()
method will always be called, but serious problems
are caused later if any initialization method does not call the initialization
of its superclass. This value is used to determine if the initialization method
defined in LightningOpMode
has been called, indicating if any method
did not call the supertype method.
This value is initialized to false, and only set to true once the version of
initializeOpMode()
defined in LightningOpMode
has been called.
protected void initializeOpMode()
super.initializeOpMode()
on the first line.isInitialized
protected abstract void main()
public final void runOpMode() throws java.lang.InterruptedException
runOpMode
in class com.qualcomm.robotcore.eventloop.opmode.LinearOpMode
java.lang.InterruptedException