usign L293D to control motors

i have a 2A brushed motor and a L293D driver IC board… i ran the below code using an arduino uno board…
the motors runs at very high rpm even with 1v supply.
int enablePin=9;
int a1=3;
int a2=11;

void setup()
pinMode(enablePin, OUTPUT);
pinMode(a1, OUTPUT);
pinMode(a2, OUTPUT);
void loop()
for(int i=0; i<=125; i++)
analogWrite(enablePin, i);
digitalWrite(a1, HIGH);
digitalWrite(a2, LOW);
i have connected only one motor to the driver and the arduino board is powered by the computer. a 9v battery was connected to the l293d board.
the motor did not run… first there was a high speed sound as if the motor was running. i thought this was beacuse the supply was not enough. then the noise stopped in a while. but the motor did not run at all. the l293d board got heated up.
Please tell me wat my mistake could be and how to rectify it.

What voltage is the motor?

Was the battery a PP3-sized one? If so you aren't getting anything like 2A from it.
If its a bigger one its probably OK, but is the motor 9V? I've not seen a 9V motor
very often, 3V, 6V, 12V, 18V and 24V are the standard voltages.

The L293D's practical upper current limit is about1A, nevermind what the datasheet
says, it will get HOT!