Have you ever felt the urge to control multi-horsepower electric motors?
with an arduino?
Doesn’t quite work like that…
A few months ago, I did. During that time, Super LOLrioKart and the mini-CityCar were both looking for a compact 36 to 48 volt, 1-brushless-and-1-dc motor control solution of roughly the same power requirements. The attentive reader (all -2 of you) would notice that a few months ago, I didn’t yet possess the skills to design printed circuit boards, and I would be hard pressed to make a good power converter on the back of an Arduino protoshield, or a chunk of perfboard.
Actually, I’ve tried before, and it failed miserably.
But the cool thing about the MITERS clique is that there is alot of cross collaboration. Being mechanical engineers, Shane Colton and I naturally build electronics, power converters, and motor controllers (because those are totally things that mechanical engineers do). And so, at my constant (b)egging, he created the Hexbridge shield, and then refined it to version 2, which is more compact and… more functional.
And now, the (impending) torch has been passed to me. So my goal is to make this thing run a standard sensored brushless DC motor, kind of like a more elegant FVM. It would be the first time I code up a BLDC controller of any kind, Arduino or otherwise, and is the logical step after creating the Kartroller’s H-bridge drive.
The rundown on the Hexbridge shield (/Hexshield): 12-48 volts (nominal) operating range. 30 amps or so continuous operation, more (50-60+) with special attention and addons such as trace reinforcement. Six half-bridges grouped into two gangs of three, i.e. enough to make two BLDC motor controllers. The two gangs each operate off 1 Arduino PWM pin (namely, D9 and D10). The FETs are D2PAK IRFB3207 units, good to several quintillion amps and according to folklore, will desolder themselves long before burning up due to heat!
Because you the user programs the Arduino part, it really can be anything.
As noted, more shields can fit on top of the Hexbridge.
In this case, I’ve put together the Arduino WireBrushLess Tower, the future wireless brushless DC motor controller. The XBee radio module takes commands over the air and the Arduino can read them via its serial port. The idea is to have all of these controllable from a command console in order to make vehicles that go whichever direction you feel like without worrying about tangling control cables.
The small protoboard area next to the Xbee acts as a convenient signal interface stage. The long header presents 3 Hall Effect sensor inputs, logic power, and ground.
For now, I’ll forego the “wireless” part and just use a knob to control the thing. So, the small header is designed to take one knob as input.
In a coming post (when I get around to it), I’ll explain how the knob can actually be a very special magnetic absolute position encoder… for, you know, keeping track of the position of wheel modules which might spin more than 360 degrees at a time.
Here’s the knob wired up, along with some hall sensors.
… but from what are those hall sensors originating from?
The brushless Etek is my favorite Absurdly Large Load to test small controllers with. Everything from Turnigy airplane controllers to the DEC module has seen this thing. It’s both the largest “normal cheap motor” after Briggs and Stratton ditched the original Etek, as well as the smallest “big motor” that is easily available on the grey market.
I quickly whipped up some Arduino code using FVM as a guide for the state table. Overall, the process and structure are similar to what I made for Kartroller 6 – first arrange the outputs to account for the state of the system, then apply the throttle signal. In the case of Kartroller, the states were “forward” and “reverse”. With a BLDC motor like this, there are six states to cycle through to achieve one electrical revolution. “Reverse” on a BLDC motor is just stepping backwards through the table.
Here’s a video (10 megs .MOV) of some of the testing done with the Etek motor. Of course, it’s not a particularly strenuous test at all – the power supply limits itself to 3 or 4 amps at most. What it does show, however, is the built-in synchronous rectification topology that the IR21844s facilitate. Non-regenerative motor controllers will just let the motor coast if I let off the throttle, but a synchronous regenerative one automagically shuffles current in either direction to match the voltages between the motor back EMF and power bus.
Now, the problem with a power supply is that they generally do not approve of having current backfed into them. The voltage will spike as a effort to fight the inflow of current, and this power supply knew when to avoid getting hurt… That is why makers of regenerative controllers always advise putting a battery (or hugeasspacitor) in parallel between a power supply and the controller.
Well, that’s all for now. There are still three whole half-bridges left unused…