// -*- C -*-
-// print on High Detail
-// but adjust infill to 50%, shell thickness to 2mm
+// print Stem and Wingnut on High Detail
+// but adjust shell thickness to 2mm
+
+// others on Standard
include <threads.scad>
include <camera-mount.scad>
positive_dia = inch * 3/8. - 0.375;
positive_l = inch * 1/2.;
-stem_l = 7;
+stem_l = 40;
stem_dia = 12;
+stem_th = 3;
+stem_ceil = 2;
+stem_base_th = 4;
+stem_base_dia = 25;
+stem_inner_l = 30;
+
+thread_nom = 8;
+thread_pitch = 1.25;
+thread_act = thread_nom + 0.600;
+
+wingnut_th = 5;
+wingnut_wall = 4;
+wingnut_wing_mindia = 17.0;
+wingnut_wing_xrad = 8;
+wingnut_wing_xh = 5;
+wingnut_wing_th = 3;
+
+$test= true;
+///$test= false;
+
+//$fa= 3;
+//$fs= 0.2;
+
+// calculated
-//base_th = 3;
-// base_dia =
+wingnut_cnr = wingnut_wing_th/2 -0.1;
-module Base(){
- translate([0,0,-0.1])
+module OurThread(l){
+ translate([0,0,-0.01])
+ metric_thread(diameter=thread_act, pitch=thread_pitch,
+ leadin=3, internal=true,
+ test=$test, length=l);
+}
+
+module Stem(){ ////toplevel
+ translate([0,0, stem_l -0.1])
english_thread(diameter=positive_dia/inch, threads_per_inch=16,
leadin=1, test=$test,
length= (positive_l + 0.1) / inch);
- rotate([180,0,0]) {
- cylinder(r= stem_dia/2 * 1/(0.5 * sqrt(3)),
- h = stem_l + 1,
- $fn=6);
-// translate([0,0, stem_l)
+ difference(){
+ union(){
+ cylinder(r= stem_dia/2 * 1/(0.5 * sqrt(3)),
+ h = stem_l,
+ $fn=6);
+ cylinder(r= stem_base_dia/2,
+ h = stem_base_th);
+ }
+ OurThread(stem_inner_l);
+ }
+}
+
+module Wingnut(){ ////toplevel
+ difference(){
+ union(){
+ cylinder(r= (thread_nom+wingnut_wall)/2,
+ h= wingnut_th);
+ minkowski(){
+ sphere(r= wingnut_cnr);
+ translate([0,0, wingnut_cnr*0.5])
+ linear_extrude(height= wingnut_wing_xh + wingnut_th
+ - wingnut_cnr*1.5)
+ square([wingnut_wing_mindia + wingnut_wing_xrad*2 - wingnut_cnr*2,
+ wingnut_wing_th - wingnut_cnr*2],
+ center=true);
+ }
+ }
+ translate([0,0, wingnut_th])
+ linear_extrude(height= wingnut_wing_xh+1)
+ square(wingnut_wing_mindia, center=true);
+ translate([0,0, wingnut_th])
+ rotate([180,0,0])
+ OurThread(wingnut_th+3);
+ mirror([0,0,1])
+ linear_extrude(height=5)
+ square(center=true, wingnut_wing_mindia*2);
}
}
-Base();
+//Wingnut();
+//Stem();