Hello All,
I’ve got a SSC-32 hooked up to a Arduino Mega running the code below. It should move the servo between it’s two extremes over two different time duration, however the time paramater never seems to do anything.
Neither does the speed command
Any advice? What am I missing?
Happy New Year!
Cheers
[code]void setup() {
Serial.begin(9600);
}
void loop() {
moveT(0, 900, 5000);
moveT(0, 2000, 500);
}
void moveT(int servo, int position, int time) {
Serial.print("#");
Serial.print(servo);//channel/servo number
Serial.print(" P");
Serial.print(position);//Pulse width 500-2500
Serial.print(" T");
Serial.println(time);
delay(time);
}
void moveS(int servo, int position, int speed) {
Serial.print("#");
Serial.print(servo);//channel/servo number
Serial.print(" P");
Serial.print(position);//Pulse width 500-2500
Serial.print(" S");
Serial.println(speed);
}[/code]