NEMA17 Stepper motor PLANETARY GEARBOX (1:5)

This planetary gearbox has been designed to reduce the backlash and hysteresis but at the same time to be easily printed and assemble. Three “planets” and the “sun” are contained inside a 60 teeth corona providing a 1:5 reduction. It has been proved that the 1:5 ratio has a very good balance between speed and accuracy when using the regular NEMA17 motors (1.8°/step).

NEMA17 planetary gearbox side view
The Gearbox, already 3d Printed

NOTE: Be sure you are using 1.8°/step ±5% stepper motors. Otherwise, the precision of the system will be compromised. Many cheap stepper motors in the market have a ±10% or even ±20% inaccuracy margins. Check the specifications before getting them.

BOM (Bill Of Materials)

  • 1x 6002RS Ball Bearing. This element will be the spine of the structure. It will keep the shaft straight.
  • 4x 623ZZ Ball Bearing. In the case of lateral deformations, they will help to cope with them.
  • 7x M3 20mm bolt
  • 4x M3 10mm bolt
  • 3D printed parts

STL FILES

After many, many sets of 3D parts printed, we got to the conclusion that it is impossible to replicate the printing accuracy when using different brands of plastic filaments or 3D printers. It will (heavily) depend on the nozzle diameter you are using or even layer height. So, as we really wanted a very precise and backlash-free gearbox, we have designed two different sets of gears. You will have to print both and select the best combination of SUN and PLANETS for your gearbox.

Place the gears as indicated below: that will eliminate the “elephant foot” deformation you can get due to an overheated heatbed. For the GEARED CASE, print it with support and completely remove it once finished.

GEARs on the heated bed
Lateral view of the gears on the heated bed
CASE placed on the heated bed
Print the GEARED CASE stl like this. Add support and thoroughly remove it when finished

NOTE: When printing the gears and outer gear case, we strongly recommend using a 0.4 mm nozzle and print with layers of 0.20 mm height or less. Infill: 40%.

With our Prusa MK3 and Ender 3D-printers, a printing speed of 30mm /s provided the best results. Remove any burr and thoughtfully clean the parts when finished. Any tiny piece of plastic that gets stuck between the gears can easily block or shatter the planetary system. Also, the use of grease is recommended.

LOOKING FOR THE PERFECT FITTING

STL files: You will find 2 sets of PLANETs and SUNs. Named as PLANET 3.15 and PLANET REGULAR, the same goes for the SUN: SUN 3.15 and SUN REGULAR.

You will have to print 3 planets and one sun for a complete set of gear. But, as we really want to reduce any gap between gear to zero, print 3x PLANET 3.15, 3x PLANET REGULAR + 1x SUN 3.15 and 1x SUN REGULAR.

Depending on the printing accuracy, you may need to combine the PLANETS of one SET with the SUN of the others.

NOTE: if you have a resin 3D printer, print the SUN 3.15 and PLANET 3.15. They have been optimized for those 3D printers.

Planetary GEARBOX points of contact
Above, Yellow dots: points of contact. Six yellow points mean that the PLANETS and SUN are perfectly aligned and always transmitting the power from the motor SHAFT to the outer GEARED corona (not shown in the image). Any inaccuracy reproducing the “designed” shape of the teeth will lead to backlash and hysteresis. That is the reason this planetary gearbox comes with 2 set of different models of STL. Look for the model that your 3D printer can reproduce better.

Once printed, insert the M3 20mm bolt inside de PLANET and force it to spin with the screwdriver. That will erode any burr inside the hole. Stop when the PLANET can rotate easily on the bolt.

Then, place them on the GEARBOX PLATFORM and screw the bolts to it, fitting the planets. Keep this in mind: this is a plastic-made gearbox. You have to be careful not over-screwing the bolts.

planetary GEARBOX top view and dimension

The teeth of the gears have been modeled so they can be printed using a 0.4mm nozzle (no sharp edges). This is the most common nozzle in the 3D-printer World.

The “shaft” of the gearbox has a diameter of 14.92mm. Our experience told us that it will perfectly fit inside a “3D printer” hole of 15mm diameter.

EXTRA: HOW TO CONTROL IT?

Basically, you need an Arduino ZERO or equivalent. We have written this Arduino code for a smooth and fast response. Once the code has been uploaded to the control board, run the Python code to open a small window. From there, you can introduce the angle you want the motor/s to point to. This code is a good example (and reference). Feel free to make it yours. Both codes were written thinking in a 2 motors system, but will move one motor without problems.

arduino logo

The Arduino CODE has to be uploaded to the DEVIA Control Board. Check in what COM port the board has been detected, you will need that info to let the Python code (below) know where to look for the board.

Basically, this firmware will let the DEVIA CONTROL BOARD to read, via serial port, the coordinates in the format indicated below. Those two sets of characters represent two angles, azimuth and altitude.

JJATXXXXXX,YYYYYY,,,

6 character for angle ONE + “comma” + 6 character for angle TWO + ,,, (3 “comma”)

Example:

Code to move both motors to 0°0’0″ , 0°0’0″ : JJAT000000,000000,,,

Code to move both motors to 10°, 20.5° : JJAT001000,002050,,,

Code to move both motors to -180°, -14.75° : JJAT-18000,-01475,,,

python logo

We have created a Python CODE (for version 3.7 and above) to easily control the motor, rotating it certain amount of degrees. Keep in mind that this simple code was intended to move two motors at the same time (the motors of the laser pointer robot -more info below-). If you run the code, this small window will appear:

planetary reduction motor control
The simple UI interface. You can set the angles you want the motors to reproduce. Just populate the fields with the angles and press Go!.
Format for the Az/Alt field; 290°42’24.3″ +34°52’57.6″

Alternatively you can use your keyboard’s arrow keys to spin the motor/s.

pngfuel.com  e1590061242428

NOTE: If you hold down the CRTL Key and press any arrow KEY, the motor will make a 0.01 degree step. Slow by precise

NOTE: You may need to modify this line in the Python code. E.g: Change the COM value for COM2 if your board has been detected in that port:

COM_PORT = 'COM8' #Serial port of DEVIA control board

NOTE 2: You will need to install the Python libraries : Keyboard / Tkinter / pyserial in order to successfully compile the code.

Reminder: This control code has been used to manually control the Laser Pointer robot. It consists of two stepper motors (attached to a planetary reduction to increase the system precision). With this robot, you have a system with the two angles mentioned above, Altitude (vertical motor) and Azimuth (horizontal). See the render at the end of this page for reference. If you connect the DEVIA control Board as indicated in the diagram below, the LEFT and RIGHT arrow keys will increase/decrease the Azimuth angle. The UP and DOWN keys will do the same with the Altitude angle. Of course, it can control just one motor.

how to connect the DEVIA board
Laser Pointer by jjRobots
This is the LASER POINTER robot. Capable of rotating a motor 0.01° with accuracy