From 5de1570643545cb1aad7ba77f668454525b453d9 Mon Sep 17 00:00:00 2001 From: thenetworkgrinch Date: Sat, 24 Aug 2024 17:48:05 -0500 Subject: [PATCH] Added fix for throughbore readings --- swervelib/parser/json/DeviceJson.java | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/swervelib/parser/json/DeviceJson.java b/swervelib/parser/json/DeviceJson.java index 776cc6e..5a99b46 100644 --- a/swervelib/parser/json/DeviceJson.java +++ b/swervelib/parser/json/DeviceJson.java @@ -69,11 +69,10 @@ public SwerveAbsoluteEncoder createEncoder(SwerveMotor motor) return null; case "integrated": case "attached": - return new SparkMaxEncoderSwerve(motor, 1); - case "sparkmax_analog": - return new SparkMaxAnalogEncoderSwerve(motor, 3.3); case "canandcoder": return new SparkMaxEncoderSwerve(motor, 360); + case "sparkmax_analog": + return new SparkMaxAnalogEncoderSwerve(motor, 3.3); case "canandcoder_can": return new CanAndCoderSwerve(id); case "ctre_mag":