Need guidence on script to drive 2 DC motors concurrently

Hi Guys,
I am a noob here and experimenting with interfacing arduino UNO + Motor shield with a RC Track truck.
I started off using the test script controlling one motor and it works fine. The track truck has 2 DC motors powered by a 9.6V NiMH battery. I modified the test script for 2nd motor and it isnt working. Can you please reveiw the script and let me know the problem.
I made sure the led light on the motor shield lights up and using the same 9.6V battery to power arduino and the track truck and can see the debug output in serial monitor.

Let me know if you have any questions.
Thanks

#include <AFMotor.h>

AF_DCMotor motor1(1, MOTOR12_64KHZ); // create motor #1,64KHz pwm
AF_DCMotor motor2(2, MOTOR12_64KHZ); // create motor2 #2, 64KHz pwm

void setup() {
Serial.begin(9600); // set up Serial library at 9600 bps
Serial.println(“Motor test! modified run”);

motor2.setSpeed(255); // set the speed to 200/255
motor1.setSpeed(255); // set the speed to 200/255
}

void loop()
{

Serial.print("!!tick motor1 forward ");
motor1.run(FORWARD); // turn it on going forward
motor1.run(RELEASE); // stopped

Serial.print("tick motor2 forward ");
motor2.run(FORWARD); // turn it on going forward
motor1.run(RELEASE); // stopped

delay(3000);

Serial.print(“tock”);
Serial.print(“tock motor1 backward”);
motor1.run(BACKWARD);
motor1.run(RELEASE); // stopped

motor2.run(BACKWARD); // the other way
motor2.run(RELEASE); // stopped
delay(3000);
Serial.print("** motor1 & motor2 Released **");

}

motor2.run(FORWARD);      // turn it on going forward 
  motor1.run(RELEASE);      // stopped

Shouldn't that RELEASE be for motor2?

Please use code tags when posting code.

Thank you.
I made the correction and uploaded the code. It is still the same. There is no no hum from motors. I tested connecting the motor directly to battery and they spin fine. I measured the voltage across battery terminals and its 10.64. At M1 and M2 I am not reading any voltage, its 0. Please find the picture with connections.

learninglions: void loop(){     Serial.print("!!tick motor1 forward ");    motor1.run(FORWARD);      // turn it on going forward   motor1.run(RELEASE);      // stopped

You start your motor, then immediately stop it. No wonder it's not turning. Try putting a delay in between them.

Thank you Henry_Best. That helped with the issue.

Even though I was using M1 and M2 it was only spinning Motor1 and there was nothing happening on M2. I tried switching the connections and there was no problem with wiring or the motor. The second motor started working after changing code and connection to use M3 terminal.

The next issue I am running into is, when I put the car down the motors seems to be not producing enough torque and the car doesn't move. The tracks spin fine when I lift the car in air. After a few seconds I had to power off as there was a burning smell from the IC. I let it cool and checked to make sure that it didn't get fried yet. I read on the forum that somebody ran into the similar issue but didn't find a solution. Can I use these toy DC motors or do I have to use something else? Please let me know.

Thanks

learninglions: Can I use these toy DC motors or do I have to use something else?

What voltage are you connecting to the motors, and what is the motor stall current at that voltage?

Is your power supply capable of providing that current at that voltage?

Is your motor driver capable of providing that current at that voltage?

What voltage are you connecting to the motors, and what is the motor stall current at that voltage?

The battery is rated at 9.6V and when measured it shows 10.64 V using multi meter. I am not sure about stall current. When the tracks are on ground the motor is drawing 1.5 amps and still not able to move the truck. I hope this helps, let me know otherwise.

Is your power supply capable of providing that current at that voltage? Yes. I am using the same battery that was supplied with the track truck. The track truck works fine without Arduino + Motor shield .

Is your motor driver capable of providing that current at that voltage? I am using the motor shield with L293D chip and I attached the picture above.

Let me know if you have any other questions. Thank you.