diff --git a/avr/devices/n28/enclosure.scad b/avr/devices/n28/enclosure.scad index 72ed69c..aabebff 100644 --- a/avr/devices/n28/enclosure.scad +++ b/avr/devices/n28/enclosure.scad @@ -12,7 +12,11 @@ post_height = 0; hole_diameter = 3; lid_thickness = 1.9; lid_lip = 1 ; -lid_tolerance = .5; +lid_tolerance = .25; + +hook_thickness = 0.75; +hook_tolerance = .25; + module posts(x, y, z, h, r){ @@ -30,7 +34,6 @@ module posts(x, y, z, h, r){ } - difference() { // box hull() { @@ -98,8 +101,67 @@ difference() { translate([(width/2), -7, wall_thickness+2+6]) cube([5, 10, 7], center=true); + translate([0, -9, -wall_thickness]) + cylinder(r = 5.5/2, h = 6); + + + // slits for hooks + // upward facing side + translate([-((width/2)-(wall_thickness/2)), length/8, (height-lid_thickness)+1]) + cube([3, 6, hook_thickness+hook_tolerance], center=true); + translate([-((width/2)-(wall_thickness/2)), -length/8, (height-lid_thickness)+1]) + cube([3, 6, hook_thickness+hook_tolerance], center=true); + + // downward facing side + translate([(width/2)-(wall_thickness/2), 0, (height-lid_thickness)+1]) + cube([3, 6, hook_thickness+hook_tolerance], center=true); + translate([(width/2)-(wall_thickness/2), length/4, (height-lid_thickness)+1]) + cube([3, 6, hook_thickness+hook_tolerance], center=true); + translate([(width/2)-(wall_thickness/2), -length/4, (height-lid_thickness)+1]) + cube([3, 6, hook_thickness+hook_tolerance], center=true); + } +/* lid */ +translate([0, 0, 40]) { + difference() { + union() { + hull() { + posts( + x=(width/2 - corner_radius - lid_lip - lid_tolerance), + y=(length/2 - corner_radius - lid_lip - lid_tolerance), + z=0, + h=lid_thickness+1.0, + r=corner_radius); + } + + // upward facing side + translate([-((width/2)-lid_lip), length/8, 1]) + cube([2, 5, hook_thickness], center=true); + translate([-((width/2)-lid_lip), -length/8, 1]) + cube([2, 5, hook_thickness], center=true); + + // downward facing side + translate([(width/2)-lid_lip, 0, 1]) + cube([2, 5, hook_thickness], center=true); + translate([(width/2)-lid_lip, length/4, 1]) + cube([2, 5, hook_thickness], center=true); + translate([(width/2)-lid_lip, -length/4, 1]) + cube([2, 5, hook_thickness], center=true); + + } + + // drilling holes + translate([0, (length/8), -lid_thickness]) + cylinder(r = hole_diameter, h = 6); + + translate([0, -(length/8), -lid_thickness]) + cylinder(r = hole_diameter, h = 6); + + } +} + + // support posts for pcb /*difference() {