]> www.fi.muni.cz Git - things.git/commitdiff
battery-1 upravy
authorJan "Yenya" Kasprzak <kas@fi.muni.cz>
Wed, 20 Oct 2021 07:18:12 +0000 (09:18 +0200)
committerJan "Yenya" Kasprzak <kas@fi.muni.cz>
Wed, 20 Oct 2021 07:18:12 +0000 (09:18 +0200)
battery-1.scad

index 7a201eddcebaa4ea09755826927786881be703f7..40cf11e8d2eab8941efb6e18cca72a2b91fcdd24 100644 (file)
@@ -9,7 +9,7 @@ infty = 200;
 batt_d_real = 18;
 batt_l = 65 + 1.5;
 
 batt_d_real = 18;
 batt_l = 65 + 1.5;
 
-batt_sep = 0.5;
+batt_sep = 0.65;
 
 wall = 1;
 
 
 wall = 1;
 
@@ -19,12 +19,12 @@ wire_sep = 1.5;
 wire_w = 3;
 wire_h = 1.5;
 
 wire_w = 3;
 wire_h = 1.5;
 
-body_h = batt_d_real;
+body_h = 0.8*batt_d_real;
 cyl_center_h = batt_l/3;
 
 // z-offset from the widest point of the battery to the widest
 // point of the clip
 cyl_center_h = batt_l/3;
 
 // z-offset from the widest point of the battery to the widest
 // point of the clip
-top_clip_h = 0.35*batt_d;
+top_clip_h = 0.25*batt_d;
 
 spring_sep = 0.7;
 // outer part of the spring
 
 spring_sep = 0.7;
 // outer part of the spring
@@ -96,16 +96,16 @@ module spring() {
        for (x = [-1, 1]) scale([x, 1, 1]) {
                // outmost d_out arc
                translate([d_out/2+wall/2+spring_sep/2, 0, 0])
        for (x = [-1, 1]) scale([x, 1, 1]) {
                // outmost d_out arc
                translate([d_out/2+wall/2+spring_sep/2, 0, 0])
-                       cyl_arc(d_out, body_h, 0, 180);
+                       cyl_arc(d_out, body_h, 0-eps, 180+eps);
                // inner center d_in arc
                translate([spring_sep/2+wall/2+d_in/2, 0, 0])
                // inner center d_in arc
                translate([spring_sep/2+wall/2+d_in/2, 0, 0])
-                       cyl_arc(d_in, body_h, 180, 360);
+                       cyl_arc(d_in, body_h, 180, 360+eps);
                // outer center d_in arc
                translate([spring_sep/2+wall/2+3*d_in/2, 0, 0])
                // outer center d_in arc
                translate([spring_sep/2+wall/2+3*d_in/2, 0, 0])
-                       cyl_arc(d_in, body_h, 0, 180);
+                       cyl_arc(d_in, body_h, -eps, 180+eps);
                // innermost d_out arc
                translate([2*d_in+wall/2+spring_sep/2-d_out/2, 0, 0])
                // innermost d_out arc
                translate([2*d_in+wall/2+spring_sep/2-d_out/2, 0, 0])
-                       cyl_arc(d_out, body_h, 270, 360);
+                       cyl_arc(d_out, body_h, 270-eps, 360+eps);
        }
        // center beam
        translate([-2*d_in-spring_sep/2-wall/2+d_out/2, -d_out/2-wall/2, 0])
        }
        // center beam
        translate([-2*d_in-spring_sep/2-wall/2+d_out/2, -d_out/2-wall/2, 0])