chiark / gitweb /
nook-case: wip, engage
authorIan Jackson <ijackson@chiark.greenend.org.uk>
Wed, 2 Sep 2020 20:35:42 +0000 (21:35 +0100)
committerIan Jackson <ijackson@chiark.greenend.org.uk>
Wed, 2 Sep 2020 20:35:42 +0000 (21:35 +0100)
Signed-off-by: Ian Jackson <ijackson@chiark.greenend.org.uk>
nook-case.scad

index 6217e6e73b174e3b231d5a818f7c3ae523e20157..5da7c7da5ac4c1fbb2f5f421466d7b19454353c3 100644 (file)
@@ -21,6 +21,10 @@ test_pillar = 4;
 
 $test = false;
 
+engage_l0 = 10;
+engage_l1 = 10;
+engage_l2 = 3;
+
 // calculated
 
 ledge_h = case_th;
@@ -57,6 +61,10 @@ spp30 = [ spp8[0], spp31[1] ];
 
 nom_cnr = 0.5 * [nook_w, nook_h, 0] - nook_cnr_rad * [1,1,0];
 
+etxa = nom_cnr[0] - engage_l2;
+etxb = etxa - engage_l1;
+etxc = etxb - engage_l0;
+
 module RightSideMainProfile() {
   rectfromto(spp7, spp0);
   rectfromto(spp7, spp20);
@@ -118,7 +126,7 @@ module Demo(){ ////toplevel
   //%SideTapeCutout();
 }
 
-module FaceCore(z0,z1){
+module FaceCore(z0,z1, extra_left, extra_right){
   for (mx=[0,1]) mirror([mx,0,0]) {
       for (my=[0,1]) mirror([0,my,0]) {
          translate(-nom_cnr) {
@@ -132,9 +140,12 @@ module FaceCore(z0,z1){
        children(1-mx);
     }
   for (my=[0,1]) mirror([0,my,0]) {
-      translate([0, -nook_h/2, 0])
-       linextr_x_yz(-nom_cnr[0]-0.1, nom_cnr[0]+0.1)
-       children(0);
+      translate([0, -nook_h/2, 0]) {
+       linextr_x_yz(-nom_cnr[0]-0.1,    etxc + extra_left)  children(0);
+       linextr_x_yz(etxc - extra_right, etxb + extra_right) children(1);
+       linextr_x_yz(etxb - extra_left,  etxa + extra_left)  children(0);
+       linextr_x_yz(etxa - extra_right, nom_cnr[0]+0.1)     children(1);
+      }
     }
   if (!$test) {
     linextr(z0,z1)
@@ -143,14 +154,14 @@ module FaceCore(z0,z1){
 }
 
 module Base(){ ////toplevel
-  FaceCore(0,0) {
+  FaceCore(0,0, 0.3, 0) {
     LeftSideMainProfile();
     RightSideMainProfile();
   }
 }
 
 module Top(){ ////toplevel
-  FaceCore(0,0) {
+  FaceCore(0,0, -gap[0], gap[0] + 0.3) {
     LeftTopMainProfile();
     RightTopMainProfile();
   }