summary |
shortlog |
log |
commit | commitdiff |
tree
raw |
patch |
inline | side by side (from parent 1:
244fc8f)
Override acorn_parts on the command line to generate individual parts
of the acorn. Default is to generate all parts.
e.g. `openscad -Dacorn_parts='["body"]' acorn_threads.scad' to only
generate the body.
+acorn_parts = [ "body", "cap", "gasket" ];
+
internal_thread_tolerance = 0.3;
external_thread_tolerance = 0.2;
thread_angle = 50;
internal_thread_tolerance = 0.3;
external_thread_tolerance = 0.2;
thread_angle = 50;
+
+function contains (x, lst) = len([ for (i = lst) if (x == i) i]) > 0;
+
module acorn (thread_pitch = 3.0,
thread_size = 2.5,
thread_height = 3.5,
module acorn (thread_pitch = 3.0,
thread_size = 2.5,
thread_height = 3.5,
- translate ([outer_d+10, 0, 0,]) nut ();
- cap ();
- translate ([-(outer_d+10), 0, 0,]) gasket ();
+ if (contains ("body", acorn_parts))
+ translate ([outer_d+10, 0, 0,]) nut ();
+ if (contains ("cap", acorn_parts))
+ cap ();
+ if (contains ("gasket", acorn_parts))
+ translate ([-(outer_d+10), 0, 0,]) gasket ();