High current protection using software?

Hello,

Even though I don’t know a lot about electronics I am planning to build an autopilot for my small boat. My plan is to use an Arduino Uno R3 and the Pololu Dual MC33926 Motor Driver Shield to power two 12V DC motors. Input should be coming from a gyro sensor, magnetometer and maybe a GPS. I want to power the shield using a 12V, 2A adapter (car type plug) and power the Arduino through the shield.

The only thing I’ve bought so far are the two DC motors and I’ve made a construction so they can control the steering wheel. It works fine even though the steering wheel has some friction.

My worry is about the stall current. The attached pdf file about my motors shows a graph that I don’t fully understand but I think I can read from it that the stall current should be about 1.6A?? With both motors stalled at 12V the adapter would be damaged. It’s hard to find a 12V car adapter that handles higher currents than 2A.

My plan is to monitor the current draw (using the sensors on the Pololu motor shield). I would program the Arduino to cut power to the motors when current of one of them gets above say 0.8A. After a second it would then try it again.

My question is: Would you think this works? Would this be enough protection against high currents? Any thoughts?

Thanks for your time!

Best regards,
Thomas

DC motor specs.pdf (65.4 KB)

Sounds like a fun project!

The graph is difficult to interpret, but I think your interpretation of 1.6 amps stall current is correct. You can easily check this by applying (for example) 3 V to the motor terminals and measuring the current with the shaft clamped. Then multiply by four. If kept short, this test should be safe for the motors.

Unfortunately, when DC motors start up, they briefly draw the stall current. That brief surge may not damage the adapter, but a long term stall would certainly be a problem.

On the other hand, the rated torque (1.14 kg-cm) seems rather small. Are you sure that this would be enough for all the situations you are likely to encounter in a boat? In a potentially dangerous situation, it seems unwise to automatically limit the motor current.

Finally, what is the ultimate power source? Why are you using a 12V “car adapter”?

One partial solution to what Jim says, is to ramp your current start. If you want to start at 6V, then start at 1V then ramp to 6V quickly but not too quickly. This will still involve a current peak, but less. In any case, heavy caps can help deal with the motor peak.

Mr Remington, Tomek, thanks for your reply and for your interest in my project!

I will test the stall current at a lower voltage as you suggested. My script should still contain protection against high current, I think, for in case one of the motors gets jammed. I will just give it a little time at high current to allow the motors to start. Hopefully the adapter can handle this…

These small motors are indeed strong enough to control the wheel of my boat. It’s a small open boat for use on the canals and lakes, here in the Netherlands. The wheel turns the outboard engine through a simple (manual) hydraulic system. Required force on the wheel is never really high and in a potentially dangerous situation I would take over manually anyway.

The reason I am planning to use a car adapter as my power source is that I’ve earlier installed a car socket in my boat, to charge my phone. It’s protected by a 2A fuse (that I could easily replace by a heavier fuse). Because the battery is 12V, I am guessing that the generator in my boat is 14V, which is higher than recommended for the Arduino. That’s why I thought a 12V car adapter would be a good and easy solution.

Best regards,
Thomas

Hi Thomas! Usually a car adapter is something like 12V–5V for USB. What kind of car-adapter do you have? I have not seen a (car battery)–>12V regulated, type car adapter. They must exist, but I do not know.

You are correct that car battery voltage can spike both on startup (in a car situation >14V and <9V) and just in general when the generator is running ~14V.

If you want something for (car battery)–>12V regulated high amp, I would look for something like a “universal 12V car laptop charger.” Here’s an example I don’t know if its any good. EDIT: my example was not good. i did not look closely, it was AC not 12vDC. But there probably exists a charger for laptops and cars that can supply 12V/5A or something like that.

But this should be >2A available.

If you can tolerate an exposed board (very hard on water), pololu has some step-down regulators and step-down-step-up (dual) regulators that could work. The higher amp ones are not super-affordable, though.

Sounds like a cool project :).

Another option: You can get a 12V regulator–>5V regulated. If it is OK quality, you can bypass the arduino regulator, and use this regulated source. Then, connect your driver direct to the 12V, it will be ok with fluctuations 12-16V, no problem.

I think maybe this sounds like a better option, if you are not worried about overdriving your motors. If you are concerned with that, then place a PWM limit (maybe 220 max pwm instead of 255. 14V*220/255= 12V)