My team is using NEOs, CTRE Mag SRXs for absolute encoders, CANSparkMax motor controllers and YAGSL. I’m only able to set a single conversion factor (which I’ve set to 360), and the code seems to only use the absolute encoder readings. While this is fine, will this pose any future problems, not using relative encoders due to the absolute encoders being slower or anything? And if so, is there a way to have YAGSL use the absolute encoder at startup and relative encoders while the robot is running?
here’s what our physicalproperties.json looks like:
{
"conversionFactor": {
"drive": 0.047286787200699704,
"angle": 360
},
"currentLimit": {
"drive": 40,
"angle": 20
},
"rampRate": {
"drive": 0.25,
"angle": 0.25
},
"wheelGripCoefficientOfFriction": 1.19,
"optimalVoltage": 12
}
And here’s what one of our module configurations look like:
{
"location": {
"front": 11.75,
"left": -11.75
},
"absoluteEncoderOffset": 3,
"drive": {
"type": "sparkmax",
"id": 6,
"canbus": null
},
"angle": {
"type": "sparkmax",
"id": 5,
"canbus": null
},
"conversionFactor": {
"angle": null,
"drive": null
},
"encoder": {
"type": "attached",
"id": 0,
"canbus": null
},
"inverted": {
"drive": true,
"angle": false
},
"absoluteEncoderInverted": false
}
Thanks in advance