chiark / gitweb /
earring-stand: toplevels
[reprap-play.git] / trackpump-mutlihead-clip.scad
index cf8a675de411e55ff86a614ae7d2c404fc1ebb3e..4d7ec02f3ca3e4da8c776231516e6b4e2f9f3aea 100644 (file)
@@ -9,11 +9,12 @@ baseplate = 4;
 pump_protr_flat = 3;
 pump_protr_slope = 0.9;
 
-hose_head_dia = 28;
+hose_inner_dia = 20;
+hose_aperture = 11;
+hose_side_width = 5;
+hose_base_offset = 30;
+
 hose_side_thick = 5;
-hose_base_offset = 10;
-hose_head_width = 22;
-hose_side_width = 4;
 
 pump_protr_protr = 3;
 pump_side_height = 20;
@@ -89,38 +90,33 @@ module PumpSide(){
   }
 }
 
-module HoseSideElevation(){
-  or = hose_head_dia/2 + hose_side_thick;
-
-  x3 = 0;
-  x4 = x3 + hose_base_offset;
-  x5 = x4 + hose_head_dia/2;
-  x6 = x4 + hose_head_dia;
-  x7 = x5 + or;
+module HoseSidePlan(){
+  ro = hose_inner_dia/2 + hose_side_width;
+  ri = (hose_inner_dia/2);
 
-  z0 = 0;
-  zm = -or;
+  apx = sqrt( ri*ri - (hose_aperture*hose_aperture)/4 );
+  apsq = hose_base_offset + apx - hose_aperture/2;
+  echo(apx,apsq);
 
   difference(){
-    intersection(){
-      translate([-100,-100]) square([x7+210, 100]);
-      hull(){
-       translate([x5, 0]) circle(r=or);
-       translate([-1, zm]) square([1,z0-zm]);
-      }
+    hull(){
+      translate([-1, -ro]) square([1, ro*2]);
+      translate([hose_base_offset, 0]) circle(r= ro);
     }
-    translate([x5,0]) circle(r=hose_head_dia/2);
+    translate([hose_base_offset, 0]) circle(r= hose_inner_dia/2);
+    translate([apsq, 0])
+      rotate(-45)
+      square([50,50]);
   }
+
+  //%translate([hose_base_offset + apx, 0]) square([50,50]);
+  //%square(center=true, [100, hose_aperture]);
 }
 
 module HoseSide(){
-  for (m=[0,1]) {
-    mirror([0,m,0])
-      translate([0, hose_head_width, 0])
-      rotate([90,0,0])
-      linear_extrude(height= hose_side_width)
-      HoseSideElevation();
-  }
+  mirror([0,0,1])
+    linear_extrude(height=hose_side_thick)
+    HoseSidePlan();
 }
 
 module Clip(){
@@ -134,8 +130,6 @@ module ClipPrint(){
 }
 
 //PumpSidePlan();
-//PumpSideElevation();
-//HoseSideElevation();
 //PumpSide();
 //HoseSide();
 //Clip();