Pages: [1]   Go Down
Author Topic: Serial communication fails with motor driver using external PSU  (Read 756 times)
0 Members and 1 Guest are viewing this topic.
Offline Offline
Newbie
*
Karma: 0
Posts: 6
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Hi, I'm trying to drive a DC motor with this motor driver:
http://www.seeedstudio.com/depot/l298-dual-hbridge-motor-driver-p-284.html?cPath=170_173
The problem is, that when it's all powered from USB only (using only a small motor without load) everything works fine and I am getting serial readouts on monitor. But when I connect external power source to driver, of course connect PSU's and Arduino's grounds together, well, it still runs.. Arduino is still okay with controlling the driver, reacts to button inputs from breadboard, but the usb communication drops. I can still see Arduino in device manager, but IDE is stating that COM port was not found and TX/RX LED's on arduino board are also reporting zero activity. I have to disconnect the ext. PSU, restart IDE and reconnect Arduino, and only then is serial communication back online.
Got any help? I just can't find what is wrong...  smiley-sad
Logged

Offline Offline
Edison Member
*
Karma: 56
Posts: 2179
The last thing you did is where you should start looking.
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Schematic Please
Logged

Offline Offline
Newbie
*
Karma: 0
Posts: 6
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Something like this.. I'm not using exactly Pololu driver, but the wiring is the same. Arduino is connected to USB & there are more of the indicated buttons on the +5V/ground rail.


* MotorDriver.jpg (523.7 KB, 3588x1986 - viewed 26 times.)
Logged

Offline Offline
Edison Member
*
Karma: 56
Posts: 2179
The last thing you did is where you should start looking.
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

If you have a connection from the Drive +5V to the Arduino +5 volts, disconnect it.
Logged

Offline Offline
Newbie
*
Karma: 0
Posts: 6
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Well, the driver has Vin pin as the motor power input and the +5V pin for powering logic. Datasheet says it doesn't need to be connected if motor power input is over 7V, but I'm using 6V PSU for motors in this case, so I need to power the logic separately... and the arduino's +5V output looked quite tempting smiley-wink
Logged

Offline Offline
Edison Member
*
Karma: 56
Posts: 2179
The last thing you did is where you should start looking.
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

On the other hand, supply the +5 volts to the driver using an external 5 volt supply, not the Arduino's +5 volts.
Logged

Offline Offline
Newbie
*
Karma: 0
Posts: 6
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Thanks a lot! smiley I managed to find some additional 5V PSU for powering driver logic and it fixed the problem. But I still fail to see why is problematic to use the Arduino's 5V output in first place..
Logged

Offline Offline
Edison Member
*
Karma: 56
Posts: 2179
The last thing you did is where you should start looking.
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

There are current limitations to the Arduino hardware.
Logged

Offline Offline
Newbie
*
Karma: 0
Posts: 6
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

I'm well aware of that. But the current draw of driver logic should not exceed some tens of mA, while Arduino on USB should be able to source up to 500mA on +5V pin smiley-wink
Logged

Offline Offline
Newbie
*
Karma: 0
Posts: 6
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Just measured it, current draw is 30mA.. should be no problem even for an IO pin smiley-wink I think the problem lies somewhere in the connected grounds of external PSU and USB.
Logged

Pages: [1]   Go Up
Jump to: