22 ply_edge_hole_dist = ply_edge_min + ply_hole_dia/2;
24 echo(str("HOLES IN PLY ctr dist from edge = ", ply_edge_hole_dist));
26 hole_slop = (ply_hole_dia - post_dia)/2;
27 tile_hard_edge_hole_dist = ply_edge_hole_dist + hole_slop;
28 thehd = [ tile_hard_edge_hole_dist, tile_hard_edge_hole_dist ];
33 cylinder(r= post_dia/2, h= tile_th + ply_th - post_shorter);
34 translate([0,0, tile_th]) {
35 cylinder(r= screw_big_dia/2, h= screw_big_len);
36 cylinder(r= screw_dia/2, h= ply_th, $fn=20);
44 translate([p[0], p[1], 0])
49 module TileBase(botleft_post, topright_post){
50 botleft = botleft_post - thehd;
51 size = topright_post - botleft_post + thehd * 2;
53 translate([botleft[0], botleft[1], 0])
54 cube([size[0], size[1], tile_th]);
57 m4_dnl INREFFRAME(left_post, right_post, morevars) { body; }
58 m4_define(`INREFFRAME',`
59 length_vec = ($2) - ($1);
60 length = dist2d([0,0], length_vec);
61 length_uvec = length_vec / length;
62 ortho_uvec = [ -length_uvec[1], length_uvec[0] ];
63 m = [ [ length_uvec[0], ortho_uvec[0], 0, ($1)[0], ],
64 [ length_uvec[1], ortho_uvec[1], 0, ($1)[1], ],
69 translate([-thehd[1], -thehd[0], -round_edge_rad])
72 module RoundEdge(left_post, right_post) {
73 INREFFRAME(left_post, right_post,
74 `tlength = length + thehd[1] * 2;') { m4_dnl '
77 cylinder(r= round_edge_rad, h= tlength, $fn=50);
78 translate([-1, 0, -20])
79 cube([tlength+2, 20, 20]);
84 module RoundLeftCorner(this_post, right_post) {
85 INREFFRAME(this_post, right_post){
87 sphere(r= round_edge_rad, $fn=60);
94 module InterlockNegative(this_post, right_post) {
102 TileBase(holes[0], holes[1]);
103 InterlockNegative(holes[1], holes[1] + [0,1]);
107 RoundEdge(holes[0], holes[1]);
108 RoundEdge(holes[0] + [ 0, 0.1 ], holes[0]);
109 RoundLeftCorner(holes[0], holes[1]);