Learn how to design and print functional gears for your next project or to replace a broken gear in a toy or tool.
Many toys, tools, robotics projects, and other hobby items use gears. Until recently, unless you had some really expensive gear, such as a CNC Lathe/Mill, it was virtually impossible to make replacement gears at home. Thanks to the advent of sub $500 3D printers, this has completely changed, and it’s simple to make your own gears to replace broken/damaged gears or even create new gears. We show you how.
THE BROAD OVERVIEW
3D Printed gears can be used for a myriad of uses, including:
- New gears (our Modular Marble Machine described below is an example).
- Gears to repair toys, tools, or hobby items. For example, R/C cars and tanks.
- Design gears to repair or improve a 3D printer (using your 3D printer to improve itself!).
Of course, with the Internet available, you don’t need to design your own gears, there are literally thousands available for free. Just search Thingiverse for “replacement gear” or use Google (hint, try “gear generator” or "parametric gears").
We’ve made a lot of gears, replacing broken gears in toys and hobby items such as R/C cars and tanks, and also made gears for 3D printers, including extruder gears and GT2 belt pulleys.
As a fun example, we designed a motorised Modular Marble Machine where nearly everything, including all gears, were made with a 3D printer.
One word of warning. When making gears for your only 3D printer, print lots of spares. Remember your 3D printer won't be usable if a gear breaks without spares. PLA, PETG, or ABS can occasionally develop stress fractures, but usually only after several months (or even years). Not all gears crack (we still have many of our original ABS Gears running), but it can be worthwhile printing spares just in case.
For 3D printed gears, we generally use PLA for room temperature applications, PETG for medium heat, and ABS (or ASA) for higher temperature environments.
Note: We’ve just started experimenting with more exotic filaments to produce even better 3D printed gears, aiming to 3D print gears with the durability and strength of commercially produced Gears. We’ll show you what happens in an upcoming Exploring 3D article.
Firstly, 3D printed gears have a couple of size limitations. The upper limit is obvious - you can't make a gear bigger than your print bed. For the majority of hobby 3D printers, this is likely between 120mm to 220mm.
The lower limit isn’t quite as obvious. This will be determined by your printer’s nozzle diameter.
In a nutshell, it’s virtually impossible to 3D print details that are much smaller than your printer’s nozzle size. If you want to print gears with very small teeth, you’ll have to replace the standard nozzle with a smaller one.
The standard 0.4mm nozzle is fine for most gears, such as extruder gears, GT2 pulleys, and the modular marble machine example, but for gears with tiny teeth, you’ll need to use 0.3mm, 0.25mm or even 0.2mm nozzle to print the fine detail involved.
Of course, as always with 3D printing, there are trade-offs. While smaller diameter nozzles can print smaller details, more force is needed to extrude the filament (that’s why cheap 3D printers with simple extruders use larger nozzles). The choice is then to increase the nozzle temperature, reducing filament viscosity. Simply put, filament flows easier when it’s hotter (just like honey), but, another trade-off, this produces more stringing which isn’t recommended for gears. The only other option is upgrading to a geared extruder (that’s why we made our first geared extruder).
Designing in OpenSCAD may take longer to code than graphical CAD software, but, if written correctly with parameters (not hard coded ‘magic’ numbers), it excels at changes.
As an example, our original Modular Marble Machine could only turn the big gear at 10RPM before the steel marbles jammed, using a 5-tooth motor gear, a 5T/18T middle gear and a 44-tooth big gear. However, after a lightbulb moment, we rounded/flared the big gear exit slot, which increased the maximum rotation from 10 to 15RPM. This increase was great, but all our carefully calculated gear ratios were now 50% wrong. Instead of a reduction ratio of around 31.68 (from 5:18 and 5:44 ratios), we now needed a lower ratio of approximately 21:1, which we achieved with 6:17 and 7:44 gears giving a 20.8:1 ratio, which was close enough for a toy. The beauty of OpenSCAD was that we only needed to change three variables, and everything rescaled to fit in place.
Old 10 RPM code:
MidGearTeethB = 18;
//mid Gear Num teeth-big side
midGearTeethS = 5;
// mid Gear Num teeth-small side
mtrGearTeeth = 5;
//motor Gear - number of teeth</div>
New 15 RPM Code:
MidGearTeethB = 17;
//mid Gear Num teeth-big side
midGearTeethS = 6;
//mid Gear Num teeth-small side
mtrGearTeeth = 6;
//motor Gear - number of teeth</div>
After these variable changes, our OpenSCAD software automatically moved the Micromotor mount and mid gear axle, and even produced new gears, all from changing three variables. That’s why we like OpenSCAD (Of course, that’s probably our programmers bias).
Another useful feature of OpenSCAD is displaying all (or only some) parts in position, with other options to print just one part.
Gears are designed to transfer power. Using our Marble Machine as an example, the motor turns the ‘drive gear’. This gear turns an intermediate gear at a slower rate, which then rotates the output gear at the desired (very slow here) speed. In this example, the drive gear is pressed onto the motor’s “D” shaft, but this isn’t always suitable with higher power motors. The simplest method just uses a grub screw, but this marks the shaft and makes the gear difficult to remove. We originally used this method but changed to a design that wouldn’t mark the shaft by using two screws to clamp onto the shaft. This clamp design is also great where you are tight on space.
We’ve provided several examples of spur and helical gears you can print, as well as the Marble Machine gears. There are many, many thousands available online as well. www.geargenerator.com is also a good resource.
Producing properly engineered gears involves a lot of mathematics, but it’s nearly all handled by our CAD software. You only need to select a few values to produce a gear:
NUMBER OF TEETH: Used to calculate the gearing ratio to the other gear(s).
TEETH SIZE: There are several ways to do this, depending on your CAD software, but basically, once the number of teeth is set, larger teeth make a bigger gear. The most commonly used variables are:
- PITCH OR CIRCULAR PITCH: The distance between two adjacent gear teeth.
- PITCH DIAMETER: The distance across the gear.
PRESSURE ANGLE: This has a complex definition. Importantly for 3D printed gears, it influences gear strength with values varying between 20 degrees and 30 degrees, with larger values making stronger gears. (We used 28 degrees in our Modular Marble Machine project).
While there are many other gear parameters, for most 3D printing, the two that sometimes need tweaking are backlash and clearance. Simply put, Backlash changes a gear tooth’s width and Clearance changes tooth height. In most cases your CAD software’s default values are OK.
To make replacement gears for repairs, you’ll need some good quality Digital Calipers. Mitutoyo brand calipers would be considered one of the best. but electronics retailers including Jaycar, Altronics, and Core Electronics sell reasonable quality ones at a much more affordable price.
Make sure you measure everything as accurately as possible. The most important measurements are diameter and pitch, but don’t forget gear width, axle size, boss diameter, and boss width, which are nearly as important.
Note: For axle size, we’ve found it’s usually easier to measure the actual axle on the device being repaired, not on the gear.
For new gears, you won’t need to measure, but you do need to decide on the tooth size and number of teeth. Quite often the space available limits how big a gear can be, and you may be forced to select smaller than optimal teeth just to fit the new gears in the available space. This wasn’t a problem with the Marble Machine, but we have had ‘fun’ trying to squeeze four gears into an extruder body.
Note: The original 2016 Marble Machine had only two gears and used a 150:1 geared Micromotor. Switching to the Jaycar 30:1 Micromotor meant an extra reduction gear was needed, and that’s why the motor mount sticks out the side a bit (it was a later add-on).
Gear Teeth Nomenclature:
There are many types of gears that we can 3D print. The most common types are:
A ‘standard’ or straight cut gear with straight teeth around the edge (Used in our Modular Marble Machine).
Double helix gears are commonly used in geared extruders to minimise backlash.
While these are the most commonly 3D printed gears, you can also print many other types of gears, such as bevel gears, worm gears, and planetary gear.
Note: There is an excellent display of gears meshing at geargenerator.com. It’s well worth a look.
Modular Marble Machine
|Parts Required:||Jaycar||Altronics||Core Electronics|
|1 x 6V Micro Motor 30:1 Gearbox||YM2800||-||POLOLU-2364|
|2 x 1xAA Battery Holders||PH9203||S5026||CE06934|
|1 x SPDT Centre-Off Miniature Toggle Switch - Solder Tag||ST0336||S1330||-|
|1 x Short Length of 4mm Teflon Tube 2mm ID ^||TL4277||-||-|
|1 x Short Length of 2mm Diameter Carbon Fibre Rod %||-||-||-|
|14 x 3mm x 20mm Countersunk Screws (4G self-tapping screws also suitable) *||HP0410||-||-|
|42 (or more) x 10mm Spherical Steel Ball Bearings +||-||-||-|
* Quantity shown, may be sold in packs.
^ This is the same 4mm Teflon Tube used in nearly all Bowden Extruders and Filament guides in 3D printers, so you probably have some, if not nearly all 3D printer suppliers sell it.
% We used 2mm rod some from www.worldhobbies.com.au/carbonfibre-rod-2mm. Most hobby stores stock Carbon Fibre rod.
+ Available from fishing tackle stores, engineering stores and other online sources, including www.fishingtackleshop.com.au or www.mundays.com.au. 3/8" steel balls should also work (9.525mm is very close to the recommended 10mm). Of course, also keep in mind that stainless steel balls won't rust.
As well as useful gears, your 3D printer can also be used to make fun ‘things’ that kids, of all ages, love. This is why we have designed a Marble Machine for you to build. This will give you a practical demonstration and we hope you all have lots of fun making and playing with it (we certainly did).
WARNING: Please, make sure very young children are always supervised and can’t pick up the steel marbles.
Our Marble Machine is designed to be printable on most 3D printers, as long as the bed size is over 145x145mm. For a base, we mounted everything on a 200x200x16mm piece of melamine covered MDF, but any plastic or timber could be used, as long as it’s at least this size, and thick enough not to flex.
The wiring is really simple - a switch, a motor and two AA batteries. The switch is a centre-off toggle, providing Fast/Off/Slow. Fast uses both batteries in series for 3V. Slow changes the circuit to place both batteries in parallel, providing 1.5V (nominal) with twice the current available, or more likely twice the discharge time.
Note: The project will run on voltages between 1V and 4V (where it tends to jam), and only uses 40mA, so the batteries should last a long time.
3D PRINTED PARTS
STL print files and the OpenSCAD code for our Modular Marble Machine is available on our website. Our Marble Machine is a modular design that clips together, so you can add more parts, or completely redesign it. We printed the project’s parts using Jaycar’s Flashforge PLA, which produced really nice prints (PETG would also work).
Note: Some warping can happen with ABS while printing and cooling down after finishing the print. We have noticed that ABS can contract a lot.
We used a 0.4mm nozzle for all 3D printed parts. Except for the gears, we used 25% infill (to minimise plastic used - you can make it higher), with supports and no rafts. For the three gears we used 85% infill, again with supports. If your printer leaves a noticeable ‘lip’ on the bottom, you may need to use rafts or else be prepared to spend a lot of time filing.
The 3D printed funnel has visible concentric rings. These are caused by the layer height being a significant portion of the funnel’s height. We just sanded ours to make it smoother. You could reduce these rings by printing the funnel with a smaller layer height or change to a smaller nozzle, the trade-off being, of course, a smaller layer height means longer print times.
All modules are assembled using both joiner keys and 2mm alignment pins. For the alignment pins, we used 8-10mm lengths of 2mm diameter carbon fibre rod, but brass, copper or aluminium will work, as long as it’s easy to cut.
First, join all chutes together, except for the Flipper.
Remove any swarf from the key recesses. You may also need to drill out the 2mm alignment holes on each end (depends on your printer), then insert the 2mm alignment pin as shown.
While we haven’t used joiner keys since we made the original Modular Marble Machine, back in 2016, they work well, but are a tad fiddly to insert. Just use multi-grips to press them into position.
Note: The module joiner keys are printed in groups of 20. This takes under 15-minutes and only costs around 6-cents. We didn’t print them with a raft to make the chamfered insertion side mores obvious.
The keys could also be (gently) hammered in place if you don’t have multi-grips.
When all the modules are joined together, put in a test ball and see if it rolls all the way around. To clean up ours, we used a rounded diamond polishing bit on a Dremel. We recommend buying a genuine Dremel Chuck (Bunnings 62 000 953) and ditching the standard collet.
To install the motor, use the plastic clip that comes with the motor. First, check the gearbox is sitting in the alignment slot inside the clip, as shown. The M2 screws should self-tap into the holes, but if they don’t just use the M2 nuts that came with the motor.
Push a short piece of Teflon tube into the flipper and trim it flush.
Note: Orange flipper pictured is from another one of our builds.
With the flipper in position in the flipper chute, push a piece of (straightened) 1.75 PLA filament through the top holes and all the way through. Make sure it’s seated inside the end hole and that the flipper flips easily from side to side. Cut the PLA filament, leaving 8mm protruding. Also, insert a 2mm aligner pin into the flipper chute, leaving 5mm protruding. Cut it off, and push the countersink 20mm screw (M3/selftapper/woodscrew) through the big gear mount.
Next, press the flipper chute and big gear mount together and tighten the 20mm screw. It should self-tap. If not, use a longer screw with a nut or you can just add a smear of glue to make the hole smaller and retry.
Connect the funnel to the flipper chute and screw in the middle baseplate. The three gears can be put in place anytime, bIg gear first, using a length of 2mm carbon fibre rod with the cap glued on. Then the middle gear, and then the motor gear.
Screw the long middle chute to the middle baseplate (it keeps the funnel level) and then screwed both plastic baseplates to the 200x200 wooden base. All that’s left is to attach are the two battery holders to the baseplate. The easiest way is with (Hot melt) glue or double-sided tape. Then wire in the switch as shown in the wiring diagram.
Your assembled Modular Marble Machine should look similar to ours.
While it mightn’t be the answer to life, the universe and everything, our Modular Marble Machine is designed to run with up to 42 steel marbles. Any more and the steel marbles can block the funnel exit hole. With less than 20 steel marbles the big gear will sometimes have empty transfer holes.
Just load up your steel marbles, either into the chute or into the funnel (easiest) and switch it on.
Note: Make sure the big gear rotates clockwise (looking from the front). It will jam at full speed if it’s rotating anti-clockwise.
WHERE TO FROM HERE?
In an upcoming Exploring 3D, we plan to show you how to 3D print gears using nylon filaments that have only recently become available for hobby 3D printing.
Adding a timer to turn the motor off after a few minutes would be a useful improvement, as would be a fully adjustable speed control, but it is, after all, just a fun toy to amuse young (and often much older) kids.
The Modular Marble Machine is designed for a small, 145x145, build area 3D printer, but you could make it bigger, and then use small marbles instead of 10mm steel balls. We have included the OpenSCAD source code on the DIYODE website, so experienced readers can experiment with OpenSCAD.