3D Printed Robot Actuator

A high speed and high torque robotic actuator using low-cost brushless motors, custom controller, 3D printed parts and bearings.

Public Chat
Similar projects worth following
I wanted to make a quadruped or biped with enough power to jump off the ground. Typical servo solutions were not good enough.

Design sections
Mechanical - Cycloidal gearbox with rolling elements, bearings and dual input and output shafts
Motor - Low-cost high torque Brushless outrunner using Multistar Elite Motors
Sensors - Dual absolute magnetic encoders for motor position and joint position
Electronics - Custom PCB including Mosfets with Mosfet driver DRV with Cypress PSOC4 SOC, sensor inputs and communications. Plus Magnetic Encoder PCBs
Software - Field Oriented Control (FOC) for position control. Mosfet Driver, Encoder and CAN communications.

The purpose of the Actuator is to create a design than I can easily make with a 3D printer using cheap and powerful Brushless motors from China. I have three prototype sizes of Cycloidal gearboxes 44mm, 60mm and 78mm diameter. The size of the motor, number of poles and their shafts are also adjustable.


Step File of the Whole Actuator

stp - 4.09 MB - 06/03/2018 at 06:13


Pack and Go files for Autodesk Inventor

x-zip-compressed - 21.85 MB - 06/03/2018 at 06:11


PSOC4 Project files Hardware and software (code) files

x-zip-compressed - 1.74 MB - 06/03/2018 at 04:17


ENC_MAG (3-06-2018 12-14-05 PM).zip

Altium project Schematic and PCB

x-zip-compressed - 485.14 kB - 06/03/2018 at 04:15


Adobe Portable Document Format - 100.01 kB - 06/03/2018 at 04:14


