format&heroes

cleanup the formaat and make heroes box
This commit is contained in:
2026-04-29 15:45:31 +02:00
parent 6c4deab335
commit bd6ea68d9a
9 changed files with 263 additions and 348 deletions

44
Box-Lid.scad Normal file
View File

@@ -0,0 +1,44 @@
include <BOSL2/std.scad>
// Parameter for console overwrite
b = 30.0;
t = 30.0;
module lid(b, t) {
bInner = b - 10;
tInner = t - 10;
if (bInner >= 6 && tInner >= 6) {
difference() {
cube([ b, t, 2 ], false);
bSpace = 5 + (((bInner + 2) % 8) / 2);
bAmount = (((bInner + 2) - bSpace + 5) / 8);
tSpace = 5 + (((tInner + 2) % 8) / 2);
tAmount = (((tInner + 2) - tSpace + 5) / 8);
for (i = [0:bAmount - 1], j = [0:tAmount - 1]) translate([ bSpace + i * 8, tSpace + j * 8, -1 ]) cube([ 6, 6, 3.5 ], false);
}
} else cube([ b, t, 2 ], false);
sideCut(b,t);
translate([b, 0, 0]) mirror([1, 0, 0]) sideCut(b,t);
}
module sideCut(b,t) {
difference() {
translate([0,0,2]) cube([3, 0.75 * t - 2.5,6.6], false);
translate([2.3,t/4+2,0.5]) rotate([-90,-90,0]) linear_extrude(0.5 * t) polygon(points=[
[-1,-1],
[-1,1],
[7, 1],
[5.1,-1]
]);
}
translate([0,0,2]) cube([1.4, t, 3.4], false);
}
lid(b, t);