2024Beta
2024Beta copied to clipboard
REVLib SimDevice has confusing naming and doesn't support the AbsoluteEncoder.
The SimDevice
's are named "SPARK MAX "
with a trailing space. The additional space is easy to overlook and can cause errors when constructing a SimDeviceSim
object. Removing the space would be more consistent with the naming scheme used by WPILib.
Additionally, there is no way to set the value returned for position or velocity from the AbsoluteEncoder
object returned by CANSparkMax.getAbsoluteEncoder()
when running in sim. In sim, the getPosition()
and getVelocity()
methods return random values. Ideally this would have a sim value that could be set by the user.
Overall, increased simulation support in REVLib would be a very welcome addition.