-
Notifications
You must be signed in to change notification settings - Fork 1
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
Shooter wheel maintainer command #58
Conversation
double speed = wheel.getTargetValue(); | ||
|
||
if (wheel.isCalibrated()) { | ||
wheel.setPower(1.0); |
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.
⭐ ⭐ ⭐ instead of setting full power, this should be running the PID on the goal speed to figure out what power to send
} | ||
|
||
@Override | ||
protected Double getHumanInput() { |
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.
@JohnGilb I'm wondering if we should have a more simple version of maintainer that doesn't have human input as a concept and then a more complicated version that does?
src/main/java/competition/subsystems/shooter/commands/ShooterWheelMaintainerCommand.java
Outdated
Show resolved
Hide resolved
src/main/java/competition/subsystems/shooter/commands/ShooterWheelMaintainerCommand.java
Outdated
Show resolved
Hide resolved
|
||
@Override | ||
protected double getErrorMagnitude() { | ||
return 0; |
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.
⭐ ⭐ ⭐ this needs to return how far off the current speed is from the goal
super(wheel, pf, hvmFactory, 0, 0); | ||
this.oi = oi; | ||
this.wheel = wheel; | ||
this.addRequirements(this.wheel); |
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.
⭐ ⭐ You don't actually have to add this requirement yourself, the BaseMaintainerCommand will do it for you because you pass in wheel on line 16 already
return 0.0; | ||
} | ||
|
||
protected boolean getErrorWithinTolerance() { |
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.
⭐ ⭐ now that we don't have custom error thresholds anymore, I think we don't need this method at all since the base one does this logic already: https://github.com/Team488/SeriouslyCommonLib/blob/main/src/main/java/xbot/common/command/BaseMaintainerCommand.java#L199
Why are we doing this?
ShooterWheelMaintainerCommand reads and controls values.
Asana task URL: https://app.asana.com/0/38541457243752/1206397614455703
Create ShooterWheelMaintainerCommand
Whats changing?
Questions/notes for reviewers
How this was tested