TankDrive

open class TankDrive @JvmOverloads constructor(left: MotorGroup, right: MotorGroup, trackWidth: Double = 1.0, externalHeadingSensor: AngleSensor? = null) : AbstractTankDrive, DriveComponent

A Component implementation of a tank drive.

Constructors

Link copied to clipboard
constructor(left: MotorGroup, right: MotorGroup, constraints: TankConstraints, externalHeadingSensor: AngleSensor? = null)
constructor(left: MotorGroup, right: MotorGroup, trackWidth: Double = 1.0, externalHeadingSensor: AngleSensor? = null)

Properties

Link copied to clipboard
protected val motors: MotorGroup

All the motors in this drive.

Functions

Link copied to clipboard
open override fun getWheelPositions(): List<Double>
Link copied to clipboard
open override fun setMotorPowers(left: Double, right: Double)
Link copied to clipboard
open override fun setRunMode(runMode: Motor.RunMode)
Link copied to clipboard
open override fun setWheelVelocities(velocities: List<Double>, accelerations: List<Double>)
Link copied to clipboard
open override fun setZeroPowerBehavior(zeroPowerBehavior: Motor.ZeroPowerBehavior)
Link copied to clipboard
open override fun update()

This method is called repeatedly by the CommandScheduler.