-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Joystick control #5
base: main
Are you sure you want to change the base?
Conversation
d7438ce
to
a8a5cf6
Compare
I cleaned up the commit history |
…veTest into joystick-control
84388cb
to
b31a713
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Mostly cleaning up testing code, one method needed docs
var slider = Shuffleboard.getTab("testing").add("Left/Right", 0).withWidget(BuiltInWidgets.kNumberSlider).getEntry(); | ||
var sliderTwo = Shuffleboard.getTab("testing").add("Forward/Backward", 0).withWidget(BuiltInWidgets.kNumberSlider).getEntry(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Remove
// System.out.println("Angle conversion factor: " + angleConversionFactor); | ||
// if (1 == 1)throw new RuntimeException(""); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ditto
for (var mod : swerveDrive.getModules()) { | ||
var motor = (WPI_TalonSRX) mod.getAngleMotor().getMotor(); | ||
if (motor.getDeviceID() == 4) { | ||
// motor.set(0.05); | ||
|
||
// System.out.println(motor.getSelectedSensorPosition()); | ||
// System.out.println("Motor: " + motor.getDeviceID() + " | Closed loop error: " + motor.getClosedLoopError() + " | Closed loop target: " + motor.getClosedLoopTarget() + " | Current Position: " + motor.getSelectedSensorPosition()); | ||
SmartDashboard.putNumber("Error", motor.getClosedLoopError()); | ||
SmartDashboard.putNumber("Current", motor.getSelectedSensorPosition()); | ||
SmartDashboard.putNumber("Reference", motor.getClosedLoopTarget()); | ||
} | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ditto
return getPose().getRotation(); | ||
} | ||
|
||
//! TODO: Fill out this info |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Document this method
435fb7e
to
513e7aa
Compare
Also updates YAGSL