mirror of
https://github.com/BroncBotz3481/YAGSL
synced 2026-06-19 06:21:40 +00:00
Updated swervelib
This commit is contained in:
3
deploy/example.txt
Normal file
3
deploy/example.txt
Normal file
@@ -0,0 +1,3 @@
|
||||
Files placed in this directory will be deployed to the RoboRIO into the
|
||||
'deploy' directory in the home folder. Use the 'Filesystem.getDeployDirectory' wpilib function
|
||||
to get a proper path relative to the deploy directory.
|
||||
@@ -1,19 +0,0 @@
|
||||
{
|
||||
"IntegratedAbsoluteEncoder": false,
|
||||
"AbsoluteEncoder": {
|
||||
"Type": "CANCoder",
|
||||
"ID": 12,
|
||||
"Offset": 72.070
|
||||
},
|
||||
"Motor": {
|
||||
"Drive": {
|
||||
"Type": "Neo",
|
||||
"ID": 7
|
||||
},
|
||||
"Steer": {
|
||||
"Type": "Neo",
|
||||
"ID": 8,
|
||||
"FreeSpeedRPM": 5676
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,19 +0,0 @@
|
||||
{
|
||||
"IntegratedAbsoluteEncoder": false,
|
||||
"AbsoluteEncoder": {
|
||||
"Type": "CANCoder",
|
||||
"ID": 11,
|
||||
"Offset": 39.551
|
||||
},
|
||||
"Motor": {
|
||||
"Drive": {
|
||||
"Type": "Neo",
|
||||
"ID": 5
|
||||
},
|
||||
"Steer": {
|
||||
"Type": "Neo",
|
||||
"ID": 6,
|
||||
"FreeSpeedRPM": 5676
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,19 +0,0 @@
|
||||
{
|
||||
"IntegratedAbsoluteEncoder": false,
|
||||
"AbsoluteEncoder": {
|
||||
"Type": "CANCoder",
|
||||
"ID": 9,
|
||||
"Offset": -115.576
|
||||
},
|
||||
"Motor": {
|
||||
"Drive": {
|
||||
"Type": "Neo",
|
||||
"ID": 4
|
||||
},
|
||||
"Steer": {
|
||||
"Type": "Neo",
|
||||
"ID": 3,
|
||||
"FreeSpeedRPM": 5676
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,19 +0,0 @@
|
||||
{
|
||||
"IntegratedAbsoluteEncoder": false,
|
||||
"AbsoluteEncoder": {
|
||||
"Type": "CANCoder",
|
||||
"ID": 10,
|
||||
"Offset": -173.320
|
||||
},
|
||||
"Motor": {
|
||||
"Drive": {
|
||||
"Type": "Neo",
|
||||
"ID": 2
|
||||
},
|
||||
"Steer": {
|
||||
"Type": "Neo",
|
||||
"ID": 1,
|
||||
"FreeSpeedRPM": 5676
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,37 +0,0 @@
|
||||
{
|
||||
"WheelBase": 23.75,
|
||||
"TrackWidth": 23.75,
|
||||
"WheelDiameter": 4,
|
||||
"Speed": {
|
||||
"MetersPerSecond": 1.25,
|
||||
"PhysicalMetersPerSecond": 5,
|
||||
"RadianPerSecond": 1
|
||||
},
|
||||
"Acceleration": {
|
||||
"MetersPerSecond": 1,
|
||||
"RadianPerSecond": 1
|
||||
},
|
||||
"Drive": {
|
||||
"Inverted": true,
|
||||
"GearRatio": 6.75,
|
||||
"MaxPower": 0.6,
|
||||
"CurrentLimit": 40
|
||||
},
|
||||
"Steer": {
|
||||
"Inverted": false,
|
||||
"GearRatio": 12.8,
|
||||
"MaxPower": 0.4,
|
||||
"CurrentLimit": 20
|
||||
},
|
||||
"Gyro": {
|
||||
"Inverted": false,
|
||||
"Type": "Pigeon2",
|
||||
"ID": 13,
|
||||
"CANBus": "canivore"
|
||||
},
|
||||
"Initial Pose": {
|
||||
"X": 0,
|
||||
"Y": 0,
|
||||
"Rotation": 0
|
||||
}
|
||||
}
|
||||
8
deploy/swerve/controllerproperties.json
Normal file
8
deploy/swerve/controllerproperties.json
Normal file
@@ -0,0 +1,8 @@
|
||||
{
|
||||
"angleJoystickRadiusDeadband": 0.5,
|
||||
"heading": {
|
||||
"p": 0.4,
|
||||
"i": 0,
|
||||
"d": 0.01
|
||||
}
|
||||
}
|
||||
26
deploy/swerve/modules/backleft.json
Normal file
26
deploy/swerve/modules/backleft.json
Normal file
@@ -0,0 +1,26 @@
|
||||
{
|
||||
"drive": {
|
||||
"type": "sparkmax",
|
||||
"id": 7,
|
||||
"canbus": null
|
||||
},
|
||||
"angle": {
|
||||
"type": "sparkmax",
|
||||
"id": 8,
|
||||
"canbus": null
|
||||
},
|
||||
"encoder": {
|
||||
"type": "cancoder",
|
||||
"id": 12,
|
||||
"canbus": null
|
||||
},
|
||||
"inverted": {
|
||||
"drive": false,
|
||||
"angle": false
|
||||
},
|
||||
"absoluteEncoderOffset": 6.504,
|
||||
"location": {
|
||||
"x": -12,
|
||||
"y": 12
|
||||
}
|
||||
}
|
||||
26
deploy/swerve/modules/backright.json
Normal file
26
deploy/swerve/modules/backright.json
Normal file
@@ -0,0 +1,26 @@
|
||||
{
|
||||
"drive": {
|
||||
"type": "sparkmax",
|
||||
"id": 5,
|
||||
"canbus": null
|
||||
},
|
||||
"angle": {
|
||||
"type": "sparkmax",
|
||||
"id": 6,
|
||||
"canbus": null
|
||||
},
|
||||
"encoder": {
|
||||
"type": "cancoder",
|
||||
"id": 11,
|
||||
"canbus": null
|
||||
},
|
||||
"inverted": {
|
||||
"drive": false,
|
||||
"angle": false
|
||||
},
|
||||
"absoluteEncoderOffset": -18.281,
|
||||
"location": {
|
||||
"x": -12,
|
||||
"y": -12
|
||||
}
|
||||
}
|
||||
26
deploy/swerve/modules/frontleft.json
Normal file
26
deploy/swerve/modules/frontleft.json
Normal file
@@ -0,0 +1,26 @@
|
||||
{
|
||||
"drive": {
|
||||
"type": "sparkmax",
|
||||
"id": 4,
|
||||
"canbus": null
|
||||
},
|
||||
"angle": {
|
||||
"type": "sparkmax",
|
||||
"id": 3,
|
||||
"canbus": null
|
||||
},
|
||||
"encoder": {
|
||||
"type": "cancoder",
|
||||
"id": 9,
|
||||
"canbus": null
|
||||
},
|
||||
"inverted": {
|
||||
"drive": false,
|
||||
"angle": false
|
||||
},
|
||||
"absoluteEncoderOffset": -114.609,
|
||||
"location": {
|
||||
"x": 12,
|
||||
"y": 12
|
||||
}
|
||||
}
|
||||
26
deploy/swerve/modules/frontright.json
Normal file
26
deploy/swerve/modules/frontright.json
Normal file
@@ -0,0 +1,26 @@
|
||||
{
|
||||
"drive": {
|
||||
"type": "sparkmax",
|
||||
"id": 2,
|
||||
"canbus": null
|
||||
},
|
||||
"angle": {
|
||||
"type": "sparkmax",
|
||||
"id": 1,
|
||||
"canbus": null
|
||||
},
|
||||
"encoder": {
|
||||
"type": "cancoder",
|
||||
"id": 10,
|
||||
"canbus": null
|
||||
},
|
||||
"inverted": {
|
||||
"drive": false,
|
||||
"angle": false
|
||||
},
|
||||
"absoluteEncoderOffset": -50.977,
|
||||
"location": {
|
||||
"x": 12,
|
||||
"y": -12
|
||||
}
|
||||
}
|
||||
17
deploy/swerve/modules/physicalproperties.json
Normal file
17
deploy/swerve/modules/physicalproperties.json
Normal file
@@ -0,0 +1,17 @@
|
||||
{
|
||||
"wheelDiameter": 4,
|
||||
"gearRatio": {
|
||||
"drive": 6.75,
|
||||
"angle": 12.8
|
||||
},
|
||||
"currentLimit": {
|
||||
"drive": 40,
|
||||
"angle": 20
|
||||
},
|
||||
"rampRate": {
|
||||
"drive": 0.25,
|
||||
"angle": 0.25
|
||||
},
|
||||
"wheelGripCoefficientOfFriction": 1.19,
|
||||
"angleMotorFreeSpeedRPM": 5676
|
||||
}
|
||||
16
deploy/swerve/modules/pidfproperties.json
Normal file
16
deploy/swerve/modules/pidfproperties.json
Normal file
@@ -0,0 +1,16 @@
|
||||
{
|
||||
"drive": {
|
||||
"p": 0.0020645,
|
||||
"i": 0,
|
||||
"d": 0,
|
||||
"f": 0,
|
||||
"iz": 0
|
||||
},
|
||||
"angle": {
|
||||
"p": 0.01,
|
||||
"i": 0,
|
||||
"d": 0,
|
||||
"f": 0,
|
||||
"iz": 0
|
||||
}
|
||||
}
|
||||
16
deploy/swerve/swervedrive.json
Normal file
16
deploy/swerve/swervedrive.json
Normal file
@@ -0,0 +1,16 @@
|
||||
{
|
||||
"maxSpeed": 14.5,
|
||||
"optimalVoltage": 12,
|
||||
"imu": {
|
||||
"type": "pigeon2",
|
||||
"id": 13,
|
||||
"canbus": "canivore"
|
||||
},
|
||||
"invertedIMU": true,
|
||||
"modules": [
|
||||
"frontleft.json",
|
||||
"frontright.json",
|
||||
"backleft.json",
|
||||
"backright.json"
|
||||
]
|
||||
}
|
||||
Reference in New Issue
Block a user