side_tophalf(); side_bothalf(); module side_tophalf() { color("red") difference() { difference() { side_panel(); translate([16,76]) rotate(90) linear_extrude(height=10) hextile_grid([0,0], [7,2]); translate([58,70]) rotate(90) linear_extrude(height=10) { hextile([1,0]); hextile_grid([0,1], [3,3]); hextile_grid([3,1], [1,3]); hextile_grid([4,2], [1,3]); hextile_grid([5,2], [1,2]); hextile_grid([6,3], [2,1]); } } splitter(); } } module side_bothalf() { color("green") intersection() { difference() { side_panel(); translate([16,16]) rotate(90) linear_extrude(height=10) hextile_grid([0,0], [8,2]); rotate(30) translate([38,-7]) linear_extrude(height=10) { hextile_grid([0,0], [9,1]); hextile_grid([1,1], [8,2]); hextile_grid([2,3], [7,1]); hextile_grid([2,4], [5,1]); hextile([8,4]); hextile([4,5]); } } splitter(); } } module hextile(coord) { r=7/2; s=0.4*2; CTC=s+2*cos(30)*r; XOFF=cos(30)*CTC; YOFF=sin(30)*CTC; translate([coord[0]*XOFF, coord[1]*CTC+(coord[0]%2)*YOFF]) circle(r, $fn=6, center=true); } module hextile_grid(coord, size) { for(i=[0:size[0]-1]) for(j=[0:size[1]-1]) hextile([coord[0]+i, coord[1]+j]); } module splitter() { CORNERX=0.044097; WIDTH=87.507148; OFFSET=5; INSET=10; translate([CORNERX-OFFSET,-OFFSET,-20]) linear_extrude(height=40) difference() { square([WIDTH+2*OFFSET,74]); translate([OFFSET+INSET,68]) square([WIDTH-2*INSET-20,20]); } } module side_panel() { // Side thickness is 5mm HEIGHT=5; // Total Boundary is width=87.507148 height=142.707741 difference() { // Layer 1 :: Side // width=87.507148 height=142.707741 linear_extrude(height=HEIGHT) polygon(points=[[ 0.044097,131.155991], [ 29.253339,142.246615], [ 32.517912,142.663643], [ 35.753545,142.063336], [ 45.739155,129.053794], [ 41.922506,126.467388], [ 35.909608,134.542692], [ 30.713543,131.542703], [ 87.463051, 33.249995], [ 30.043644, 0.044097], [ 27.543711, 0.044097], [ 27.543711, 10.044176], [ 22.043788, 10.044176], [ 22.043788, 0.044097], [ 11.043943, 0.044097], [ 11.043943, 10.044176], [ 5.544020, 10.044176], [ 5.544020, 0.044097], [ 0.044097, 0.044097], [ 0.044097,131.155991], ], paths=[0:20]); // Cutouts linear_extrude(height=HEIGHT) group() { // Layer 1 :: // width=5.588117 height=10.088101 polygon(points=[[ 11.043943,129.042769], [ 5.544020,129.042769], [ 5.544020,119.042863], [ 11.043943,119.042863], ], paths=[0:4]); // Layer 1 :: // width=5.588117 height=10.087929 polygon(points=[[ 22.043788, 26.043888], [ 27.543711, 26.043888], [ 27.543711, 16.044154], [ 22.043788, 16.044154], ], paths=[0:4]); // Layer 1 :: // width=5.588117 height=10.088273 polygon(points=[[ 22.043788, 56.043780], [ 27.543711, 56.043780], [ 27.543711, 46.043701], [ 22.043788, 46.043701], ], paths=[0:4]); // Layer 1 :: // width=5.588117 height=10.088273 polygon(points=[[ 22.043788, 80.043349], [ 27.543711, 80.043349], [ 27.543711, 70.043270], [ 22.043788, 70.043270], ], paths=[0:4]); // Layer 1 :: // width=5.588117 height=10.087929 polygon(points=[[ 22.043788,100.043161], [ 22.043788,110.042896], [ 27.543711,110.042896], [ 27.543711,100.043161], ], paths=[0:4]); // Layer 1 :: // width=5.588117 height=10.088101 polygon(points=[[ 27.543711,119.042863], [ 22.043788,119.042863], [ 22.043788,129.042769], [ 27.543711,129.042769], ], paths=[0:4]); // Layer 1 :: // width=3.088184 height=3.088011 polygon(points=[[ 26.043716, 90.043255], [ 25.604466, 91.103828], [ 24.543722, 91.543077], [ 23.483149, 91.103828], [ 23.043727, 90.043255], [ 23.483149, 88.982510], [ 24.543722, 88.543260], [ 25.604466, 88.982510], [ 26.043716, 90.043255], [ 26.043716, 90.043255], [ 26.043716, 90.043255], ], paths=[0:11]); // Layer 1 :: // width=3.088184 height=3.088184 polygon(points=[[ 26.043716, 36.043623], [ 25.604466, 37.104367], [ 24.543722, 37.543617], [ 23.483149, 37.104367], [ 23.043727, 36.043623], [ 23.483149, 34.983222], [ 24.543722, 34.543628], [ 25.604466, 34.983222], [ 26.043716, 36.043623], [ 26.043716, 36.043623], [ 26.043716, 36.043623], ], paths=[0:11]); } } }