Electrical – Limit current of ESC by software

currentcurrent-limitingmotormotor controllerpwm

I am designing a cheap electric skateboard.

I have played around with various parameters for quite a while until I finally converged towards a specific motor and a specific battery. Lithium batteries are too expensive so I'm going for an AGM motorcycle battery. The problem is that the 0.025Ohm resistance of the motor leads to a huge current (hundreds of amps) up to 10km/hr which is most of my operational range. Other motors do not provide me with sufficient torque, therefore I need to include a current limiter to protect the ESC and maximise the battery capacity. For information, the continuous rating of the ESC I'm using is 60A.

I'm planning on measuring the current with a Hall Effect current sensor such as the Allegro modules out there, and an Arduino. Then map the current to a % of the duty cycle to subtract to the setpoint, before sending it to the ESC. For example, up to 30A => 0 feedback, 60A and above => 100% feedback, varying linearly in between. My gut feeling says it's basically a bang-bang controller which should be converging.

Any better alternatives?

Best Answer

You are probably overthinking this.

First, as soon a DC motor is rotating, there is an internal voltage source which works against the outer voltage. Second, the rotor coil of a DC motor is fed an AC voltage because of the commutator, which means its inductivity adds a lot of additional resistance to the circuit, depending on speed.

So, overcurrent is only a problem at a standstill and very low speeds. The usual way to handle this is to have thermoswitches at all interesting points (battery too!) and thermofuses as a measure of last resort.