diff options
Diffstat (limited to 'case')
-rw-r--r-- | case/case.scad | 55 |
1 files changed, 38 insertions, 17 deletions
diff --git a/case/case.scad b/case/case.scad index db677a9..c47900e 100644 --- a/case/case.scad +++ b/case/case.scad @@ -30,32 +30,53 @@ module keyboard_base_plate(pcb_width, pcb_height) { } } - /* Lower left rounded corner */ - corner([0, 0, 0], [-90, 90, 90]); + /* Lower left corner */ + corner([0 - pcb_clearance_edge, + 0 - pcb_clearance_edge, 0], [-90, 90, 90]); - /* Upper left rounded corner */ - corner([0, pcb_height, 0], [0, 90, 90]); + /* Upper left orner */ + corner([0 - pcb_clearance_edge, + pcb_clearance_edge + pcb_height, 0], [0, 90, 90]); - /* Upper right rounded corner */ - corner([pcb_width, pcb_height, 0], [90, 90, 90]); + /* Upper right corner */ + corner([pcb_clearance_edge + pcb_width, + pcb_clearance_edge + pcb_height, 0], [90, 90, 90]); - /* Lower right rounded corner */ - corner([pcb_width, 0, 0], [180, 90, 90]); + /* Lower right corner */ + corner([ pcb_clearance_edge + pcb_width, + 0 - pcb_clearance_edge, 0], [180, 90, 90]); /* Top edge */ - edge(pcb_width, [0, pcb_height, 0], [0, 90, 0]); - + edge(2 * pcb_clearance_edge + pcb_width, + [0 - pcb_clearance_edge, + pcb_clearance_edge + pcb_height, 0], + [0, 90, 0]); + /* Right edge */ - edge(pcb_height, [pcb_width, 0, 0], [270, 0, 0]); - + edge(2 * pcb_clearance_edge + pcb_height, + [ pcb_clearance_edge + pcb_width, + 0 - pcb_clearance_edge, 0], + [270, 0, 0]); + /* Bottom edge */ - edge(pcb_width, [0, 0, 0], [90, 180, 90]); - + edge(2 * pcb_clearance_edge + pcb_width, + [0 - pcb_clearance_edge, + 0 - pcb_clearance_edge, + 0], + [90, 180, 90]); + /* Left edge */ - edge(pcb_height, [0, 0, 0], [270, 90, 0]); + edge(2 * pcb_clearance_edge + pcb_width, + [0 - pcb_clearance_edge, + 0 - pcb_clearance_edge, 0], + [270, 90, 0]); - linear_extrude(corner_radius*2); - square([pcb_width, pcb_height], false); + linear_extrude(corner_radius*2) + translate([0 - pcb_clearance_edge, + 0 - pcb_clearance_edge, 0]) + square([2 * pcb_clearance_edge + pcb_width, + 2 * pcb_clearance_edge + pcb_height], + false); } keyboard_base_plate(pcb_width, pcb_height); |