Servo speed control is not precise.

So, here is the code)

#include <Servo.h>
Servo servo1;
float servoSpeed;


#define CALIBRATION_BUTTON_PIN 4


boolean calibrationButtonWasUp = true;
boolean calibrationLedEnabled = false;

float p3 = 0; // manipulator
int inputPin3 = A3;
boolean CCW = false;

int servoValue;

void setup() {
  // put your setup code here, to run once:
pinMode(CALIBRATION_BUTTON_PIN, INPUT_PULLUP);
servo1.attach(9);

Serial.begin(9600);
}




void loop() {


  boolean calibrationButtonIsUp = digitalRead(CALIBRATION_BUTTON_PIN);
  if (calibrationButtonWasUp && !calibrationButtonIsUp) {
    delay(1000);
   calibrationButtonIsUp = digitalRead(CALIBRATION_BUTTON_PIN);
      if (!calibrationButtonIsUp) {
        
        if (CCW== false) {
        CCW = true;}
        else {
         CCW = false; 
        }
        
        
      }
      
  }

  
p3 = analogRead(inputPin3);
servoSpeed = float(1500*(p3/1023));

//Serial.println(servoSpeed);
if (CCW == false) {

servoValue = 1500+servoSpeed;
Serial.println(servoValue);
servo1.writeMicroseconds(servoValue);}
else {
Serial.println(servoValue);
servoValue = 1500-servoSpeed;
servo1.writeMicroseconds(servoValue);

}

  
}

Servo starts its moving CCW with 1300us, then while the value changes up to 1041us the speed stays the same and becomes faster just after 1041 and then keeps the same pace up to 772, after 772 it again becomes faster and keeps the same pace up to 0. So, it has just 3 speeds CCW. ))) Chinese servos)

I looking at JX PDI-6221MG 360. It looks like it has a more precise speed regulation.