chiark / gitweb /
filamentspool: 3mm: thicker prongs on cup
[reprap-play.git] / filamentspool.scad
index 34e2f823458e60c7341dc1753cd247a55ad2442b..b84856a032affe6d4a8f3e90a87a9788bda9e1fb 100644 (file)
@@ -1,6 +1,6 @@
 // -*- C -*-
 
-fdia=1.75;
+fdia=2.85;
 
 slop=0.5;
 bigslop=slop*2;
@@ -18,17 +18,18 @@ axletowerfudgebend = 0;
 axleaxlefudgebend = 3;
 axlepadlen = 1.0;
 
-prongthick=5;
-prongwidth=5;
+function selsz(sm,lg) = fdia < 2 ? sm : lg;
+
+prongthick=selsz(5,7);
+prongwidth=selsz(5,7);
 ratchetstep=15;
 ratchettooth=3;
 ratchettoothheight=5;
 ratchettoothsmoothr=1;
 ratchettoothslope=0.75;
 overlap=0.5;
-cupbigrad=20;
-
-xstraightmul = 1.75;
+cupwidth=selsz(40,60);
+cupheight=selsz(55,75);
 
 propxshift = 0;
 
@@ -135,38 +136,33 @@ module FilamentCupHandle(){
 }
 
 module FilamentCupCup(){
-  xstraight = cupbigrad * xstraightmul;
-  linear_extrude(height=prongthick) {
-    FlatArc(0,0, cupbigrad,cupbigrad+prongwidth, 89,271, $fn=80);
-  }
   for (my=[0,1]) mirror([0,my,0]) {
-    translate([0,cupbigrad,0])
-      cube([xstraight, prongwidth, prongthick]);
+    translate([0,cupwidth/2,0])
+      cube([cupheight + prongwidth, prongwidth, prongthick]);
   }
 }
 
 module FilamentCup() { ////toplevel
   FilamentCupHandle();
 
-  dx = cupbigrad + prongwidth;
   gapy = prongwidth;
-  dy = cupbigrad + gapy + overclipcupgap;
+  dy = cupwidth/2 + gapy + overclipcupgap;
 
-  translate([dx, dy, 0])
+  translate([0, dy, 0])
     FilamentCupCup();
   translate([0, -1, 0]);
-  cube([prongwidth, dy+1, prongthick]);
+  cube([prongwidth, dy+1+cupwidth/2, prongthick]);
 
-  midrad = cupbigrad + prongwidth/2;
+  midrad = cupwidth/2 + prongwidth/2;
 
   propshift = stalklength - overclipdepth - prongthick + propxshift;
   proptaken = propshift;
-  echo(cupbigrad, dx, midrad, propshift, proptaken);
+  echo(midrad, propshift, proptaken);
 
   translate([propshift, -1, 0]) {
     // something is wrong with the y calculation
     cube([prongwidth,
-         dy - sqrt(midrad*midrad - proptaken*proptaken) - prongwidth/2,
+         gapy+2,
          prongthick]);
   }
   for (y = [overclipcupgap, overclipcupgap+overclipcupnextgap]) {
@@ -174,6 +170,11 @@ module FilamentCup() { ////toplevel
       rotate([0,0, 102 + fdia])
       FilamentTeeth(fdia=fdia, h=teethh);
   }
+  for (x = [-0.3, -1.3]) {
+    translate([cupheight + overclipcupnextgap*x, dy+cupwidth/2 + prongthick, 0])
+      rotate([0,0, 12 + fdia])
+      FilamentTeeth(fdia=fdia, h=teethh);
+  }      
 }
 
 module CupSecuringClipSolid(w,d,h1,h2){
@@ -359,8 +360,17 @@ module TowerExtender(){ ////toplevel
                   pillarw = towerpillarw);
 }
 
+module FilamentCupPair(){ ////toplevel
+  FilamentCup();
+  translate([cupheight + prongthick*3,
+            cupwidth/2*1.7,
+            0])
+    rotate([0,0,180]) FilamentCup();
+}
+
 //ArmEnd();
 //FilamentCup();
+FilamentCupPair();
 //CupSecuringClip();
 //Hub();
 //ArmExtender();