wierd arduino and l293d motor shield problems[SOLVED]

Hi guys,
I just bought a local arduino l293d motor driver shield in india.. About 11 USD.. I bought this due to my initial breadboard circuit failures and lack of enough soldering skills to make an motor driver circuit myself :frowning:

Now, I have been experinmenting with this past 3 days and I observe the following wierd behaviors..

  1. the 8th pin1(VCC) through which we provide required voltage to the motors in connected to the VIN pin of the arduino.. But whenever I power the arduino via an apple 5V adapter through USB... Even without the the vin pin connected to an external battery, the motor runs!! Can it happen???

  2. Each motor requires a two inputs HIGH or LOW based on which it send output to the motor.. In my case I have assigned 5,6 digital pins of arduino as HIGH and LOW while 9,10 as LOW,HIGH... But when I connect one of the input pin(note it is only one pin) connected to say pin 5, the motor starts running backward!! And it repeats when I connect ONLY ONE PIN to pin 10 again...

The motor moves backwards when connecting the another input pin alone to 5 or 10, it moves forward!!!

I can't deduce the problem to single component, my shield, arduino, motors or connections??
So can anyone pls shed some light ?? And sorry for the lengthy problem by the way.. :frowning:

Also you can visit this site in order to have a look at my shield:
http://allsensor.in/ProductDetails.aspx?SEOType=BSuwhmB9Ll4%3D&PID=3jII%2FQHIflo%3D&CType=ZgDIC937E8s%3D&CID=Ex1tZ6fBQBg%3D

cyberteen:

  1. the 8th pin1(VCC) through which we provide required voltage to the motors in connected to the VIN pin of the arduino.. But whenever I power the arduino via an apple 5V adapter through USB... Even without the the vin pin connected to an external battery, the motor runs!! Can it happen???

Don't do this, you are probably pushing high currents through a protection diode on the chip, it could
easily be damaged by doing this, or go into latch-up mode and fry. You can use an external rectifier diode to
bypass the on-chip diodes and protect against damage if you want (anode to 5V supply, cathode to motor
supply). Of course you may be overloading the 5V rail then, but voltage regulators are usually robust against
over-current.
Perhaps a better idea is to disconnect the motor if the motor supply is absent, then no high currents can flow.

  1. Each motor requires a two inputs HIGH or LOW based on which it send output to the motor.. In my case I have assigned 5,6 digital pins of arduino as HIGH and LOW while 9,10 as LOW,HIGH... But when I connect one of the input pin(note it is only one pin) connected to say pin 5, the motor starts running backward!! And it repeats when I connect ONLY ONE PIN to pin 10 again...

The motor moves backwards when connecting the another input pin alone to 5 or 10, it moves forward!!!

If you leave an input unconnected all bets are off - again don't do this, floating inputs can read as low or high, or oscillate,
basically its a bad circuit.

Perhaps a better idea is to disconnect the motor if the motor supply is absent, then no high currents can flow.

Sounds like a nice bet..

[If you leave an input unconnected all bets are off - again don't do this, floating inputs can read as low or high, or oscillate

But if I connect both the inputs for the motor, it does not run, be it 5,6 or 9,10!!

Also can you make a guess what could be wrong with this shield??

I have solved the problem of this unusal behavior of motors, which has been present right from my start of this obstacle detecting/line following bot project...
Being a noob, i have been using a 9V battery to power the L293D, which has been the biggest mistake right from the beginning. I never knew the that 9V battery could not supply the required current to drive the motors, and i thought it was the chip i had destroyed and had bought three more!!!(LOL :D)

Now that I came into my senses, I switched to AA batteries and every problem got solved..

Thanks for all for replying to my problems.. :grin: