The servo motor does not start

Hello.

I just bought this servomotor (Amazon.com: 20KG RC Servo High Torque Servo Motors with 25T Servo Horn, Dual Ball Bearing, Aluminium Case, Metal Bracket, Waterproof Metal Gear Steering Digital Servo for RC Car Robot DIY, Control Angle 180° : Toys & Games) and it won't start. My code is the following:

#include <Servo.h>

// Declaramos la variable para controlar el servo
Servo servoMotor;

void setup() {
  // Iniciamos el monitor serie para mostrar el resultado
  Serial.begin(115200);

  // Iniciamos el servo para que empiece a trabajar con el pin 9
  servoMotor.attach(9);
}

void loop() {
  
  // Desplazamos a la posición 0º
  servoMotor.write(0);
  // Esperamos 1 segundo
  delay(1000);
  
  // Desplazamos a la posición 90º
  servoMotor.write(90);
  // Esperamos 1 segundo
  delay(1000);
  
  // Desplazamos a la posición 180º
  servoMotor.write(180);
  // Esperamos 1 segundo
  delay(1000);
}

I have it connected to pin 9, GND and 5V. Before I had bought another servo motor that if it worked (this: Amazon.com: 4PCS Servo Motor MG995 Control Angle180 Metal Gear Servo 20KG Digital High Speed Torque Servo Motor for Smart Car Robot Boat RC Helicopter : Toys & Games), why not the new?

Because it hasn't got its own power supply?

1 Like

You're right, I put it on 5V and it needs 7.

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.