chiark / gitweb /
Makefile: fix reference to utils.scad
[reprap-play.git] / bike-lipo-box.scad.m4
index 60c11659ff0ed313529d0bc2ebf92f6631f28342..ce9fdb5cd6de33739c03df2ab69c4267ef5bc5f9 100644 (file)
@@ -66,7 +66,9 @@ tubesealrad = 2.0;
 ts_xbox = 30;
 ts_ybox = 25;
 ts_cnrrad = 10;
-ts_zbox = 15;
+ts_zbox = 8;
+
+ts_cidoff = (ts_cnrrad * (1-.7) + wallthick * .8) * [1,1];
 
 m4_dnl Box_Part($1=transl_x,$2=transl_y, $3=rot_z,$4=mirror_xy)
 m4_dnl          $5=kind, $6=kindargs, $7=profile(profileargsargs))
@@ -163,9 +165,30 @@ module CeilProfile(){
     square([wallthick*2, ceilth]);
 }
 
-module TestSealBox(){
+module TestSealBox(){ ////toplevel
   TestSealDoBoxShape(WallProfile(););
   hull(){ TestSealDoBoxShape(FloorProfile();); }
+  translate(ts_cidoff)
+    Commitid_BestCount([ts_xbox,ts_ybox] - 2*ts_cidoff);
+}
+
+module TestSealLid(){ ////toplevel
+  difference(){
+    union(){
+      TestSealDoBoxShape(LidProfile(););
+      hull(){ TestSealDoBoxShape(CeilProfile();); }
+    }
+    translate([ts_xbox * .75, ts_ybox/2, 0])
+      cylinder(h=100, r=5);
+    
+    translate([-wallthick, ts_cnrrad - wallthick, ts_zbox + ceilth])
+      Commitid_BestCount([ts_xbox * .75 - 2.5,
+                         ts_ybox - (ts_cnrrad - wallthick)*2]);
+  }
+}
+
+module TestSealLidPrint(){ ////toplevel
+  rotate([180,0,0]) TestSealLid();
 }
 
 module ProfileDemos(){
@@ -176,6 +199,7 @@ module ProfileDemos(){
 }
                          
 //TestWall();
+//ProfileDemos();
 //TestSealBox();
-ProfileDemos();
+//TestSealLid();
 //FArcSegment_mask(350);