Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions ci-scripts/check_constants.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@
"ShooterConstants.json": "frc.robot.constants.ShooterConstants",
"HoodConstants.json": "frc.robot.constants.HoodConstants",
"ClimberConstants.json": "frc.robot.constants.ClimberConstants",
"TransferRollerConstants.json": "frc.robot.constants.TransferRollerConstants",
"ShotMaps.json": "frc.robot.constants.ShotMaps",
"RedFieldLocations.json": "frc.robot.constants.FieldLocationInstance",
"BlueFieldLocations.json": "frc.robot.constants.FieldLocationInstance",
Expand Down
284 changes: 284 additions & 0 deletions elastic_layouts/tuning.json
Original file line number Diff line number Diff line change
Expand Up @@ -2380,6 +2380,290 @@
}
]
}
},
{
"name": "Transfer Roller Tuning",
"grid_layout": {
"layouts": [
{
"title": "PIDGains",
"x": 0.0,
"y": 0.0,
"width": 256.0,
"height": 256.0,
"type": "List Layout",
"properties": {
"label_position": "LEFT"
},
"children": [
{
"title": "kP",
"x": 0.0,
"y": 0.0,
"width": 128.0,
"height": 128.0,
"type": "Text Display",
"properties": {
"topic": "TunableNumbers/TransferRoller/MotorTuning/PIDGains/kP",
"period": 0.06,
"data_type": "double",
"show_submit_button": true
}
},
{
"title": "kI",
"x": 0.0,
"y": 0.0,
"width": 128.0,
"height": 128.0,
"type": "Text Display",
"properties": {
"topic": "TunableNumbers/TransferRoller/MotorTuning/PIDGains/kI",
"period": 0.06,
"data_type": "double",
"show_submit_button": true
}
},
{
"title": "kD",
"x": 0.0,
"y": 0.0,
"width": 128.0,
"height": 128.0,
"type": "Text Display",
"properties": {
"topic": "TunableNumbers/TransferRoller/MotorTuning/PIDGains/kD",
"period": 0.06,
"data_type": "double",
"show_submit_button": true
}
}
]
},
{
"title": "FeedForwardGains",
"x": 256.0,
"y": 0.0,
"width": 256.0,
"height": 256.0,
"type": "List Layout",
"properties": {
"label_position": "LEFT"
},
"children": [
{
"title": "kA",
"x": 0.0,
"y": 0.0,
"width": 128.0,
"height": 128.0,
"type": "Text Display",
"properties": {
"topic": "TunableNumbers/TransferRoller/MotorTuning/PIDGains/kA",
"period": 0.06,
"data_type": "double",
"show_submit_button": true
}
},
{
"title": "kG",
"x": 0.0,
"y": 0.0,
"width": 128.0,
"height": 128.0,
"type": "Text Display",
"properties": {
"topic": "TunableNumbers/TransferRoller/MotorTuning/PIDGains/kG",
"period": 0.06,
"data_type": "double",
"show_submit_button": true
}
},
{
"title": "kS",
"x": 0.0,
"y": 0.0,
"width": 128.0,
"height": 128.0,
"type": "Text Display",
"properties": {
"topic": "TunableNumbers/TransferRoller/MotorTuning/PIDGains/kS",
"period": 0.06,
"data_type": "double",
"show_submit_button": true
}
},
{
"title": "kV",
"x": 0.0,
"y": 0.0,
"width": 128.0,
"height": 128.0,
"type": "Text Display",
"properties": {
"topic": "TunableNumbers/TransferRoller/MotorTuning/PIDGains/kV",
"period": 0.06,
"data_type": "double",
"show_submit_button": true
}
}
]
},
{
"title": "MotionProfile",
"x": 896.0,
"y": 0.0,
"width": 384.0,
"height": 384.0,
"type": "List Layout",
"properties": {
"label_position": "TOP"
},
"children": [
{
"title": "MaxAcceleration_Rotation per Second per Second",
"x": 0.0,
"y": 0.0,
"width": 128.0,
"height": 128.0,
"type": "Text Display",
"properties": {
"topic": "TunableNumbers/TransferRoller/MotorTuning/MotionProfile/MaxAcceleration_Rotation per Second per Second",
"period": 0.06,
"data_type": "double",
"show_submit_button": true
}
},
{
"title": "MaxJerk_Rotation per Second per Second per Second",
"x": 0.0,
"y": 0.0,
"width": 128.0,
"height": 128.0,
"type": "Text Display",
"properties": {
"topic": "TunableNumbers/TransferRoller/MotorTuning/MotionProfile/MaxJerk_Rotation per Second per Second per Second",
"period": 0.06,
"data_type": "double",
"show_submit_button": true
}
},
{
"title": "MaxVelocity_Rotation per Second",
"x": 0.0,
"y": 0.0,
"width": 128.0,
"height": 128.0,
"type": "Text Display",
"properties": {
"topic": "TunableNumbers/TransferRoller/MotorTuning/MotionProfile/MaxVelocity_Rotation per Second",
"period": 0.06,
"data_type": "double",
"show_submit_button": true
}
},
{
"title": "expoKA_Volt per Rotation per Second per Second",
"x": 0.0,
"y": 0.0,
"width": 128.0,
"height": 128.0,
"type": "Text Display",
"properties": {
"topic": "TunableNumbers/TransferRoller/MotorTuning/MotionProfile/expoKA_Volt per Rotation per Second per Second",
"period": 0.06,
"data_type": "double",
"show_submit_button": true
}
},
{
"title": "expoKV_Volt per Rotation per Second",
"x": 0.0,
"y": 0.0,
"width": 128.0,
"height": 128.0,
"type": "Text Display",
"properties": {
"topic": "TunableNumbers/TransferRoller/MotorTuning/MotionProfile/expoKV_Volt per Rotation per Second",
"period": 0.06,
"data_type": "double",
"show_submit_button": true
}
}
]
},
{
"title": "MotorTuning",
"x": 512.0,
"y": 0.0,
"width": 384.0,
"height": 256.0,
"type": "List Layout",
"properties": {
"label_position": "TOP"
},
"children": [
{
"title": "CurrentTuning_Amp",
"x": 0.0,
"y": 0.0,
"width": 128.0,
"height": 128.0,
"type": "Text Display",
"properties": {
"topic": "TunableNumbers/TransferRoller/MotorTuning/CurrentTuning_Amp",
"period": 0.06,
"data_type": "double",
"show_submit_button": true
}
},
{
"title": "VelocityTarget_Rotation per Minute",
"x": 0.0,
"y": 0.0,
"width": 128.0,
"height": 128.0,
"type": "Text Display",
"properties": {
"topic": "TunableNumbers/TransferRoller/MotorTuning/VelocityTarget_Rotation per Minute",
"period": 0.06,
"data_type": "double",
"show_submit_button": true
}
},
{
"title": "VoltageTuning_Volt",
"x": 0.0,
"y": 0.0,
"width": 128.0,
"height": 128.0,
"type": "Text Display",
"properties": {
"topic": "TunableNumbers/TransferRoller/MotorTuning/VoltageTuning_Volt",
"period": 0.06,
"data_type": "double",
"show_submit_button": true
}
}
]
}
],
"containers": [
{
"title": "TransferRoller Test Mode Selector",
"x": 0.0,
"y": 256.0,
"width": 896.0,
"height": 128.0,
"type": "ComboBox Chooser",
"properties": {
"topic": "/SmartDashboard/TransferRoller Test Mode Selector",
"period": 0.06,
"sort_options": false
}
}
]
}
}
]
}
3 changes: 2 additions & 1 deletion src/main/deploy/constants/comp/CANBusAssignment.json
Original file line number Diff line number Diff line change
Expand Up @@ -22,5 +22,6 @@
"intakeRollersFollowerMotorId": 21,
"shooterLeaderId": 22,
"shooterFollowerId": 23,
"climberKrakenId": 24
"climberKrakenId": 24,
"transferRollerKrakenId": 25
}
1 change: 1 addition & 0 deletions src/main/deploy/constants/comp/FeatureFlags.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
"runIntake": true,
"runHood": true,
"runClimber": true,
"runTransferRoller": true,
"useHomingSwitch": false,
"useTuningServer": true,
"pretendCamerasAreMobile": false
Expand Down
72 changes: 72 additions & 0 deletions src/main/deploy/constants/comp/TransferRollerConstants.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,72 @@
{
"transferRollerReduction": 1.0,
"velocityFilterTime": {
"value": 0.05,
"unit": "Seconds"
},
"transferRollerGains": {
"kP": 10.0,
"kI": 7.0,
"kD": 0.0,
"kS": 2.0,
"kG": 0.0,
"kV": 0.1,
"kA": 0.0
},
"transferRollerMotionProfileConfig": {
"isMutable": false,
"maxVelocity": {
"value": 0.0,
"unit": "Rotation per Second"
},
"maxAcceleration": {
"value": 3000.0,
"unit": "Rotation per Second per Second"
},
"maxJerk": {
"value": 0.0,
"unit": "Rotation per Second per Second per Second"
},
"expoKV": {
"dividend": {
"value": 0.0,
"unit": "Volt"
},
"divisor": {
"value": 1.0,
"unit": "Rotation per Second"
}
},
"expoKA": {
"dividend": {
"value": 0.0,
"unit": "Volt"
},
"divisor": {
"value": 1.0,
"unit": "Rotation per Second per Second"
}
}
},
"transferRollerSupplyCurrentLimit": {
"value": 60.0,
"unit": "Amp"
},
"transferRollerStatorCurrentLimit": {
"value": 40.0,
"unit": "Amp"
},
"simTransferRollerMOI": {
"value": 2.5E-4,
"unit": "Kilogram-Meter per Second-Meter per Radian per Second"
},
"transferRollerSpinningVelocity": {
"value": 2000.0,
"unit": "Rotation per Minute"
},
"transferRollerDeJamVelocity": {
"value": -2000.0,
"unit": "Rotation per Minute"
},
"transferRollerMotorDirection": "CounterClockwise_Positive"
}
Original file line number Diff line number Diff line change
Expand Up @@ -22,5 +22,6 @@
"intakeRollersFollowerMotorId": 21,
"shooterLeaderId": 22,
"shooterFollowerId": 23,
"climberKrakenId": 24
"climberKrakenId": 24,
"transferRollerKrakenId": 25
}
Loading