View all 11 files

  • Arduino Brushless FOC Controller

    Paul Gould06/18/2018 at 14:04 2 comments

    In an effort to make the controller accessible to more makers I've strated designing an Arduino based system. It uses the SAM D21 G 32-bit micro-controller as used on the MKRZERO board. This chip has an advanced Timer Counter Controller which can generate three centre aligned PWM signals. After sorting out the correct pin mapping it is up and running.

    The code is based on information provided in the Arduino forum by MartinL. 

    Now with deadband

    I will create a github shortly

    Next up dual SPI. One for the absolute magnetic encoder sensors and the other for the FET gate Driver IC.

    PID and FOC should be easily ported across.

    Voltage and current measurement may be difficult because the Arduino doesn't support free running sequential ADCs very well.

    The SAM D21 does not have CAN commucations so it will need RS485 and USB.

  • Biped Design

    Paul Gould06/09/2018 at 15:22 1 comment

    6x Actuators

    Do all the joints need the same size actuators?

    Are different reduction ratios required? Higher torque less speed.

  • Mini Quadruped Design (CAD)

    Paul Gould06/08/2018 at 16:16 0 comments

    12x Mini Actuators

    Needs a head, tail, electronics and batteries. 

    Two leg has been 3D printed. Some assembly required. See end of YouTube video. It's the little one on the left.

    I have made some 2 axis legs for testing. They have enough torque but the speed is huge, even under load. Jumping is not impossible. 

  • Actuator Testing

    Paul Gould06/01/2018 at 15:31 0 comments

    Testing using the Brushless motor, Cycloidal gearbox, Position sensors, Controller and LiPo Battery

    • 3kg of weights placed at 330mm distance from the center axis = 100kg/cm or 10Nm
    • The laptop sends a command to move between 90 (vertically down) and 180 degrees (horizontal)
    • 11.1V 3Cell LiPo (1500mAh 30C)
    • Peak Current while moving is about 6A @ 12V = 60W
    • Controller is set to 50% max PWM (I don't want to break anything yet)
    • 90degrees transit time is about 1 second @ 10Nm load

    My prototype actuator has a tested no load speed of 60deg in 0.2sec @ 12V, 4A @ 50 Max PWM

    I have not tested the max stall torque but 10Nm is currently suitable for my needs.

    The motor can handle 600W (22V @  27A) and the brushless controller can handle 4000W (40V @ 100A) (both dependent on cooling)

    In comparison, the Dynamixel MX-106R is the servo I wanted as it had 100kg/cm (10Nm) stall torque but it's no load speed is 55RPM and it cost ~US$500

  • PSOC4 Controller software

    Paul Gould05/16/2018 at 15:03 0 comments

    The software runs on the PSOC4 by Cypress and is a Programmable System on Chip which includes

    • 32-Bit ARM Cortex M0 (48MHz)
    • Programmable Digital Blocks - UDB  (Like FPGAs)
    • Programmable Analogue Blocks (Opamps, Comparitors, ADC, DAC)

    In the PSOC4 you can choose between fixed blocks (as in normal micro-controllers) or Universal Digital Blocks (as in FPGAs). So features  like SPI, I2C, UART, Timers and Counters (PWM), can be either fixed or custom. 

    I was hoping to say that is it fully configurable but it is really not. There are many limitations and work-arounds in both hardware and software. That being said, it is a brilliant chip, you can do many things without the CPU being involved at all. The sequencing SAR ADC is a good example of this. The IDE is good but hides too much low level functions. Things like being able to change the CAN ID on the fly meant searching through lines of undocumented c code.

    The software/configuration went through many iterations depending on the Controller version.

    Software Structure for Brushless Controller 2.0

    • Restore Configuration data from User Flash
    • Create Sin array from number of motor pole pairs
    • Configure Motor Driver
    • Enable Everything (Comms, PWM, ADC and IRQ)
    • The Sequencing ADC End of Conversion IRQ is the sub-routine for the controller loop
      • Read Motor and Joint position information
      • Read ADC information (Current, Voltage, Temp)
      • PID
      • Field orientated Control (FOC)
      • Sin to PWM output
    • CAN IRQ
    • Motor Fault IRQ
    • UART Debug Control and User Flash Configuration

    The sub-routine for the controller loop runs at 10kHz and uses about 20% of the CPU time. Not bad for a 48MHz CPU and doing FOC. The main reason it runs efficient is the that FOC array is pre-calculated to suit the number of poles of the motor being used. The other two phases are just offsets in the main array. The output from the PID is just a multiplied by the FOC array and shifted to get the three PWM signals. There are no sin and division calculations in the controller loop.

    The FOC array is based on modified sinusoidal waveform, often called saddle profile. It has the benefits of higher voltages between phases (than pure sin waves) and 1/3 less switching losses. The FOC array has 4096 (2^12) points and the Motor's Magnetic encoder has 16384 2^14 steps. Which is fine, because the encoder has some noise.

    The hardware and software has been updated to the "file page".

  • Actuator Controller - Hardware

    Paul Gould05/13/2018 at 15:03 0 comments

    From everything that was learnt from the hardware development a real / custom actuator had to be developed. After some research the best/easiest solution for me was the 3-Phase driver DRV8305 paired with 6x N-MOSFETs and the PSOC4 Processor. 

    Hardware for the Second Controller

    • Custom 4 Layer PCB 47mmx45mm
    • PSOC4 CY8C4247AZI-L485 ARM Cortex-M0 32-bit Processor with Programmable Analog Block and Programmable Digital Blocks
    • DRV8305 MOSFET Driver with integrated Current Sense Amplifers, SPI and PWM Control
    • 6x N-MOSFETs R-on-typical @ 0.7mOhms 40V
    • 3x 1mOhms Current Sense Resistors
    • CAN Transceiver
    • 25MHz Oscillator
    • LMR14206 Step Down Regulator
    • Optional (un-populated) - RS485, FET Temp Sensor, USB, Hall effect input, Sensorless operation 

    Brushless Controller 2.0

    There is not much to say about this controller. All components were "wired" up as per their datasheets. As the two main IC's have a lot of  integrated components inside there is not much interconnects required. 

    The angle of the motor and the joint is read by the AS5147s via SPI. PSOC4 uses PID to determine the required joint position and uses Field Orientation Control from motor angle to calculate 3 Sinusoidal values. These Sinusoidal values are converted to PWM signals to drive the 3-phase Driver. This intern drives the 6x N-MOSFETS to power the Brushless Motor. Control of the Actuator is done by CAN. 

    As the board was soldered by hand, the SPI link between PSOC4 and the DRV8305 helped to to pick up dry-joints and short-circuits on the MOSFETs, Current Sense Resistors and some DRV8305 pins. It had many fault and error registers which points directly to the bad connection.

    The Schematic and PCB has been uploaded to the "file page".

  • Actuator Controller - Hardware Development

    Paul Gould05/11/2018 at 17:30 0 comments

    The goal of the Actuator Controller is to 

    • Drive the Brushless motor at high speed and low speed including zero speed (holding joint position)
    • Joint Position Control PID 
    • Actuator Communications 

    Hardware for the First Controller 

    • PSOC4 Development board CY8CKIT-043
    • 3x Half Bridge Drivers BTN8982TA (10mOhms 55Amps 40V)
    • CAN Transceiver
    • Hall effect sensors for Motor commutation
    • Potentiometer for Joint Position

    Brushless Controller 1.0 (of many)

    The control of the Sensored Brushless Motor with Hall effect sensors was done by a "look-up table" in the digital Marcocells of the PSOC4, no CPU overhead is needed for Brushless comutation. Only Direction and PWM duty cycle are passed to the Marcocells. The hall effect sensors only had a resolution of 6 phases per electrical revolution. This worked ok at high speeds but the motors operation would not be smooth a low  speeds or when trying to hold a set position.

    Brushless Controller 1.1

    The Hall effect sensors used had a differential analogue output. In the previous control method they went into the PSOC's internal compactors. In this control method they can be read by the PSOC's differential ADC and a reasonably accurate electrical position can be calculated. Having full motor position information meant that Field Vector Control could be implemented. (More on this later) 

    The problem with using hall effects in this manner is that the distance between the hall effect sensor and the flux ring has a large effect on the voltage output. Also the type of sensor and thickness of the flux ring varies so much that it is not practical to use this technique for a general purpose robot actuator. For example, when used on the Multistar Elite 5008 the hall effect sensors gave a good sinusoidal output over one electrical rotation, every time took apart system and put back the Hall-effect board the amplitude of the sinusoidal output would change. Moving the hall effect sensors over to the Multistar Elite 3508, the effective diameter had to change but the sinusoidal output was very small.

    I came to the conclusion that the thickness of the flux ring on the Multistar Elite 5008 was too thin or the magnets are too strong, either way it is not the most efficient design. It let too much of the magnetic strength travel on the outside of the motor. By contrast the the Multistar Elite 3508 had very little magnetic flux on the outside of the motor. This is not good for using external hall effect sensors but at least the full magnetic strength can be potentially used

    Using external hall effect sensor with differential analogue to use Field Vector Control is not relieable for general use. Maybe internal hall effect sensors could work better but they would not be installed easily for different types of motors. 

    Brushless Controller 1.2

    No more Motor based hall effect sensors. Some other brushless controllers use quadrature optical encoders but these need to be referenced on power up. I prefer absolute position sensors, so a diametric magnetic is placed on the motor output shaft and the magnetic rotary encoder chip placed opposite to it. The first chip i used was a AS5043 10-bit SSI, PWM and analogue outputs with a Max 30kRPM (10KHz update rate). This is the "Magnetic Induction" that is used in the Hobbyking HK47360TM Servos, I had several of these in one of my original quadruped robots. The AS5043 and diametric magnetic replaces the normal potentiometer in the servo. It was setup using it's analog output set to 180 degree at full scale and low noise/slow mode. 

    For use as a absolute angle sensor with Brushless motors a few changes were made. Slow mode was changed to Fast Mode. The SPI from the PSOC was connected the AS5043 SSI which gave a 1024 counts per revolution. With the 5008 having 7 magnetic...

    Read more »

  • Sensors - Absolute Magnetic Encoders

    Paul Gould05/10/2018 at 16:05 0 comments

    The position sensor board uses the AS5147 is a 14-bit Magnetic Encoders

    One for is used for the motor electrical position/angle. One is used for the joint position/angle. The are connected via daisy chain on SPI communication with 2x 16bit clocking. There is a piece of Silicon Steel between the two sensors boards to prevent cross flux of diametric magnets.

    The technical information for the system:-

    • 14500RPM (240 REV/sec) 
    • Multistar Elite 5008 motor maximum speed 7000 RPM
    • 7 Pole pairs
    • 10kHz sample rate (85 samples per revolution at full RPM)
    • 12 samples for electrical rotation at full RPM
    • DAEC™ dynamic angle error compensation

    This basically means that they are quite suitable for this application.

    The Schematic and PCB has been uploaded to the "file page".

  • Motor Modification

    Paul Gould05/10/2018 at 15:26 0 comments

    The Hobbyking range of Multistar Elite Brushless motors are powerful and lightweight.  I have paid between AU$25 and AU$75 for the Multistar Elite 5008. They do need to be modified to be integrated into the robot actuator. The shaft has been replaced with a longer one (with a hole) and the base has been reduced in size and weight.

  • Mechanical Design - Cycloidal Transmission

    Paul Gould05/06/2018 at 14:58 5 comments

      Typical Cycloidal Transmissions consist of four main sections.

      1. Input shaft and eccentric bearing
      2. Cycloidal Gear(s)
      3. ring pins and housing
      4. Output rollers and shaft

      The way that the sections are arranged are with the input shaft on one side and the output shaft on the other and the housing in the middle.

      This means that the output rollers are based on the "Fixed-Free Beam Moment" and are not suited to high torque operation when 3D printed.

      This design's output support pins are based on the "Fixed-Fixed Beam Moment". This means the housing and the output rollers are dual sided. The motor input shaft is only single sided. This all works well on 3D printed parts as the forces on the steel output support pins are spread over a large area in the ABS material. A huge credit goes to Mike Buckingham for his idea on making the input shaft go through both the housing and output shaft. Sure it increased the complexity but it made the design usable.

      The CAD files are uploaded to the "files page".

      There are two sizes of Cycloidal Transmissions but they are identical in their design. 

      Thin wall Bearing 6809 58x47x7
      Hobbyking Elite 5008-330KV (6s 600W)
      Shaft size 6mm
      Eccentric offset 1mm
      Reduction Ratio 1:25
      Cycloidal Gear "Teeth" 25
      Ring Pins 26
      Output Support Pins 8
      Thin wall Bearing 6807 47x35x7
      Hobbyking Elite 3508-268KV HV (8s 300W)
      Shaft size 4mm
      Eccentric offset 1mm
      Reduction Ratio 1:20
      Cycloidal Gear "Teeth" 20
      Ring Pins 21
      Output Support Pins 8

      Using Equation Curves in Inventor to draw Cycloidal gears using the epitrohoid equation.

      I will have to get the exact numbers for my gears.

View all 11 project logs

  • 1
    Actuator Assembly

    1x Brushless motor with extended shaft (6mm Silver Steel)

    1x Custom Brushless Controller Board

    2x AS5147 Absolute Position Boards

    2x 6mm x 2.5mm Diametric Neodymium Magnet

    12x 3D printed parts

    16x 5x8x2.5 bearings

    2x 6809 Bearings

    5x 12x18x4

    1x 6x10x3

    8x 3mm dia x 30mm Silver Steel shaft

    26 (or 13) 3/32" x 28mm Silver Steel shaft

    26 (or 13) 1/8" x 16mm Brass tube (thin wall)

    24x M3 bolts

    10x M2 Bolts

    3x PZT screws

    1x M6 thin wall washer

    1x 2mm dia x 11mm Silver Steel shaft

  • 2
    Sources of information


    • CCDIY 3D filiment
    • Plaig Bearings
    • MiniTech
    • Digikey/Mouser
    • Apollo Bearings

    Favorite Makers

    • Makers Muse
    • AVE
    • Clickspring
    • Tom Stanton
    • Ivan Miranda
    • James Bruton
    • Gear Down For What?
    • MRB Engineering
    • Thomas Sanladerer
    • ODrive Robotics
    • Benjamin's Robotics
    • Laura Kampf
    • Tested

View all instructions

Enjoy this project?



lion mclionhead wrote 07/08/2018 at 07:09 point

Didn't have much luck with this concept.  Direct drive is a bit too power hungry.  Modern brushless servos can do pretty incredible things for a lot less money.

  Are you sure? yes | no

Paul Gould wrote 07/08/2018 at 09:09 point

Hi lion, this design is not for everyone. It's not direct drive, the cycloidal gearbox is 25:1 reduction. The cost is about $150 (the time is huge). The aim is 20Nm (200kg-cm), with speed of 0.05sec/60deg (testing required). The backlash is extremely low and it also backdriveable. I created this because I couldn't find a servo that suited me, if you know some good servos please let me know.

  Are you sure? yes | no

Alan Timm wrote 07/08/2018 at 02:30 point

I have an updated design.  The bolts helped, but the actuator still binds when the assembly is compressed axially.  This new version includes aluminum spacers.  Switch back to version 50 for a better view.

I built a prototype of the base design.  Clearances look good, I'll print out a new prototype when the spacer parts come in with PETG.

It looks like you're planning on using these at 12v.  Would it be reasonable to assume that it should approach 20Nm of force at 24v?

I've been looking at your spring compliance setup.  I don't see a 3rd sensor for spring deflection.  I think... that if you're measuring shaft count / position and joint position after the spring you should be able to derive force and imitate compliance.  I have an idea or two on how to integrate that into the actuator.  

And after futzing about a bit with the stm32f103, and then moving to the stm32f302 after realizing that the 103 makes you choose between CAN and USB, it dawned on me that there is no point.  The PSOC 4 is a good fit for this application and seems to work well.  PCB design isn't my strong suit, but I'm working to convert your design to a circular board integrating an AS5147 in the center, and using one of your carrier boards underneath for the motor shaft.  This minimizes the SPI cable length, and puts the electronics right on the actuator.

Speaking of which, where are you guys finding the AS5147/AS5047?  Mouser and Digikey are out.

  Are you sure? yes | no

Paul Gould wrote 07/08/2018 at 03:29 point

Your actuator looks good. Go to Discord->Odrive->robotics. Others are making this actuator in metal. I plan on running this on 8S (32V) MOSFETs are rated at 40V. I'm hoping for 20Nm with the 5010 motor. I'm looking at the 6215 Brushless 170KV. 

I have just made a jumping stand for one leg. I haven't added the spring feedback sensor yet. I am trying to work out how to store the spring energy. 

The more I work with SAMD21 (Arduino) and STM32fxxxx the more I like the PSOC4. If you are going to redesign the board, you should use the drv8323 instead. It is much better and has in integrated buck reg. I have started a design/PCB with it. Let me know if you want to see it. (What software are you using?)

I purchased a few AS5147 for testing last year. I am trying to find more but nothing yet.

  Are you sure? yes | no

Alan Timm wrote 07/08/2018 at 04:49 point

I thought the 5010 was spec'd out at 6S 24v max?  Maybe temperature dissapation is the limiting factor.  In that case 32v sounds like fun.

I've been using KiCad.  I grabbed Altium Viewer to get a closer look at your board.  Electronics is a weak spot for me, but I can follow most of the datasheets and documentation.  I'm using your Cypress codebase to learn PSOC creator.

Here's a sketch of what I have in mind.  A circular board with an AS5147 mounted dead center, keeping the electronics close.   No long SPI runs, just power and CAN to each actuator.  motor shaft AS4187 mounted on a carrier board underneath.  USBUART for pre-install configuration.

  Are you sure? yes | no

Paul Gould wrote 07/08/2018 at 06:53 point

The 5008 is 6S max and the 5010 is 8S max but it is rated at continuous operation with a lot of air flow. The PSOC code needs to be tidied up, sorry. The round board looks good. 

  Are you sure? yes | no

Gabrael Levine wrote 07/08/2018 at 04:31 point

I've been using the AS5047 boards from However, they only sell assembled boards and not the ICs themselves, so I don't know if that's any use to you. 

  Are you sure? yes | no

Alan Timm wrote 07/09/2018 at 23:24 point

Yeah, looks like both the AS5047 and AS5147 are out of stock in the usual places.

Per Paul, the AS5601 isn't suitable.  

There's also a MA700GQ-P that support SPI, but would require a carrier board change and most likely some code changes as well.  Paul says that this one might work.

  Are you sure? yes | no

Gabrael Levine wrote 07/01/2018 at 22:27 point

Great design! Do you have an estimate of the torque-to-weight ratio? I'm working on a similar project ( that puts out 56 Nm of torque and weighs 1.2 kg. I'm curious how that compares to the specs of your actuator. 

  Are you sure? yes | no

Paul Gould wrote 07/02/2018 at 16:13 point

The actuator weights 536g with all the electronics and cables. (Not including battery). 

Theory - The Multistar 5008 330KV has a Kt of 0.029 (Nm/A). Max Amps = 27A and a gear ratio of 25:1 x 75% Efficiency = 15Nm

Testing  - (As in the video) Lifted 3Kg at 330mm = 10Nm (Voltage and Amps need to be rechecked).

I haven't pushed it to hard yet and I only have 1/2 the external pins in. 10Nm is enough for my application. I am hoping the big quad i'm making with Series Elastic Actuators with be about 10Kg (including some light/small batteries and with minimal sensors)

I like those large high pole count motors. I wanted to use them but I would have to change my control scheme and not use the magnetic encoder (only works well at 7 pole pairs). I just read that you are using the AS5047 magentic encoder with O-Drive. How well does it handle 0RPM holding positions?

  Are you sure? yes | no

Gabrael Levine wrote 07/02/2018 at 21:58 point

The AS5047 has been working perfectly so far. No issues with holding positions at 0 RPM. Currently I'm just using the incremental ABI interface, but I'm going to set up the absolute position interface so it doesn't have to search for the index pulse on startup. 

I see you're using the AS5147. How come you say it's limited to working with 7 pole pairs? That sensor has a resolution of 2048 CPR according to AMS' website, which should be plenty for any high-pole-count motor. 

In regards to the efficiency of your gearbox, have you measured it at 75% or is that just an estimate? 75% seems low for a single-stage cycloidal reducer. If you're having issues with sliding friction, I recommend printing the cycloid disks out of nylon. I used Taulman Alloy 910 for the gears in my design and they run very smoothly. 

  Are you sure? yes | no

Paul Gould wrote 07/03/2018 at 14:19 point

Gabrael - The data sheet of the 5147 says the the UVW interface support 7 poles pairs, so I assumed that it should only be used with 7pole pair motors for all the interfaces. I might be wrong on this and will have to do more research. I would like to use the higher pole count motors with a lower KV and higher torque and lower gear reduction. 

Did you try any other motor? How long does the 9235-100KV take to spin up to full speed? What RPM are you getting?

I haven't measured the efficiency yet, I would rather underestimate. I don't think I am having sliding friction problems, it is all rolling elements. I have some Nylon but I have to upgrade my printer so that it can reach a higher temperature.

  Are you sure? yes | no

Gabrael Levine wrote 07/04/2018 at 02:09 point

The 7 pole pair limitation only affects the UVW interface, since it outputs commutation signals for each of the motor phases. Since you're doing the commutation from the microcontroller, you can use any number of pole pairs you want. 

The 9235-100KV spins up really fast. See here:

The max RPM should be 2400 (24 volts * 100 rpm/volt). I haven't confirmed this though. 

These 9235 motors are great, by the way. They have so much torque you could use them in a quadruped with no gear reduction at all. 

  Are you sure? yes | no

John wrote 07/01/2018 at 20:44 point

Your design is impresive! It got me to thinking about how animals and insects can jump so well. In biological systems that are "jumpers" (fleas, grasshoppers, kangaroos, even humans), the tendons are loaded before a jump, and then the "release" happens ... which basically adds a spring into the system. There are linear wound springs (like in a dog walking leash - but stronger!) that might be usable in your system. You would have to "pre-wind" the spring, and then trigger it. Given a strong enough spring, you could get some pretty decent "instant" burst of power from a "small" addition. You mention backlash; if you have rotational transducers, couldn't you just "fix" that with software? That might introduce too much delay, maybe. Best of luck, and keep posting! Between you and Mike's Robot Dog (see:, y'all are making me want to get a 3D printer, or learn to cast brass, etc!

  Are you sure? yes | no

Paul Gould wrote 07/02/2018 at 15:48 point

I am working on creating a video of the parallel linked series elastic actuator that is on the big quad. I am trying to work out how to store the spring's energy on foot fall/ landing and release it later in the gait. 

The backlash is quite small, it is the main reason I chose the Cycloidal gearbox design. It is more than good enough for e quad, maybe not for a robotic arm. I was after speed and torque rather than precision. 

  Are you sure? yes | no

Alan Timm wrote 06/28/2018 at 18:05 point

Hey Paul, I've been really studying your actuator model, and I have a few suggestions that I'm incorporating into my build.  The rest of my parts should be arriving next week.  Here's a link to my work in progress model:

 - If you separate the eccentric lobes you can pin them separately during assembly. I'm pretty sure that having a single pin driving both lobes is going to be the weakest point at load.  I'm also looking at 2mm v 3mm retaining pins.

 - I've reduced the drive rollers from 8 to 6, and included 6 through hole bolts.  The locknuts need to be trapped into the motor bracket earlier in the assembly.  This should make the actuator much stronger.  I'm on the fence between having 6 drive rollers and 6 bolts, or going 4 and 4.

I hacked together a parametric cycloidal gear box generator into Fusion 360, changing ratios is almost automatic by adjusting the parameters.  I've been going back and forth between a 26:1 and 32:1 gear reduction for the Gartt 5010.  Out of curiousity, what design software are you using?

On the electronics side, I have even more catching up to do.  How are things going on your next controller?  Depending on how invested you are in your SAM D21 design, the stm32f103c8 may be another option.  It's what's used in the "STM32 blue pill" board.  They're cheap, fairly well supported, and include CAN as well as a bunch of other features.  

  Are you sure? yes | no

Paul Gould wrote 07/02/2018 at 15:42 point

Hi Alan, Adding the bolts is a good improvement. Just be careful you still have enough material at that diameter so that it doesn't weaken the gear. I tried to replace the 3mm rods with M3 bolts with a long shank. I had some problems getting the alignment correct. (It also took along time to take the unit apart). 

I have just created a parametric cycloidal gear in Autodesk Inventor (All my CAD is done in this program, I have it on my laptop for my day job). 

Have a look at the testing of the motors here

This is main reason I choose the Multistar Elite 5010/5008. I am looking at Foxtech and Arris for their 5010 motors but I just searched the Gartt 5010 on ebay and they are 1/2 the price. mmmm

I got the SAM D21 up to the point where I don't like the CPU. The SPI only has a single buffer TX and RX and requires the DMA to use it properly/efficiently. I wanted to create an easy solution (Arduino) for brushless actuator control. I'm not sure if I can hide the DMA in an Arduino library. I have thought about using the STM32F3 family but the PSOC4 is just so good. The problem is that is too complex for most makers.

I have some STM32Fx development boards so I will see what i can up and running. The stm32f103c8 will still require the use on DMAs for the SPI unless I change the structure of the code/interrupts.

  Are you sure? yes | no

MattB wrote 06/26/2018 at 04:00 point

Hi! In your video you showed it pulling 10 Nm @ 12 V with a peek of 5 amps. This is with the Multistar elite 5008 & a 26:1 gear ratio, right?

I love the results, but am a bit confused. The 5008 is 330 Kv, which would be a Kt roughly 0.029 (Nm/A). 

0.029 * 5 = 0.14 Nm * 26 = 3.75 Nm

Which is way under 10 Nm. Is there something I'm missing?

  Are you sure? yes | no

Paul Gould wrote 06/26/2018 at 10:49 point

Hi MattB, Your maths is right. I have never done the Kt calc befre. Where did I go wrong? 

The arm is ~330mm between the centre of the 3kg weight and the pivot point. The battery is 3 cell Lipo ~12V. The cheap current sensor from Hobby King max value shows ~5Amps. I would guess that the filtering / averaging / update rate of the current sensor is not showing the actual peak. Is it the measurement Amps RMS?

I wonder what the efficiency of the cycloidal gearbox is. I would be surprised if it was over 80%. 

Hobbyking claim that the KV is 330. I should be able to check this. Does the KV change as the speed approaches 0RPM/stall?

Does the Saddled Sine wave output of the controller give a different reading than a normal sine wave. Could this effect the Kv and Kt values?

As the arm moves from Vertically down to horizontal the torque required will increase. Maybe it is better to use a large pulley with a weight as this torque will be constant. 

I will set-up the test again with better equipment and post the results. It would be nice if the theory matches the actual.

  Are you sure? yes | no

Alan Timm wrote 06/20/2018 at 15:51 point

Hey Paul, this is an outstanding project, and congratulations on your win! 

For the parts that require you to center them, it would be a snap to design and print a centering spacer to use during assembly. 

I've been eyeballing the failure modes, and I think the first part to fail at load will be the eccentric bearing lobes. That's based on the stresses between the top and bottom lobe and a single eccentric bearing pin, which I assume is going through the center of the top lobe. Maybe sticking a second pin through the center of the lower lobe would help mitigate that?

And, did I see that you can backdrive the actuator? I wouldn't have expected that.
I have to admit that I've watched this video about 12 times already to understand how you've accomplished this. I'm looking forward to building a couple of these to see how they work. 

Aliexpress would be a great source for most of the parts like the bearings, bulk 2mm x 28mm steel dowel pins, and 3mm (2.6mm internal) brass tubing.  the 2mm pins are a bit smaller (15%) than the 3/32".  Do you think those will work?  Otherwise there are other sources for true 3/32" x 1 1/8" steel dowel pins.

Can you share a bit about the modified axle/shaft?  Did you fabricate it?  Or is that something that can be found and ordered online?

  Are you sure? yes | no

Paul Gould wrote 06/23/2018 at 15:38 point

Hi Alan, I tried to put a second pin in the eccentric top lode but the "order of assembly" did not allow it to happen (unless I press fit the motor on the main shaft after assembly, this was not going to happen). I get silver steel rods from minitech and the brass tubes from the local hobby shop. I always buy local if I can get the right part (no matter what the cost) and only order overseas if I have too. i prefer to make parts from scratch if I can. Hacksawing a rod and filing the ends are easy to do.

The main 6mm shaft is a silver steel rod from i just file a flat spot for the motor's bell grub screw and drill a 2mm hole for the pin at the right distance for the second lobe. I don't have many tools. (Cheapest 3D, cheapest drill press, cheapest vice and files and that's it). I can use my vice as an arbor press. I pressed out the motor's original shaft and pressed in longer 6mm silver steel shaft

  Are you sure? yes | no

neilmbajaj wrote 06/19/2018 at 23:16 point

Can the actuators be backdriven? I suppose if you want it to stand passively, you would not want that, bu it seems like putting the bearing in, on at least the interior pins, could greatly reduce internal friction. 

Since your external pins touch two of the cycloid rings at once, would bearings not help there? Your cad odel appears to have bushings over the exterior pins, but i feel like they might have the same issue.

Backdriveable actuators are especially nice when you want to do force control, or try to map motor current to torque, which might be useful when trying to make this robot walk or jump.

  Are you sure? yes | no

Paul Gould wrote 06/20/2018 at 01:00 point

The Actuator is backdriveable. It is only a 26:1 ratio. I think that having it backdriveable with regenerative capabilities is a must for overall efficiency. I had a prototype with bearings on the outside pins but the reduction ratio was lower because of the bearing spacing around the circumference. Also that is a lot of additional bearings, which increases cost and weight. Series Elastic actuator is also much better for efficiency (the big quad design has this). I am also trying to work out how to store potential energy from the elastic actuator (spring). Store the energy on a foot fall and release when going to jump/step.

  Are you sure? yes | no

Dan Royer wrote 06/19/2018 at 19:42 point

I saw a project recently that used an atmospheric pressure sensor (very small) wrapped in a rubber material.  When the rubber touched a flat surface the pressure on the sensor was registered.  Made for a really quick contact sensor for feet.  Might be useful for your quad walker.

  Are you sure? yes | no

Paul Gould wrote 06/20/2018 at 01:04 point

That is a nice idea but it will only tell you after you have hit the ground. It would be nice to know just before then so that you can turn off the motors so the joints are a bit "softer".

  Are you sure? yes | no

Dan Royer wrote 06/20/2018 at 01:09 point

how about... if the motor senses resistance and the foot is not touching then we know it's not ground interference.  not sure what the logic branch from there would look like, tho it's an interesting edge case...

  Are you sure? yes | no

K.C. Lee wrote 06/20/2018 at 08:36 point

The sensor deforms make contact before the leg reaches all the way down and transfers its full weight.  It is like the pads and hairs on the bottom of a cat's feet can provide feedback for the cat to walk quietly.  Or your keyboard keys making contact before it reaches full stroke.
Pressure can travel, so the sensor doesn't need to be where actual impact happens; 

  Are you sure? yes | no

albertson.chris wrote 06/19/2018 at 18:10 point

Maybe just to re-state one point.  I had the idea that a motor controller should live INSIDE a length of the 25x25 tube.

I had a robot fire a year of so ago.  I has dumb and THOUGH the cable has protected from overcorrect but the design was faulty and I vaporized a #8 cable (3mm diameter copper conductor)  I

I saw that 25x25 tube and though "use it as conduit", "use it as housing for electronics", "use it as a heat sink",  "EMI shielding if you ground it." "I wonder of batteries will fit inside?"   

I thing the most valuable space in the robot might is the inside of the 25mm square tubes

Robots like these and to fall and take bubbles down stairs or worse the limbs get into self-collisions and rip wires from each other.  At least until the motional planner is fully debugged.

I know first hand that LiPo battery fires can't be put out, you just have to wait.

  Are you sure? yes | no

albertson.chris wrote 06/19/2018 at 03:25 point

I think a good way to design a motor driver is to look at what controls the driver.   I think anyone building a walking robot is going to be using ROS/MoveIt or ROS/TOWR so you'd want to run ROS Serial and a joint controller node on the driver.  It would save a ton of work to build the controller on a CPU platform that can run ROS Serial.    Not looking upward at the higher level controller might mean you later have to introduce a layer between.  A chain of controller adapter PCBs is ugly.   

STM makes the STSPIN32F0 with builtin MOSFET drivers the chip is designed for robotics and BLDC motors.  

The higher level controller likely a "Joint Trajectory Action Controller" attempt to place joints in space at a given time and velocity within the limits of the hardware.  This is the controller this driver will need to interface with.  best to make it seamless.  

All that said.  I'm pretty sure I'll be using a stepper motor at fist.  Steppers are easy to control.

  Are you sure? yes | no

ꝺeshipu wrote 06/19/2018 at 07:23 point

> I think anyone building a walking robot is going to be using ROS/MoveIt or ROS/TOWR so you'd want to run ROS Serial and a joint controller node on the driver. 

If you look at the walking robot projects (, you will notice that very few of them use ROS in any way.

  Are you sure? yes | no

albertson.chris wrote 06/19/2018 at 17:35 point

But they also lack any interesting behavior other than walking.     What's the point of that?   I would think the reason you use legs rather then wheels is because wheels can't work for you application.    But so many of these robot have no application.

As a minimum, I'd want antonymous navigation and route planning that gets from point A to point B without attempting to walk through solid objects, replannrng aroubd obstacles.

We see this a lot with hobby robots, nice mechanics with no software

  Are you sure? yes | no

ꝺeshipu wrote 06/19/2018 at 18:37 point

Some of them have pretty interesting behaviors. Also, lack of application is not an exclusive feature of ROS-less robots.

For "antonymous" navigation you need sensors that cost two orders of magnitude more than the whole budgets of those projects. But they usually do obstacle avoidance, so they don't walk into things.

No software is often better than crappy and bloated software. At least you get to learn how it actually is done.

  Are you sure? yes | no

Paul Gould wrote 06/19/2018 at 12:36 point

Albertson.chris - can you tell me about the joint controller have you have made? 

The PSOC4 controller can be configured to support the following communication protocols PWM,  I2C, SPI, UART, RS485, USB, CAN, Step/Dir and LIN. I like CAN the best, as the packet handling is supported in hardware and it has a higher immunity to noisy environments. The CPU is running at 90% idle, so i'm sure adding some sort of Trajectory planning should be possible. 

The current big quad I'm designing requires interaction between the joints as the two actuators are joined as one parallel linked series elastic actuators. Two controllers, two gearboxes and one series elastic actuator. This will most likely require a centralized controller.

The CPU in the STSPIN32F0 is not a "high end" controller. 4KB of RAM is not much for a Robot controller.

  Are you sure? yes | no

albertson.chris wrote 06/19/2018 at 17:59 point

I think a robot controller for a robot that has as many degrees of freedom is a quadruped is going to be hierarchical.    Every group of 6 MOSFETS controls one motor has one CPU.   The cPU only has to run a position and velocity feedback loop and monitor temperature.  I would bolt the mosfets to the 25x25 mm tube as a heat sink.  These controllers could live inside the structurel tubes and all connect to a bus and DC power.     4K is easy enough to run a couple loops and control one motor if not get a bigger uP.   

The next layer of control like does coordinated movement.   It receives as input a series of vectors.  The vector has a target position and velocity for every joint and also a time tag for when those positions are to be realized.   It then sends commends to all the motor controllers to update their set points such that every point gets to it's target at the same time.

The next level above os motion planning.  It's output is the vector of joint targets

Above that is the SLAM and navigation.  The robot needs to know where it is and how to get to where it needs to be and hw to rout arub fixed and moving obstacles.  This means a LIDAR, Vision, IMU, Kalman filters and so on.   This is where ROS is best used.  One person could never write a modern SLAM and sensor integration suite in one lifetime.

The level above is what decides the where it needs to be part which is likely based on a high-level command give by the owner of the robot who just said "go downstairs and fetch me a beer"

Using the "fetch me a beer" scenario is a great place holder.  It the design can do that is is general enough.  I don't need a beer fetcher but I do want a personal assistant for a blind person.  A machine that cn read signs and not bump into walls and communicate by voice.

  Are you sure? yes | no

albertson.chris wrote 06/18/2018 at 16:09 point

I've been looking for motors.  Hoby King has the one in the you tube video.  But then checked industrial brushless motors and found a line of them a   One of them has a Kv of 111.  That means 3X more torque per  amp.  Same price but physically larger in the axial direction by a lot, but on the other hand I doubt it needs cooling.  Likely more weight.  

Maybe suitable for an indutrial robot arm that with base fixed to platform

  Are you sure? yes | no

albertson.chris wrote 06/18/2018 at 05:18 point

I just read the comment about casting.  It is not hard. You can print a mold, pour in the resin then, here is the key:  the mold comes apart in two or three sections.  The mold parts have flanges that bolt together.  and have registration indents for precision alignment.  Coat the inside with some kind of mold release and car past wax.    

I will have access to CNC mill just as soon as I finish my CNC conversion project.  Milling from mild steel is not as hard as it seems

Comercial cscloidic drive this size use grease only the larger ones need a oil bath.  I'd stay with white lithium grease

Now to find suitable motor

  Are you sure? yes | no

albertson.chris wrote 06/18/2018 at 03:40 point

I have been looking for an actuator for the exact same reasons you were.  My goal was an affordable quadruped that could jump off the ground.  Yours is great and (I say this in a positive way) there is room for modification which means it could be even better.   

I think the electronics can be very much simplified. and I don't know how your position/velocity feedback works yet or anything about the magnetic encoders.  

About cooling, yes, the motors likely can run hotter than you are letting them get and remember that heat flows in proportion th the difference in temperature.   So hot is not bad.  My first try would be putting a fan in the shaft then making the mount out of aluminum and a thermistor some place to measure temperature.   I'm going to have to build one of these and study it.    Thanks for all the hard work

I need to buy a brushless motor -- Sorry I've not read everything yet, do you a source  for the motors? Or a model number i can google.   

  Are you sure? yes | no

Paul Gould wrote 06/18/2018 at 10:40 point

Any ideas and improvements are always welcome. For the electronics you can get a uC with inbuilt FET driver but then I loose the ability of the PSOC FPGA section (which is very useful). The advantage of the magnetic encoder is you can get full torque at 0RPM at angle angle using FOC. The motors are from Hobbyking Multistar Elite 5008/5010 or from Arris Hobby 5008/5010/5020 or from Foxtech 5010 or T-motor 5008/5012

  Are you sure? yes | no

JoshuaBRussell wrote 06/17/2018 at 20:23 point

Really cool project! I'm interested in motor control myself. What resources did you use when helping design the motor control electronics? Specifically related to the PWM, DRV chip, etc.

  Are you sure? yes | no

Paul Gould wrote 06/18/2018 at 13:53 point

ODrive and VESC are a good starting point. For the FET Drivers, I like the smarter chips of TI's DRV8xxx family. They offer various control and fault detection options. Gate control can be tricky and these chips handle them easily. The main reason for my custom controller was to have full motor torque at 0RPM. 

  Are you sure? yes | no

Deinactivation wrote 06/17/2018 at 18:43 point

This is extremely interesting, but how does it compare to the commercial actuators on price? You said those ones are ~$500, but what I can find looks like this one has to be pushing at least $200. A full BOM with sources and costs would be awesome.

  Are you sure? yes | no

Paul Gould wrote 06/18/2018 at 11:04 point

I was comparing the actuator to the DYNAMIXEL PRO line of robot servos. They start about $500. I will update the BOM over the next few weeks.

  Are you sure? yes | no

Dan Royer wrote 06/17/2018 at 14:22 point

Nice work! I’m very interested in your project. I’ve tried to make cycloids in the past. My sixi robot arm needs a min holding torque of 20Nm at the base. What kind of play are you getting? (How’s the repeatable accuracy?)

  Are you sure? yes | no

Paul Gould wrote 06/18/2018 at 11:13 point

The backlash is quite small but that is all relative. It is good for a quad, not sure about a robot arm. It depends on the tolerances of the 3D printed Cycloidal gear. The joint position sensor is 14bits but getting the magnetic sensor and diametric magnet concentric will effect the accuracy. I have seen people have a calibration table for the magnetic sensor, so maybe the usable accuracy is only 12bits.

  Are you sure? yes | no

Josh Starnes wrote 06/13/2018 at 13:58 point

It reminds me of transformers and other robots that have rotating discs in the joints, and you made it real, waaaah !!

  Are you sure? yes | no

Josh Starnes wrote 06/13/2018 at 13:57 point

Khudos, I really hope you were one of the individuals in the top 20 who got the $1000 prize, this concept is really cool and I love it!! It could be used in any joint in robotics.

  Are you sure? yes | no

Paul Gould wrote 06/13/2018 at 16:48 point

Thanks Josh. I was one of the 20 finalists. I think that the electronic part of the actuator is not the easiest for makers to implement into their designs right now so I might improve it a bit. The PSOC4 is not an easy chip to learn. Maybe something Arduino compatible.

  Are you sure? yes | no

Josh Starnes wrote 06/13/2018 at 16:52 point

I hope the prize encourages you to keep developing it, I normally use high torque servos on my robots but I would like something better and purpose built like this, if there is any way I can help .... even testing some setups I’m happy to be involved

  Are you sure? yes | no

Dan DWRobotics wrote 06/08/2018 at 18:02 point

Can only second my previous comments. The level of work and detail on this project is incredible. I am very excited to see the outcome!

  Are you sure? yes | no

Similar Projects

Does this project spark your interest?

Become a member to follow this project and never miss any updates