use 2 measurements to calculate shape
authordaniel watson <ozzloy@gmail.com>
Fri, 8 Apr 2016 02:04:24 +0000 (19:04 -0700)
committerdaniel watson <ozzloy@gmail.com>
Fri, 8 Apr 2016 02:04:24 +0000 (19:04 -0700)
final shape depends only on how much higher shelf needs to be
and how wide foot of shelf leg is

foot-riser-data.scad
foot-riser.scad

index dbc60b26ce5e8e6d481452ad8b6de5ba77cdf75e..a6dcd66c40ef4598ab71bd3a4f11e08d438d9e43 100644 (file)
@@ -4,19 +4,22 @@
 /* riser foot for raising bathroom shelves */
 
 fudge = 1;
-riser_height = 200;
-foot_radius = 42 / 2 + fudge;
+// how much higher the shelf needs to be
+extra_height = 150;
+// radius of foot of shelf actually measured with calipers
+foot_radius_measured = 42 / 2;
+foot_radius = foot_radius_measured + fudge;
 wall_thickness = 3;
 
-module ring_2d(inner_radius, wall_thickness) {
-  outer_radius = inner_radius + wall_thickness;
+module ring_2d(inner_radius, outer_radius) {
   difference() {
     circle(outer_radius);
     circle(inner_radius); } }
 
-module foot_riser() {
+module foot_riser(foot_radius, extra_height) {
+     outer_radius = foot_radius + wall_thickness;
      linear_extrude(height = 200) {
-          ring_2d(foot_radius, wall_thickness); } }
+          ring_2d(foot_radius, outer_radius); } }
 
 /*
   This file is part of 3d-printables.
index d7fa523373447b4abefd2e496acfe6af92049770..122041de51acb623f33e10dfb96a5ddaf08e2e89 100644 (file)
@@ -4,7 +4,7 @@
 /* riser foot for raisingbathroom shelves */
 include <foot-riser-data.scad>
 
-foot_riser();
+foot_riser(foot_radius, extra_height);
 
 /*
   This file is part of 3d-printables.