FRC1076 / 2019-Competition

Code for 2019 Competition
2 stars 1 forks source link

BallManipulatorController.getSetPoint() erroneously returns positive value for spit (throw) action #37

Closed mcolinj closed 5 years ago

mcolinj commented 5 years ago

The current design of the BallManipulator uses a positive constant for the SPIT_SPEED and then reverses the sign when using it. If that was changed, so the constant was negative, the BallManipulatorController would return the correct value.

mcolinj commented 5 years ago

The main principal at work here is to avoid duplicated information. If we find out that electrical has wired things backward, we ought to be able to change the code in a single place in order to fix the problem. If various sign manipulations are in several, separate locations in the code, then we risk missing one. We can avoid that potential problem by being careful with how we represent the information about the robot.

mcolinj commented 5 years ago

See if you can figure out how to record the working motor direction is a single place. (and then use that to derive all other values)