Table 1.
FOSS CAD tools with scripting capabilities.
Fig 1.
Arrangement example of the configurable filter stage.
Printable parts are highlighted with colors: motor bracket (green), filter holder (yellow), belt tensioner (blue and orange).
Fig 2.
(A) Drawing of the motor bracket. (B) Side view of the motor mount. The bracket and the stepper motor are partially transparent to show the internal parts.
Fig 3.
(A) Drawing showing the filter holder parts. (B) Exploded view of the filter holder assembly to a linear guide.
Fig 4.
(A) Belt tensioner side-front view. (B) Belt tensioner side-back view.
Fig 5.
Exploded view of the belt tensioner.
The two printable parts are drawn in colors: tensioner holder (blue) and idler tensioner (orange).
Fig 6.
The leadscrew tightens or loosens the idler tensioner (orange). (A) Side view of the retracted belt tensioner. (B) Side view of the extended belt tensioner.
Fig 7.
3D printing orientation of the four printable models to avoid supports.
Fig 8.
Motor bracket main parameters.
Fig 9.
Two brackets for different stepper motor sizes.
Fig 10.
Main filter holder parameters.
Fig 11.
Two filter holders for different filter sizes and linear guides.
Fig 12.
Example of an idler pulley made out of a bearing and some washers.
Fig 13.
Comparing two idler tensioners made out of different components.
The size of the idler tensioner is smaller when it contains an idler pulley using a M3 bolt (A), than when using a M4 bolt (B). For example, the space for the pulley or the tensioner width are smaller for case A than case B, as the figure shows that sep_m3 < sep_m4 and tens_w_m3 < tens_w_m4.
Fig 14.
Idler tensioners with different stroke lengths.
Fig 15.
Idler tensioners with different wall thickness.
Fig 16.
Idler tensioners with different leadscrew diameters.
Fig 17.
Tensioner holder dimensions depending on idler tensioner sizes.
Fig 18.
(A) Definition of the belt height. (B) Belt tensioners with different belt heights.
Fig 19.
Belt tensioners with different base width.
Fig 20.
Sample codes to model a rectangular cuboid.
Code (A) is modeled in OpenSCAD. Codes (B) and (C) are modeled using FreeCAD Python scripts. Code (D) is modeled using a Python script for FreeCAD CadQuery workbench.
Fig 21.
OpenSCAD sample codes to show the effect of its functional programming paradigm.
(A) Assignment in line 1 has no effect since variables keep a constant value during their entire lifetime. (B) The code shows an invalid assignment since variables cannot change their values.
Fig 22.
Sample codes to show the variable scope in OpenSCAD.
(A) Assignment in line 4 has no effect outside the if statement; therefore the sphere in line 7 will have a radius of 1. (B) This code produces the same result as in (A) even that the variable assignments are placed after the sphere function calls that use those variables.
Fig 23.
Parametric design and variable scope in OpenSCAD.
Code (A) will not work because h has not been defined outside the if statement. Codes (B) and (C) will work.
Fig 24.
Sample codes of dictionaries for defining component dimensions in Python.
(A) Dictionary DIN125_H defines the height (thickness) of some DIN 125 washers. Keys can be a float number, as in line 2. Line 6 shows how to obtain the height (0.5) of a DIN125 M2.5 washer from the dictionary. (B) Dictionaries can be multidimensional and can have strings as keys.
Fig 25.
Source codes and their generated models.
(A) OpenSCAD can export to polygonal mesh models, but not export to parametric models. (B) FreeCAD can export to both polygonal mesh models and standard parametric models.
Table 2.
Time to generate parametric models.
Table 3.
Selected parameter values to get different mesh resolutions.
Table 4.
Motor bracket: Number of vertices, edges and facets of the meshes and time to generate them.
Table 5.
Filter holder: Number of vertices, edges and facets of the meshes and time to generate them.
Table 6.
Idler tensioner: Number of vertices, edges and facets of the meshes and time to generate them.
Fig 26.
Mesh generation times in OpenSCAD an FreeCAD.
Table 7.
General project metrics.
Table 8.
The table is divided in the four topics: (1) geometric modeling kernel; (2) easy of use, (3) programming languages characteristics and (4) tool features.