1
0
mirror of https://github.com/nophead/NopSCADlib.git synced 2025-09-06 05:12:54 +02:00

Compare commits

...

3 Commits

Author SHA1 Message Date
Chris Palmer
fa658d9eaa Moved polysink test to avoid clash in the big picture. 2020-12-17 07:28:02 +00:00
Chris
6d3f54b7a5 Merge pull request #107 from martinbudden/hanging_hole_rounding
Fixed rounding error in hangin_hole assert.
2020-12-16 21:58:40 +00:00
Martin Budden
cbd3cf29af Fixed rounding error in hangin_hole assert. 2020-12-16 19:27:03 +00:00
4 changed files with 6 additions and 6 deletions

Binary file not shown.

Before

Width:  |  Height:  |  Size: 854 KiB

After

Width:  |  Height:  |  Size: 854 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 146 KiB

After

Width:  |  Height:  |  Size: 148 KiB

View File

@@ -25,16 +25,16 @@ module polysink_stl() {
n = len(cs_screws);
size = [n * 20, 20, 10];
difference() {
translate([-size.x / n / 2, $preview ? 0 : -size.y / 2, -size.z])
translate([-size.x / n / 2, $preview ? 0 : -size.y / 2])
cube($preview ? [size.x, size.y / 2, size.z] : size);
for(i = [0 : n - 1])
let(s = cs_screws[i])
translate([i * 20, 0]) {
screw_polysink(s, 2 * size.z + 1);
translate_z(size.z)
screw_polysink(s, 2 * size.z + 1);
translate_z(-size.z)
screw_polysink(s, 2 * size.z + 1, alt = true);
screw_polysink(s, 2 * size.z + 1, alt = true);
}
}
}
@@ -52,7 +52,7 @@ module screws() {
screw(screw, length);
}
}
translate([80, 140])
translate([80, 20])
polysink_stl();
}

View File

@@ -35,7 +35,7 @@ module hanging_hole(z, ir, h = 100, h2 = 100) { //! Hole radius ```ir``` hanging
poly_cylinder(r - eps, h - layer_height);
}
}
assert(z % layer_height == 0, str(z));
assert(z - layer_height * floor(z / layer_height) < eps, str(z));
infill_angle = z % (2 * layer_height) ? -45 : 45;
below = min(z + eps, h2);
big = 1000;