API Reference
YAGSL's own Java surface is intentionally small: swervelib.parser.SwerveParser reads your JSON config and hands you back a fully-built YAMS SwerveDrive. From that point on, you're driving and configuring a YAMS object, not a YAGSL-specific one — so the authoritative API reference lives in the YAMS docs, not here.
Class you get back from SwerveParser
YAMS API reference
yams.mechanisms.swerve.SwerveDrive
yams.mechanisms.config.SwerveDriveConfig
yams.mechanisms.swerve.SwerveModule (per-module)
Module config (built internally from your module JSON)
yams.mechanisms.swerve.utility.SwerveInputStream
The full YAMS API reference (all mechanisms, motor controllers, units, and math helpers — not just swerve) is at yagsl.gitbook.io/yams.
SwerveParser.createSwerveDriveDevices(config) is the one place YAGSL hands back something other than YAMS objects: alongside the SwerveDrive, it returns the raw vendor motor controller/encoder/ gyro objects it built, for the rare case where you need to call a vendor-specific method SmartMotorController doesn't expose. See How to access raw hardware devices.
Where to look for what
"What JSON fields exist?" → JSON Schema Reference (this repo).
"What does
SwerveDrive.drive(...)do, what are all its methods?" → YAMS SwerveDrive reference."How do I build a
SwerveDriveConfigby hand instead of from JSON?" → YAMS SwerveDriveConfig reference."How do I wire joystick input into field/robot-relative chassis speeds?" → YAMS SwerveInputStream reference.
"What changed in the JSON schema recently?" → Schema Changes.
Last updated
Was this helpful?