3D ontwerp SCAD – Parametric Cable Chain

scad icon

Screens:

Thingiverse commentaar:

As I did not find a cable chain suiting my needs, I decided to make my own.

I was looking for a fully parametric cable chain, capable of output in CSG.
The Cable Chains I found here were mostly only .stl Surfaces.

Also I wanted to be able to build not only a single Chainlink, but a complete cable chain.
Here you can specify a vector consisting of the angles towards the previous chain links.

In future the will be an additional option to differing link types, to restrict angular movement of the chain.

The Cable Chain is generated though a nested vector.
There is a tupel consisting of the chain link type (at the moment there are only type 1: restricted to 45° movement and type 2: +-45° movement, type 3 generates a nice looking closed but mechanically not necessarily reasonable closed chain, type 4 onwards is just the same as type 3) and the angle of this link towards the previous. e.g. [1,30] is a link with a 30° angle.

These tupels are embedded in a vector. The vector:

defines the example cable chain shown as screenshot.

The vector:

defines the version I use in my 3D printer for the xy-axis.

The vector:

Give a small straigh line.

The chain links are not optimized for printing. I made this to be able to quickly add cable chains in a solid geometry format into my FreeCAD Printer Assembly. If you want to print customized chain links, you can of course just set the chain length to a single element and export the .stl:
ChainDef = [[1,0]];
I will add a link type optimized for printing. But maybe it could be of interest for you how to generate parametric chains, as OpenSCAD is a functional language you cannot use “for” loops and variables, for evaluating the input vector, it has to be made in a recursive function.

Please, don’t mind the bad formatting of the source with German words in the comments, I just quickly made this in one afternoon, as I needed it as a quick and dirty solution for my 3D printer project, but I thought, maybe it could be of interest to somebody here, so I put it here anyway in this “beta” version.

I will surely update it with a better structured and commented version sometime later.

If you have any questions, feel free to leave a comment.

ToDo:

  • Possibility to restrict allowed angle of movement
  • More 3D printer friendly linktype (e.g. based on: http://www.thingiverse.com/thing:34661)
  • Check if chainprintable version is possible
  • Add Start and End links
  • Clean up Source Code
  • Improve detection of impossible designs (“Error-Cube”)

Wat heb je nodig?

1) OpenSCAD software


Download @ Thingiverse.com

[#/3dprinter/model_scad/parametric_cable_chain” ]