chiark / gitweb /
digispark-with-cable: wip progress
[reprap-play.git] / digispark-with-cable.scad
index a489574afb718cdaaa95c5dd2f5f1353ff766e0a..c29b2fafa8711c9bf19e9a77759b578d686f0a1c 100644 (file)
@@ -55,9 +55,12 @@ side_x_gap = 0.5;
 
 cover_ceil_th = 0.9;
 
+cover_strap_sz_x = side_wall_th * 3.5;
+
 // calculated
 
 strap_w = strain_w;
+strap_cutout_z = side_wall_th;
 
 top_top_z = usb_wall_h;
 top_base_z = -board_th;
@@ -87,6 +90,23 @@ module BothSides(){
     }
   }
 }
+module StrapCutouts(y_c, z_top, top_sz_x){
+  for (z = [ bottom_base_z, z_top ]) {
+    BothSides(){
+      translate([ -total_side_wall_x, y_c, z_top ]) {
+       cube([ top_sz_x*2,
+              strap_w,
+              strap_cutout_z*2 ],
+            center=true);
+      }
+    }
+  }
+}
+
+module CoverStrapCutouts(){
+  StrapCutouts( -cover_strap_c_d_y, cover_top_z, cover_strap_sz_x );
+}
+
 module FrontWallsPlan(slop) {
   BothSides(){
     rectfromto([ -board_w/2 - side_wall_th,    0             ],
@@ -204,6 +224,10 @@ module Bottom(){ ////toplevel
        }
       }
     }
+    minkowski(){
+      CoverRegistrations();
+      cube([ 1, fit_gap_y*2, fit_gap_z*2 ], center=true);
+    }
   }
 }
 
@@ -216,9 +240,14 @@ module CoverMainElevation(){
   }
 }
 module Cover(){ ////toplevel
-  linextr_y_xz(main_y_min, front_y_max)
-    CoverMainElevation();
-  CoverRegistrations();
+  difference(){
+    union(){
+      linextr_y_xz(main_y_min, front_y_max)
+       CoverMainElevation();
+      CoverRegistrations();
+    }
+    CoverStrapCutouts();
+  }
 }
 
 module BottomDemo(){ ////toplevel