This should let us use differently-configured swerve modules in the Swerve subsystem. For example, the test robot uses TalonFX for both drive and steering, so we can construct a Swerve subsystem using the SwerveModuleTalonTalon subclass, and for the new robot that uses a TalonFX to drive and a Neo to steer, we can use SwerveModuleTalonNeo instead. If there are any other combinations of motors/controllers used in swerve modules, we can just implement another subclass of SwerveModule.
This should let us use differently-configured swerve modules in the Swerve subsystem. For example, the test robot uses TalonFX for both drive and steering, so we can construct a
Swerve
subsystem using theSwerveModuleTalonTalon
subclass, and for the new robot that uses a TalonFX to drive and a Neo to steer, we can useSwerveModuleTalonNeo
instead. If there are any other combinations of motors/controllers used in swerve modules, we can just implement another subclass ofSwerveModule
.