diff options
-rw-r--r-- | case/top.scad | 14 |
1 files changed, 9 insertions, 5 deletions
diff --git a/case/top.scad b/case/top.scad index 34dd6dc..62473bd 100644 --- a/case/top.scad +++ b/case/top.scad @@ -137,6 +137,8 @@ module top_case(key_switch_sizes, pcb_screw_holes) { cube([wall_width, case_length_bottom, wall_height - wall_width], false); /* Upper vertical supports */ + upper_support_x_interval = (keyboard_width + wall_width + 1.25) / 6; + upper_support_length = case_length_bottom - keyboard_length - keyboard_y_offset @@ -148,11 +150,13 @@ module top_case(key_switch_sizes, pcb_screw_holes) { upper_support_x_offset = keyboard_x_offset - wall_width; - translate([upper_support_x_offset, - upper_support_y_offset, - wall_height - wall_width]) - support([upper_support_length, keyboard_switch_height], - 1.25); + for (x = [0: upper_support_x_interval: keyboard_width + 2 * wall_width]) { + translate([upper_support_x_offset + x, + upper_support_y_offset, + wall_height - wall_width]) + support([upper_support_length, keyboard_switch_height], + 1.25); + } } module screw_holes() { |