chiark / gitweb /
scaffold-clamp: wip pin
[reprap-play.git] / scaffold-clamp-common.scad
index 9de0eb5285c31770fce71e253b441baeacd3d90a..3fee76b0e47af0d25c8b4fefc65865a01f434598 100644 (file)
@@ -32,9 +32,15 @@ hhook_inside = 40;
 hhook_th = 4;
 hhook_l = 40;
 
-// ========== calculated ==========
+// ========== defaults ==========
 
+pin_head_th = th/2;
 pin_dia = th;
+pin_hole_dia = pin_dia/2;
+pin_tail = pin_hole_dia + pin_head_th + hinge_z_gap*3;
+
+// ========== calculated ==========
+
 hole_dia = th + pin_gap;
 
 main_r = tube_dia/2 + th;
@@ -260,6 +266,29 @@ module HHookPlanDemo(){
 
 // ---------- misc ----------
 
+module PinSitu(){ ////toplevel
+  difference(){
+    union(){
+      translate([0,0, -pin_head_th])
+       cylinder(r= pin_dia/2, h = total_z + pin_head_th + pin_tail);
+      mirror([0,0,1])
+       cylinder(r= hinge_o_r - pin_gap, h = pin_head_th);
+    }
+    translate([0,0, total_z + pin_tail/2])
+      rotate([0,90,0])
+      translate([0,0, -pin_dia])
+      cylinder(r= pin_hole_dia/2, h=pin_dia*2);
+    translate([pin_dia/2 * cos(45), -50, -pin_head_th*2])
+      cube([50,100, total_z*2]);
+  }
+}
+
+module Pin(){ ////toplevel
+  rotate([0,90,0]) {
+    PinSitu();
+  }
+}
+
 module GeneralB(){ ////toplevel
   HalfClampX(true);
 }
@@ -290,6 +319,8 @@ module PlanDemo(){ ////toplevel
 module Demo(){ ////toplevel
   color("red") rotate([180,0,0]) GeneralB();
   color("blue") DummyA();
+  color("orange") translate([hinge_x, 0, min_z - hinge_z_gap])
+    rotate([0,0,180]) PinSitu();
 }
 
 //PlanDemo();