Sorta scrapping things and starting over
This commit is contained in:
parent
dace90c21b
commit
6ebd07e4e1
1 changed files with 72 additions and 56 deletions
124
case/case.scad
124
case/case.scad
|
@ -9,11 +9,14 @@ module keyboard_base_plate(pcb_width, pcb_height) {
|
||||||
|
|
||||||
pcb_screw_hole_diameter = 1.5;
|
pcb_screw_hole_diameter = 1.5;
|
||||||
|
|
||||||
thickness = 2.0;
|
thickness = 1.75;
|
||||||
wall_height = 14.0;
|
wall_height = 14.0;
|
||||||
corner_radius = thickness / 2.0;
|
corner_radius = thickness / 2.0;
|
||||||
|
|
||||||
case_color = [0, 0, 0, 1.0];
|
case_color = [0.5, 0.5, 0.5, 1.0];
|
||||||
|
|
||||||
|
bottom_width = 2 * (pcb_clearance_edge + thickness) + pcb_width;
|
||||||
|
bottom_height = 2 * (pcb_clearance_edge + thickness) + pcb_height;
|
||||||
|
|
||||||
screw_holes = [
|
screw_holes = [
|
||||||
[ 4.8150, 85.7250],
|
[ 4.8150, 85.7250],
|
||||||
|
@ -88,104 +91,117 @@ module keyboard_base_plate(pcb_width, pcb_height) {
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Upper right corner */
|
/* Upper right corner */
|
||||||
round_corner([2 * pcb_clearance_edge + pcb_width,
|
/*round_corner([thickness + pcb_clearance_edge + pcb_width,
|
||||||
2 * pcb_clearance_edge + pcb_height, 0], [90, 90, 90]);
|
thickness + pcb_clearance_edge + pcb_height, 0],
|
||||||
|
[90, 90, 90]);*/
|
||||||
|
|
||||||
/* Lower right corner */
|
/* Lower right corner */
|
||||||
round_corner([ 2 * pcb_clearance_edge + pcb_width,
|
round_corner([ thickness + pcb_clearance_edge + pcb_width,
|
||||||
-2 * pcb_clearance_edge, 0], [180, 90, 90]);
|
0 - thickness - pcb_clearance_edge,
|
||||||
|
-thickness/2],
|
||||||
|
[180, 90, 90]);
|
||||||
|
|
||||||
/* Lower left corner */
|
/* Lower left corner */
|
||||||
round_corner([-2 * pcb_clearance_edge,
|
round_corner([0 - thickness - pcb_clearance_edge,
|
||||||
-2 * pcb_clearance_edge, 0], [-90, 90, 90]);
|
0 - thickness - pcb_clearance_edge,
|
||||||
|
-thickness/2],
|
||||||
|
[-90, 90, 90]);
|
||||||
|
|
||||||
/* Upper left corner */
|
/* Upper left corner */
|
||||||
round_corner([-2 * pcb_clearance_edge,
|
round_corner([0 - thickness - pcb_clearance_edge,
|
||||||
2 * pcb_clearance_edge + pcb_height, 0], [0, 90, 90]);
|
thickness + pcb_clearance_edge + pcb_height,
|
||||||
|
-thickness/2],
|
||||||
|
[0, 90, 90]);
|
||||||
|
|
||||||
/* Upper edge */
|
/* Upper edge */
|
||||||
round_edge([-2 * pcb_clearance_edge,
|
round_edge([0 - thickness - pcb_clearance_edge,
|
||||||
2 * pcb_clearance_edge + pcb_height, 0], [0, 90, 0],
|
thickness + pcb_clearance_edge + pcb_height,
|
||||||
2 * thickness + pcb_width);
|
-thickness/2],
|
||||||
|
[0, 90, 0],
|
||||||
|
bottom_width);
|
||||||
|
|
||||||
/* Right edge */
|
/* Right edge */
|
||||||
round_edge([ 2 * pcb_clearance_edge + pcb_width,
|
round_edge([ thickness + pcb_clearance_edge + pcb_width,
|
||||||
-2 * pcb_clearance_edge, 0], [270, 0, 0],
|
0 - thickness - pcb_clearance_edge,
|
||||||
2 * thickness + pcb_height);
|
-thickness/2],
|
||||||
|
[270, 0, 0],
|
||||||
|
bottom_height);
|
||||||
|
|
||||||
/* Lower edge */
|
/* Lower edge */
|
||||||
round_edge([-2 * pcb_clearance_edge,
|
round_edge([0 - thickness - pcb_clearance_edge,
|
||||||
-2 * pcb_clearance_edge, 0], [90, 180, 90],
|
0 - thickness - pcb_clearance_edge,
|
||||||
2 * thickness + pcb_width);
|
-thickness/2],
|
||||||
|
[90, 180, 90],
|
||||||
|
bottom_width);
|
||||||
|
|
||||||
/* Left edge */
|
/* Left edge */
|
||||||
round_edge([-2 * pcb_clearance_edge,
|
round_edge([0 - thickness - pcb_clearance_edge,
|
||||||
-2 * pcb_clearance_edge, 0], [270, 90, 0],
|
0 - thickness - pcb_clearance_edge,
|
||||||
2 * thickness + pcb_height);
|
-thickness/2],
|
||||||
|
[270, 90, 0],
|
||||||
|
bottom_height);
|
||||||
|
|
||||||
/* Upper right wall corner */
|
/* Upper right wall corner */
|
||||||
wall_corner([2 * pcb_clearance_edge + pcb_width,
|
/*wall_corner([thickness + pcb_clearance_edge + pcb_width,
|
||||||
2 * pcb_clearance_edge + pcb_height, 0],
|
thickness + pcb_clearance_edge + pcb_height, 0],
|
||||||
[0, 0, 0],
|
[0, 0, 0],
|
||||||
corner_radius,
|
corner_radius,
|
||||||
wall_height);
|
wall_height);*/
|
||||||
|
|
||||||
/* Lower right wall corner */
|
/* Lower right wall corner */
|
||||||
wall_corner([ 2 * pcb_clearance_edge + pcb_width,
|
/*wall_corner([ thickness + pcb_clearance_edge + pcb_width,
|
||||||
-2 * pcb_clearance_edge, 0],
|
0 - thickness - pcb_clearance_edge, 0],
|
||||||
[0, 0, 270],
|
[0, 0, 270],
|
||||||
corner_radius,
|
corner_radius,
|
||||||
wall_height);
|
wall_height);*/
|
||||||
|
|
||||||
/* Lower left wall corner */
|
/* Lower left wall corner */
|
||||||
wall_corner([-2 * pcb_clearance_edge,
|
/*wall_corner([0 - thickness - pcb_clearance_edge,
|
||||||
-2 * pcb_clearance_edge, 0],
|
0 - thickness - pcb_clearance_edge, 0],
|
||||||
[0, 0, 180],
|
[0, 0, 180],
|
||||||
corner_radius,
|
corner_radius,
|
||||||
wall_height);
|
wall_height);*/
|
||||||
|
|
||||||
/* Upper left wall corner */
|
/* Upper left wall corner */
|
||||||
wall_corner([-2 * pcb_clearance_edge,
|
/*wall_corner([0 - thickness - pcb_clearance_edge,
|
||||||
2 * pcb_clearance_edge + pcb_height, 0],
|
thickness + pcb_clearance_edge + pcb_height, 0],
|
||||||
[0, 0, 90],
|
[0, 0, 90],
|
||||||
corner_radius,
|
corner_radius,
|
||||||
wall_height);
|
wall_height);*/
|
||||||
|
|
||||||
/* Upper wall */
|
/* Upper wall */
|
||||||
side([-2 * pcb_clearance_edge,
|
/*side([0 - thickness - pcb_clearance_edge,
|
||||||
pcb_clearance_edge + pcb_height, 0],
|
pcb_clearance_edge + pcb_height, 0],
|
||||||
[2 * thickness + pcb_width, thickness, wall_height]);
|
[2 * thickness + pcb_width, thickness, wall_height]);*/
|
||||||
|
|
||||||
/* Right wall */
|
/* Right wall */
|
||||||
side([ pcb_clearance_edge + pcb_width,
|
/*side([ pcb_clearance_edge + pcb_width,
|
||||||
-2 * pcb_clearance_edge, 0],
|
0 - thickness - pcb_clearance_edge, 0],
|
||||||
[thickness, 2 * thickness + pcb_height, wall_height]);
|
[thickness, 2 * thickness + pcb_height, wall_height]);*/
|
||||||
|
|
||||||
/* Lower wall */
|
/* Lower wall */
|
||||||
side([-2 * pcb_clearance_edge,
|
/*side([0 - thickness - pcb_clearance_edge,
|
||||||
0 - pcb_clearance_edge - thickness, 0],
|
0 - thickness - pcb_clearance_edge, 0],
|
||||||
[ 2 * thickness + pcb_width, thickness, wall_height]);
|
[2 * thickness + pcb_width, thickness, wall_height]);*/
|
||||||
|
|
||||||
/* Left wall */
|
/* Left wall */
|
||||||
side([ 0 - pcb_clearance_edge - thickness,
|
/*side([0 - thickness - pcb_clearance_edge,
|
||||||
-2 * pcb_clearance_edge, 0],
|
0 - thickness - pcb_clearance_edge, 0],
|
||||||
[thickness, 2 * thickness + pcb_height, wall_height]);
|
[thickness, 2 * thickness + pcb_height, wall_height]);*/
|
||||||
|
|
||||||
/* Bottom plate */
|
/* Bottom plate */
|
||||||
side([-2 * pcb_clearance_edge,
|
side([0 - thickness - pcb_clearance_edge,
|
||||||
-2 * pcb_clearance_edge,
|
0 - thickness - pcb_clearance_edge,
|
||||||
-thickness / 2],
|
0 - thickness],
|
||||||
[2 * thickness + pcb_width,
|
[bottom_width, bottom_height, thickness]);
|
||||||
2 * thickness + pcb_height,
|
|
||||||
thickness]);
|
|
||||||
|
|
||||||
/* Screw holes */
|
/* Screw holes */
|
||||||
for (screw_hole = screw_holes) {
|
/*for (screw_hole = screw_holes) {
|
||||||
screw_post([screw_hole[0], screw_hole[1], thickness],
|
screw_post([screw_hole[0], screw_hole[1], 0],
|
||||||
pcb_clearance_bottom * 2,
|
pcb_clearance_bottom * 2,
|
||||||
pcb_screw_hole_diameter * 2,
|
pcb_screw_hole_diameter * 2,
|
||||||
pcb_screw_hole_diameter);
|
pcb_screw_hole_diameter);
|
||||||
}
|
}*/
|
||||||
}
|
}
|
||||||
|
|
||||||
keyboard_base_plate(pcb_width, pcb_height);
|
keyboard_base_plate(pcb_width, pcb_height);
|
||||||
|
|
Loading…
Add table
Reference in a new issue