Why build one
When I was reading about what the most important and most scarce things in robotics are, it was the actuators. They account for around 70 percent of the cost of each robot. I wanted to know why they are so hard to make, why they can't be customized easily, and why you need so much equipment to design, assemble and manufacture them.
I did a bunch of research and I kind of understood why. But I didn't fully understand, because I hadn't felt it. So I designed an outrunner motor, simulated it, had the round parts machined, and did the rest by hand.
I now feel why. I felt it gluing the plates together, and wrapping the stator by hand, and recoating the varnish, and turning the hub down on the lathe over and over until it fit. But the first time it spun was amazing. It isn't done. I'm still testing it, and I want to build a robot arm from scratch with this actuator.
How it works
Fourteen magnets are on the rotor outside and twelve coils are on the stator inside. The controller drives current through three phases in sequence, and the coils pull the magnets around. The drawing on the left is the actual cross section, from the file that was sent to the laser cutter. The one on the right is what the magnetic field looks like at the same moment.
Designing it in simulation
Before cutting anything I simulated the design in FEMM, a free 2D magnetics solver. I ran a few thousand solves to compare tooth widths, slot openings, air gaps and magnet sizes. That was slow on the CPU, so I moved the solve onto a GPU, which ran a batch about 27 times faster. The field picture above is one of those solves.
The first design fit 23 turns in each slot, but only with the wires packed the way a machine packs them. Wound as loosely as I can wind by hand, it would have held 14.
So I simulated 70 tooth shapes to find one with more room for wire that didn't lose torque. The one I picked has thinner teeth and a thinner back. I 3D printed it and wound it before cutting any steel, and I got 20 turns on. That is about 12 percent more torque for the same heat.
One slot between two teeth, before and after. Each circle is one turn of wire, drawn at the spacing I can wind by hand. The dashed line on the right is the first design's outline. Thinner teeth and a thinner back left room for six more turns.
I also added a 0.5 mm fillet on the inside corner under each tooth tip to match the other corners. It doesn't take any winding space, and the simulated cogging dropped to about a third.
A 0.5 mm fillet cut the simulated cogging to about a third.
Making the parts
The hub, shaft, face plate and rotor can were machined. The stator plates were laser cut from sheet steel. I did the rest by hand.


The stator plates have to be glued into one stack. I glued them one at a time on a 3D printed jig. I had to come up with a few different ways to do this before it worked.
This is where I learned how important it is to surface prep metal before epoxying it. Epoxy doesn't do anything if the surface isn't prepped.


The magnets needed their own jig. They pull toward each other, so they won't stay in their pockets on their own. A 3D printed plug holds them against the steel while the epoxy cures.
North and south alternate all the way around.


Insulating the stator
Magnet wire is copper with a thin enamel coating. The edges of the laser cut plates are sharp. If the wire drags across a sharp edge, the enamel comes off and the wire shorts to the stator.
So the stator has to be insulated before winding. It took me a few tries to get that right.




The first coat of varnish wasn't thick enough, so I had to recoat it multiple times. I also learned that varnish doesn't stick to sharp corners, so I had to Dremel them down. For the slots I tried PTFE tape first, and it was not good at protecting the wire from the corners.


Winding

Twelve teeth with twenty turns each. Wrapping the stator took me around nine hours, because I kept ripping the enamel off and shorting the wire to the stator. Every time that happens the tooth has to be unwound and redone.
It is also really hard to keep track of how many turns you have done. When you are trying to do 20, you have internal battles with yourself about whether you are on 15 or 16. You end up undoing it and doing it again. Then you make a mistake and have to undo it again.
Direction matters too. Some coils are wound clockwise and some counterclockwise, following the winding diagram on the laptop.


Then the rotor went on for the first time. The magnets pull the rotor toward the stator, so as it slides on it gets pulled down and smacks into place with a really satisfying click.
PS. Turn on the audio for this one.
First spin
The euphoria when it first spun was amazing. I clamped it to the bench, connected an ODrive controller and an encoder, ran the calibration, and it worked.
300 to 1,200 rpm in 39 ms at about 11 amps, then back down.
One burst as the controller logged it, at 8,000 samples a second, from a later run of the same test. Positive current speeds it up and negative current brakes it.

