MecanumDriveWithPP

class MecanumDriveWithPP(hardwareMap: HardwareMap, followerConstants: FollowerConstants, localizerConstants: DriveEncoderConstants, pathConstraints: PathConstraints, driveConstants: MecanumConstants, initialPose: Pose = Pose()) : MecanumDrivetrain

A mecanum drivetrain integrated with the PedroPathing library

Parameters

hardwareMap

The FTC hardware map

followerConstants

Constants for the path follower

localizerConstants

Constants for the drive encoder localizer

pathConstraints

Constraints for path following

driveConstants

Constants specific to the mecanum drivetrain

initialPose

The initial pose of the robot

Constructors

Link copied to clipboard
constructor(hardwareMap: HardwareMap, followerConstants: FollowerConstants, localizerConstants: DriveEncoderConstants, pathConstraints: PathConstraints, driveConstants: MecanumConstants, initialPose: Pose = Pose())

Types

Link copied to clipboard
inner class FollowerActionBuilder(startPose: Pose)

Properties

Link copied to clipboard
val follower: Follower

The path follower instance

Link copied to clipboard
Link copied to clipboard
val pose: Pose

The robot's current pose

Link copied to clipboard
val state: StateFlow<AttachmentState>

Functions

Link copied to clipboard

Checks if the attachment is currently busy (Running).

Link copied to clipboard

Checks if the attachment is currently in a faulted state.

Link copied to clipboard

Creates a path following action starting from the given pose

Link copied to clipboard
fun pathTo(pathChain: PathChain): Action

Follows the given path using PedroPathing

Link copied to clipboard

Ensures the attachment is in the Idle state, throwing an exception if not.

Link copied to clipboard
open override fun setDrivePowers(powers: PoseVelocity2d)
Link copied to clipboard
Link copied to clipboard
open fun stop()

Stops the attachment and resets its state to Idle.

Link copied to clipboard
context(telemetry: Telemetry)
open override fun update()

Updates the telemetry with the current state of the attachment.