ChainringGen is an OpenSCAD script I wrote that can generate a bike chainring with any specifications you like.
You can download ChainringGen here: https://github.com/nothinglabs/chainringgen
You can control parameters like bolt-circle-diameter (BCD), number of bolt holes, number of teeth and other stuff.
I primarily created ChainringGen because I thought designing / milling my own 110 BCD 39 tooth chainring would be the most practical and economic way to obtain one.
I also wanted to explore ways I could get from an OpenSCAD design to an object created on my CNC mill. It’s a bit trickier than just exporting an STL file.
The video above includes instructions on how to use ChainringGen in conjunction with other open-source tools to actually make a chainring out of 7075 aluminum using an inexpensive CNC mill.
Stuff I used:
Zen Toolworks – mill
OpenSCAD – design
MakerCAM – toolpathing
Universal Gcode Sender – Gcode sender!
GRBL – CNC controller
MakerCam is both quite useful – but also limited. Instead of dealing with 3d objects directly – it converts 2d paths / areas into (3d) milling operations that you define manually. It also likes niceties like being able to save your work.
I’ll say that compared to 3d printing – the open-source toolpathing options for CNC milling seem immature. I couldn’t find any “full 3d” options that were stable / usable.
If you’re getting into milling – I’d definitely suggest checking out these resources in addition:
Autodesk Fusion 360 – free for students / hobbyists (commercial) CAD software with built-in mill toolpathing
TinyG – Inexpensive, arm-based CNC controller with built-in motor drivers
ChillPeppr – Web-based CNC control software with lots of cool stuff
PyCAM – Open source 3-axis toolpath generator (interesting – but seems abandoned / buggy)
Be sure to check out my other bike-related projects: