NextOpMode

abstract class NextOpMode

Base class for all NextFTC OpModes.

Automatically injects the scanned dev.nextftc.robot.NextRobot instance and handles the lifecycle execution, calling various OpModeHooks and managing the internal command scheduler.

Parameters

hooks

Internal hooks used to manage robot mechanisms and the scheduler loop.

Constructors

Link copied to clipboard
constructor(robot: NextRobot, vararg hooks: OpModeHook)

Secondary constructor invoked by the NextFTCOpModeScanner during automatic registration.

Types

Link copied to clipboard
object Companion

Properties

Link copied to clipboard
val gamepad1: Gamepad

The primary gamepad provided by the Driver Station.

Link copied to clipboard
val gamepad2: Gamepad

The secondary gamepad provided by the Driver Station.

Link copied to clipboard
val hardwareMap: HardwareMap

The hardware map provided by the FTC SDK.

Link copied to clipboard
val telemetry: Telemetry

The standard SDK telemetry provided by the Driver Station.

Functions

Link copied to clipboard
open fun disabledPeriodic()

Called repeatedly while the OpMode is in the INIT phase.

Link copied to clipboard
open fun end()

Called exactly once when the OpMode finishes execution.

Link copied to clipboard
open fun periodic()

Called repeatedly while the OpMode is actively running.

Link copied to clipboard
open fun start()

Called exactly once after the PLAY button is pressed.