Simulation vs. measured
I had a simulation of this exact motor, so I wanted to see how close it was. I ran 17 tests in one afternoon.
Most of it matched. The main difference is that the motor makes about 11 percent less magnetic flux than the simulation predicted. Most of the other differences come from that.
Back-EMF is linear with speed, about 11 percent below the simulation.
Acceleration rises in a straight line with current up to 11 amps, so the steel isn't saturating.
Why is the flux low? I don't know for sure yet. The simulation is 2D and assumes a 1.2 mm air gap, a full height stack and magnets at their datasheet strength. The real motor is probably a little short on each. A few tenths of a millimetre of extra air gap would account for most of it. The plates being shorted together could also play a part, but the back-EMF stays in a straight line with speed, so I think that shows up more as loss than as missing flux.
Cogging is about four times what the simulation predicted. An ideal 12 slot, 14 pole motor only cogs 84 times per turn, and that part is small, like the simulation said. Most of what I measured is at 12, 14, 24 and 28 times per turn. Those show up when the teeth or magnets aren't identical, which makes sense for something glued together by hand.
Measured cogging is about four times the simulated range.
It takes 14 watts to spin at 1,000 rpm with no load.
That loss is mostly from the steel. Proper motor laminations are thin silicon steel. I used plain mild steel more than twice as thick because it was easy to get laser cut. The simulation predicted about the same torque with more loss at speed, and that is what I measured.
The plates also aren't insulated from each other like I thought they would be. When I checked with a multimeter, I measured continuity between the top plate and the bottom plate. So the epoxy didn't isolate them, and current can flow from plate to plate. That is exactly what laminations are supposed to prevent, so some of this loss is probably from that.
I also ran heating tests. Holding 8 amps with the rotor stalled took the winding from room temperature to 75 °C in five minutes. At 11 amps it went up 56 degrees in one minute. There is no temperature sensor in the motor, so the test script calculates the temperature from the change in the copper's resistance.
It can hold about 8 amps continuously. 11 amps is only good for a few seconds.
One thing went wrong. After the heating tests, the motor needed more and more current to hold the same speed and then couldn't hold it at all. The encoder offset had shifted by 82 electrical degrees, so the controller was driving the coils at the wrong time. I don't know yet what moved. I adjusted the encoder, checked that the offset stayed within a degree, and reran the test.
Spec sheet
- Layout
- 12 slot, 14 pole outrunner
- Size
- 82 mm across, 25 mm stack
- Winding
- 20 turns per tooth, 21 AWG, star
- Magnets
- 14 × N42SH, 25.4 × 12.7 × 3.2 mm
- Core
- 0.76 mm mild steel plates
- Air gap
- 1.2 mm, as designed
- Phase resistance
- 0.256 Ω
- Phase inductance
- 0.31 mH
- Torque constant
- 0.145 N·m per amp
- Speed constant
- 57 rpm per volt
- Peak torque
- 1.57 N·m at 10.9 A
- Continuous torque
- about 1.15 N·m
- Top speed
- 2,605 rpm on 48 V
- Rotor inertia
- 6.2 × 10⁻⁴ kg·m²
- Cogging
- 39 mN·m peak to peak
- Drag
- 14 W at 1,000 rpm
Everything electrical is measured on the bench. Torque figures come from current and the measured torque constant, since I don't have a torque sensor yet. Currents are peak phase amps.
What I learned
Surface prep before epoxy
Epoxy doesn't do anything on metal that hasn't been surface prepped first.
PTFE tape doesn't protect corners
It is not good at protecting wire from a sharp corner. The wire goes right through it.
Varnish doesn't stick to sharp corners
You have to Dremel the corners down before the varnish will stay on and actually protect anything. One coat was also too thin, so I recoated it several times.
One layer of tape isn't enough
Electrical tape needs two layers, cut into thinner strips so it wraps the corners.
Counting to 20 is hard
When you are trying to do 20 turns you end up arguing with yourself about whether you are on 15 or 16. Eventually you just undo it and do it again. Then you make a mistake and undo it again.
Epoxy doesn't insulate the plates
I measured continuity from the top plate to the bottom plate after gluing. The epoxy held the stack together but didn't isolate the plates like I thought it would.
Fit takes several passes
I had to turn the hub down on a lathe multiple times before the stator would fit over it.
I kind of understand all these steps now. It makes a lot more sense to me why actuators are hard to make and why they cost what they do.
It's not done yet. I'm still doing a lot more testing, and I really do want to build a robot arm from scratch with this actuator. But so far this motor has been a lot of fun.
