Arduino Nano - Servo motor SG995 not working but SG90 working

I am trying to build a robot using tower pro SG995 (2 nos) motor on arduino nano. Initially SG995 were working erratically & after sometime both SG995 stopped working all together. I check with other servo SG90 and it is working perfectly fine but not with SG995. I am using a 9volt battery for power supply.
Is the issue with SG995 or arduino board?
Can anyone help me out on this?

Link of robot I am trying to make. - https://www.instructables.com/id/3D-Printed-Robot

Below is the code-

//add the servo library
#include <Servo.h> 

//Create two servo instances 
Servo myservo; 
Servo myservo1; 
 
//Change this numbers until the servos are centered!!!!
//In theory 90 is perfect center, but it is usually higher or lower.
int FrontBalanced = 75;
int BackCentered = 100;

//Variables to compensate for the back center of balance when the front shifts
int backRight = BackCentered - 20;
int backLeft = BackCentered + 20;



//Setup initial conditions of the Servos and wait 2 seconds
void setup() 
{ 
  myservo.attach(8); 
  myservo1.attach(9); 
  myservo1.write(FrontBalanced); 
  myservo.write(BackCentered);  
  delay(2000);
} 

 
 
void loop() 
{ 
  
  //Walk straight
  goStraight();
  for(int walk = 10 ; walk >= 0; walk -=1) { 
     walkOn();
  }   
 
  //Turn right
  goRight();
  for(int walk = 10 ; walk >= 0; walk -=1) { 
     walkOn();
  } 
  
  
  //Walk straight   
  goStraight();
  for(int walk = 10 ; walk >= 0; walk -=1) { 
     walkOn();
  }  
  
  //Turn left  
  goLeft();
  for(int walk = 10 ; walk >= 0; walk -=1) { 
     walkOn();
  } 

} 


//Walking function
void walkOn(){
    myservo.write(BackCentered + 30);
    delay(1000);
    myservo.write(BackCentered - 30);
    delay(1000);
}


//Turn left function
void goLeft(){
  BackCentered = backLeft;
  myservo1.write(FrontBalanced + 40);       
}


//Turn right function
void goRight(){
  BackCentered = backRight;
  myservo1.write(FrontBalanced - 40);              
}


//Go straight function
void goStraight(){
  BackCentered = 100;
  myservo1.write(FrontBalanced);             
}

Details of the SG995 servo please. Neither I or Google have heard of it. Or do you perhaps mean a TowerPro MG995 servo?

If so then your battery probably won't provide enough power, particularly if it's a little rectangular PP3 type. The MG995 is a much more powerful servo than an SG90 and well known for being fairly power-hungry.

Steve

Hi,
Your tiny 9 volt battery is your problem!! just not enough current to drive a servo, well perhaps a minute! then (the battery power drops) so you try again and neither servo works!! It looks like these are full size servos and not miniture. So no chance.

Instruictables are very unreliable, many written by those who don't know how to!

Mel.

I applied 18 volts (9v + 9v) to the servos(MG995) and separate 5 volts to nano, still servos are not responding.

I rechecked with SG90 it is working is fine.

You needed more current NOT more voltage.You have a servo specified for 4.8-6V and you applied 18V, 3 times the maximum voltage, to it. Do you not see anything wrong here?

I would expect the servos are dead now unless you are still using weak little 9V batteries, in which case you might just have got away with it. Try four 1.5V AA alkaline batteries, they might have a chance of working.

Steve

Hi,
yes! what he said, again.
Regards

Mel.