chiark / gitweb /
adafruit-powerboost: reorganise layerframes
authorIan Jackson <ijackson@chiark.greenend.org.uk>
Thu, 2 Dec 2021 20:28:09 +0000 (20:28 +0000)
committerIan Jackson <ijackson@chiark.greenend.org.uk>
Thu, 2 Dec 2021 20:28:09 +0000 (20:28 +0000)
Signed-off-by: Ian Jackson <ijackson@chiark.greenend.org.uk>
adafruit-powerboost-common.scad

index fd632449084766324aebbdaa8691aa11348e0a4a..b38753aa7d75aaab4434de12fd522d6ca3573882 100644 (file)
@@ -263,9 +263,11 @@ psu_frame_gap = 1.0;
 module PsuMountLayerFrame(bl, tr, ix) {
   gap0 = [1,1] * (psu_frame_gap + psu_initial_layer_width*(ix+0));
   gap1 = [1,1] * (psu_frame_gap + psu_initial_layer_width*(ix+1));
-  difference(){
-    rectfromto(bl-gap1, tr+gap1);
-    rectfromto(bl-gap0, tr+gap0);
+  linextr(0, psu_initial_layer_thick) {
+    difference(){
+      rectfromto(bl-gap1, tr+gap1);
+      rectfromto(bl-gap0, tr+gap0);
+    }
   }
 }
 
@@ -279,8 +281,7 @@ module PsuMountTestFullLayerFrame(ix) {
 module PsuMountTestFullMain() { ////toplevel
   ceil = psu_test_ceil;
 
-  linextr(0, psu_initial_layer_thick)
-    PsuMountTestFullLayerFrame(2);
+  PsuMountTestFullLayerFrame(2);
   
   difference(){
     translate([0,0, ceil])
@@ -298,8 +299,8 @@ module PsuMountTestFullMain() { ////toplevel
 }
 
 module PsuMountTestFullOneLayer(ix) {
+  PsuMountTestFullLayerFrame(ix);
   linextr(0, psu_initial_layer_thick) {
-    PsuMountTestFullLayerFrame(ix);
     translate([0, psu_y]) children();
   }
 }