|
double armFeedVolts = armFeed.calculate(goalState.position, goalState.velocity); |
The kG portion of the feedforward should be based on the arm's current position (ie getArmPos()) and the kV portion should be based on the profiled velocity (ie setPoint.velocity). Neither should be based on goalState.