I have a DC gearmotor (50:1 spur gearbox with roughly 1° of backlash at the output) turning an arm, with an encoder on the output shaft and a PID position loop running on a microcontroller. The arm reaches the target but never settles: it keeps swinging about ±0.5° around it at around 2 Hz.
Lowering the gains makes the oscillation slower but does not stop it. Removing the integral term stops it, but then the arm rests up to a degree away from the target. Is this a tuning problem or a mechanical one?




