When controlling a continuous rotation servo, the drive shaft should be completely stopped if the program has written the center point, ie. 90 degrees (correctly calibrated). I first noticed something was wrong while programming via GPIO, but even a reality check proves the issue exists:
#include <Servo.h> Servo servo; int positions[] = {0, 90, 99, 180}; int i = 0; void setup() { Serial.begin(9600); servo.attach(9); } void loop() { int position = positions[i]; servo.write(position); Serial.println(position); i++; if (i == 4) { i = 0; } delay(2000); }
When this is run, 0 spins full speed in one direction, 90 is a bit slower, 99 is stopped and 180 is full speed in the opposite direction. This should be stopped at 90.