chiark / gitweb /
bike-phone-mount: square
authorIan Jackson <ijackson@chiark.greenend.org.uk>
Sat, 6 Jun 2020 00:22:47 +0000 (01:22 +0100)
committerIan Jackson <ijackson@chiark.greenend.org.uk>
Sat, 6 Jun 2020 00:22:47 +0000 (01:22 +0100)
Signed-off-by: Ian Jackson <ijackson@chiark.greenend.org.uk>
bike-phone-mount.scad

index b3feb9487b0706daf684ab66630094bdad08e4f7..9e03b2bca78770c2d75cd051445f241285d8f10d 100644 (file)
@@ -7,7 +7,6 @@ include <utils.scad>
 lip_height = 2.0 - 0.15;
 lip_depth = 2.5 /*?*/ - 0.30;
 neck_width = 26.5 - 0.55;
-neck_depth = 28.5 - 0.45;
 neck_length = 1.5 + 0.50;
 
 slope = .65;
@@ -30,7 +29,6 @@ nepm = [ nep0[0], nep3[1] ];
 total_height = nep2[1] - nep6[1];
 nep_z_offset = -nep2[1];
 nep_side_offset = [ neck_width/2, nep_z_offset ];
-nep_rear_offset = [ neck_depth, nep_z_offset ];
 
 module NeckEdgePlan() {
   polygon([ nep0,
@@ -44,30 +42,26 @@ module NeckEdgePlan() {
 }
 
 module Neck() {
-  intersection(){
-    linextr_y_xz(-100,100,convexity=10){
-      for (m=[0,1]) {
-       mirror([m,0]) {
-         translate(nep_side_offset) NeckEdgePlan();
-         rectfromto([-0.1, -total_height],
-                    nep_side_offset + nepm);
+  intersection_for (r=[0,90]) {
+    rotate([0,0,r]){
+      linextr_y_xz(-100,100,convexity=10){
+       for (m=[0,1]) {
+         mirror([m,0]) {
+           translate(nep_side_offset) NeckEdgePlan();
+           rectfromto([-0.1, -total_height],
+                      nep_side_offset + nepm);
+         }
        }
       }
     }
-    linextr_x_yz(-100,100,convexity=10){
-      translate(nep_rear_offset) NeckEdgePlan();
-      rectfromto([0, -total_height],
-                nep_rear_offset + nepm);
-    }
   }
 }
 
 module DemoCeil() {
   c = demo_ceil + extra_slope;
   linextr(0, 0.8) {
-    rectfromto
-      ([ -(neck_width/2 + c), -demo_ceil ],
-       [ +(neck_width/2 + c), neck_depth + c]);
+    square(neck_width + 2*(demo_ceil + extra_slope),
+          center=true);
   }
 }