|
Re: swerve drive
Hello,
On our swerve modules, we use two different sensors. One is to determine the angle that the wheel is pointed to. Like others have said, this is an absolute analog sensor. This is helpful because regardless of what angle the swerve modules are facing when the robot is powered on, they will still read the correct angle. Each of these sensors gets plugged into one of the 4 analog IO ports on the roborio.
The second encoder is used to determine the distance that the pivot has moved, similar to other drivetrains. This is mostly useful in autonomous, where the distance the robot travels needs to be exact. These sensors can be plugged into the digital IO ports on the roborio.
Also, may I ask what version of our code you are looking at (as in what year)?
~Laura
|