Well that was a slog

This commit is contained in:
XANTRONIX 2023-11-12 22:42:07 -05:00
parent 813183a047
commit 533cdf1817

View file

@ -98,126 +98,129 @@ module keyboard_base_plate(pcb_width, pcb_length) {
for (y = horizontal) { for (y = horizontal) {
side([0 - pcb_clearance_edge, y, 0], side([0 - pcb_clearance_edge, y, 0],
[pcb_width, width, height]); [bottom_width, width, height]);
} }
for (x = vertical) { for (x = vertical) {
side([x, 0 - pcb_clearance_edge, 0], side([x, 0 - pcb_clearance_edge, 0],
[width, pcb_length, height]); [width, bottom_length, height]);
} }
} }
/* Upper right corner */ /* Upper right corner */
/*round_corner([thickness + pcb_clearance_edge + pcb_width, round_corner([pcb_clearance_edge + thickness + pcb_width - corner_radius,
thickness + pcb_clearance_edge + pcb_length, pcb_clearance_edge + thickness + pcb_length - corner_radius,
-thickness/2], -thickness/2],
[90, 90, 90]);*/ [90, 90, 90]);
/* Lower right corner */ /* Lower right corner */
/*round_corner([ thickness + pcb_clearance_edge + pcb_width, round_corner([ pcb_clearance_edge + thickness + pcb_width - corner_radius,
0 - thickness - pcb_clearance_edge, -pcb_clearance_edge - thickness + corner_radius,
-thickness/2], -thickness/2],
[180, 90, 90]);*/ [180, 90, 90]);
/* Lower left corner */ /* Lower left corner */
/*round_corner([0 - thickness - pcb_clearance_edge, round_corner([-pcb_clearance_edge - thickness + corner_radius,
0 - thickness - pcb_clearance_edge, -pcb_clearance_edge - thickness + corner_radius,
-thickness/2], -thickness/2],
[-90, 90, 90]);*/ [-90, 90, 90]);
/* Upper left corner */ /* Upper left corner */
/*round_corner([0 - thickness - pcb_clearance_edge, round_corner([-pcb_clearance_edge - thickness + corner_radius,
thickness + pcb_clearance_edge + pcb_length, pcb_clearance_edge + thickness + pcb_length - corner_radius,
-thickness/2], -thickness/2],
[0, 90, 90]);*/ [0, 90, 90]);
/* Upper edge */ /* Upper edge */
/*round_edge([0 - thickness - pcb_clearance_edge, round_edge([0 - thickness - pcb_clearance_edge + corner_radius,
thickness + pcb_clearance_edge + pcb_length, thickness + pcb_clearance_edge + pcb_length - corner_radius,
-thickness/2], -thickness/2],
[0, 90, 0], [0, 90, 0],
bottom_width);*/ bottom_width + 2 * corner_radius);
/* Right edge */ /* Right edge */
/*round_edge([ thickness + pcb_clearance_edge + pcb_width, round_edge([ thickness + pcb_clearance_edge + pcb_width - corner_radius,
0 - thickness - pcb_clearance_edge, 0 - thickness - pcb_clearance_edge + corner_radius,
-thickness/2], -thickness/2],
[270, 0, 0], [270, 0, 0],
bottom_length);*/ bottom_length + 2 * corner_radius);
/* Lower edge */ /* Lower edge */
/*round_edge([0 - thickness - pcb_clearance_edge, round_edge([-pcb_clearance_edge - thickness + corner_radius,
0 - thickness - pcb_clearance_edge, -pcb_clearance_edge - thickness + corner_radius,
-thickness/2], -thickness/2],
[90, 180, 90], [90, 180, 90],
bottom_width);*/ bottom_width + 2 * corner_radius);
/* Left edge */ /* Left edge */
/*round_edge([0 - thickness - pcb_clearance_edge, round_edge([-pcb_clearance_edge - thickness + corner_radius,
0 - thickness - pcb_clearance_edge, -pcb_clearance_edge - thickness + corner_radius,
-thickness/2], -thickness/2],
[270, 90, 0], [270, 90, 0],
bottom_length);*/ bottom_length + 2 * corner_radius);
/* Upper right wall corner */ /* Upper right wall corner */
/*wall_corner([thickness + pcb_clearance_edge + pcb_width, wall_corner([thickness + pcb_clearance_edge + pcb_width - corner_radius,
thickness + pcb_clearance_edge + pcb_length, thickness + pcb_clearance_edge + pcb_length - corner_radius,
-thickness/2], -thickness/2],
[0, 0, 0], [0, 0, 0],
corner_radius, corner_radius,
wall_height);*/ wall_height);
/* Lower right wall corner */ /* Lower right wall corner */
/*wall_corner([ thickness + pcb_clearance_edge + pcb_width, wall_corner([ thickness + pcb_clearance_edge + pcb_width - corner_radius,
0 - thickness - pcb_clearance_edge, 0 - thickness - pcb_clearance_edge + corner_radius,
-thickness/2], -thickness/2],
[0, 0, 270], [0, 0, 270],
corner_radius, corner_radius,
wall_height);*/ wall_height);
/* Lower left wall corner */ /* Lower left wall corner */
/*wall_corner([0 - thickness - pcb_clearance_edge, wall_corner([0 - thickness - pcb_clearance_edge + corner_radius,
0 - thickness - pcb_clearance_edge, 0 - thickness - pcb_clearance_edge + corner_radius,
-thickness/2], -thickness/2],
[0, 0, 180], [0, 0, 180],
corner_radius, corner_radius,
wall_height);*/ wall_height);
/* Upper left wall corner */ /* Upper left wall corner */
/*wall_corner([0 - thickness - pcb_clearance_edge, wall_corner([-pcb_clearance_edge - corner_radius,
thickness + pcb_clearance_edge + pcb_length, pcb_clearance_edge + corner_radius + pcb_length,
-thickness/2], -thickness/2],
[0, 0, 90], [0, 0, 90],
corner_radius, corner_radius,
wall_height);*/ wall_height);
/* Upper wall */ /* Upper wall */
side([-pcb_clearance_edge, side([-pcb_clearance_edge - corner_radius,
pcb_clearance_edge + pcb_length, pcb_clearance_edge + pcb_length,
-thickness/2], -thickness/2],
[wall_width, thickness, wall_height]); [wall_width + 2 * corner_radius, thickness, wall_height]);
/* Right wall */ /* Right wall */
side([ pcb_clearance_edge + pcb_width, side([ pcb_clearance_edge + pcb_width,
-pcb_clearance_edge, -pcb_clearance_edge - corner_radius,
-thickness/2], -thickness/2],
[thickness, wall_length, wall_height]); [thickness, wall_length + 2 * corner_radius, wall_height]);
/* Lower wall */ /* Lower wall */
side([-pcb_clearance_edge, side([-pcb_clearance_edge - corner_radius,
-pcb_clearance_edge - thickness, -pcb_clearance_edge - thickness,
-thickness/2], -thickness/2],
[wall_width, thickness, wall_height]); [wall_width + 2 * corner_radius, thickness, wall_height]);
/* Left wall */ /* Left wall */
side([-thickness - pcb_clearance_edge, side([-pcb_clearance_edge - thickness,
-pcb_clearance_edge, -pcb_clearance_edge - corner_radius,
-thickness/2], -thickness/2],
[thickness, wall_length, wall_height]); [thickness, wall_length + 2 * corner_radius, wall_height]);
/* Bottom plate */ /* Bottom plate */
side([-pcb_clearance_edge, -pcb_clearance_edge, -thickness], side([-pcb_clearance_edge - corner_radius,
[bottom_width, bottom_length, thickness]); -pcb_clearance_edge - corner_radius,
-thickness],
[bottom_width + 2 * corner_radius,
bottom_length + 2 * corner_radius, thickness]);
/* Screw holes */ /* Screw holes */
for (screw_hole = screw_holes) { for (screw_hole = screw_holes) {