|
Valkyrie 2026
|
Request structure for commanding a swerve drivetrain using chassis speeds. More...
#include <valkyrie/drivetrain/mecanum/Requests.h>
Public Attributes | |
| frc::ChassisSpeeds | speeds |
| Desired chassis-relative or field-relative motion. | |
| frc::Translation2d | centerOfRotation = {} |
| Center of rotation for the drivetrain motion. | |
| BaseController::Output | frontLeftFF = 0 |
| Optional feedforward outputs for each swerve module. | |
| BaseController::Output | frontRightFF = 0 |
| BaseController::Output | rearLeftFF = 0 |
| BaseController::Output | rearRightFF = 0 |
| BaseController::Output | zeroOutput = 0 |
| Default output value used when speeds are below the given deadband. | |
| OutputType | outputType = OutputType::Velocity |
| Output control mode used when applying drive requests. | |
| bool | discretize = true |
| Whether to discretize the chassis speeds. | |
| bool | desaturateWheelSpeeds = true |
| Whether to desaturate wheel speeds. | |
| bool | fieldRelative = true |
| Whether the chassis speeds are field-relative. | |
| units::meters_per_second_t | deadband = 0_mps |
| Minimum wheel speed required before motion is applied. | |
Request structure for commanding a swerve drivetrain using chassis speeds.
Contains the desired chassis motion, optional module feedforwards, and configuration flags controlling how the drivetrain request is processed before being applied to the modules.
| frc::Translation2d valor::mecanum::requests::ApplyChassisSpeeds::centerOfRotation = {} |
Center of rotation for the drivetrain motion.
Allows the robot to rotate around a point other than its geometric center.
| units::meters_per_second_t valor::mecanum::requests::ApplyChassisSpeeds::deadband = 0_mps |
Minimum wheel speed required before motion is applied.
Speeds below this threshold are treated as zero to prevent unintended module movement or jitter.
| bool valor::mecanum::requests::ApplyChassisSpeeds::desaturateWheelSpeeds = true |
Whether to desaturate wheel speeds.
If enabled, wheel speeds are scaled proportionally to ensure no module exceeds the drivetrain's maximum achievable speed.
| bool valor::mecanum::requests::ApplyChassisSpeeds::discretize = true |
Whether to discretize the chassis speeds.
Discretization compensates for loop timing to improve motion accuracy during simultaneous translation and rotation.
| bool valor::mecanum::requests::ApplyChassisSpeeds::fieldRelative = true |
Whether the chassis speeds are field-relative.
If enabled, the requested motion is interpreted relative to the field coordinate frame instead of the robot frame.
| BaseController::Output valor::mecanum::requests::ApplyChassisSpeeds::frontLeftFF = 0 |
Optional feedforward outputs for each swerve module.
Used to apply additional controller output alongside the calculated module states.
| OutputType valor::mecanum::requests::ApplyChassisSpeeds::outputType = OutputType::Velocity |
Output control mode used when applying drive requests.
Determines how wheel speed commands are interpreted by the drive motor controllers, such as closed-loop velocity, direct voltage, or normalized duty cycle control.
| frc::ChassisSpeeds valor::mecanum::requests::ApplyChassisSpeeds::speeds |
Desired chassis-relative or field-relative motion.
Represents the translational and angular velocity request for the robot.
| BaseController::Output valor::mecanum::requests::ApplyChassisSpeeds::zeroOutput = 0 |
Default output value used when speeds are below the given deadband.
This is required when switching between brake and coast mode at different parts of the match given how some vendors' on-the-fly neutral mode switching works