core / com.acmerobotics.roadrunner.drive / SwerveDrive / SwerveLocalizer

SwerveLocalizer

class SwerveLocalizer : Localizer

Default localizer for swerve drivetrains based on the drive encoder positions and module orientations.

Parameters

drive - drive

clock - clock

Constructors

<init>

SwerveLocalizer(drive: SwerveDrive, clock: NanoClock = NanoClock.system())

Default localizer for swerve drivetrains based on the drive encoder positions and module orientations.

Properties

poseEstimate

var poseEstimate: Pose2d

Current robot pose estimate.

Functions

update

fun update(): Unit

Completes a single localization update.