// -*- C -*- main_sz = 22.5; wall_th = 3; front_fullsz = 10; front_th = 2; gap_th = 9.5 + 0.5; back_th = 4; back_tot_l = 32.5; back_cut_l = 4; back_cut_w = 13; back_prong_w = 3; back_hole_d = 2; back_hole_dia = 1 + 0.5; module MidPlan(){ polygon([[0, 0], [0, main_sz], [wall_th, main_sz], [wall_th, wall_th], [main_sz, wall_th], [main_sz, 0]]); } module FrontPlan(){ halfway = (front_fullsz + main_sz)/2; polygon([[0, 0], [0, main_sz], [front_fullsz, main_sz], [main_sz, front_fullsz], [main_sz, 0]]); } module BackPlan(){ sqmid = main_sz * sqrt(0.5); prlen = back_tot_l - sqmid; prx = 0.5*back_cut_w + back_prong_w; difference(){ union(){ square(main_sz); rotate(-45) translate([-prx, sqmid]) square([prx*2,prlen]); } rotate(-45) translate([-back_cut_w/2, back_tot_l-back_cut_l]) square([back_cut_w, back_cut_l+1]); } } module Hook(){ rotate([90,0,0]){ difference(){ union(){ linear_extrude(height=back_th) BackPlan(); linear_extrude(height=back_th+gap_th+front_th) MidPlan(); translate([0,0, back_th+gap_th]) linear_extrude(height=front_th) FrontPlan(); } rotate([0,0,-45]) translate([0, back_tot_l - back_hole_d, back_th/2]) rotate([0,90,0]) translate([0,0,-50]) cylinder(h=100, r=back_hole_dia/2, $fn=40); } } } //MidPlan(); //FrontPlan(); //BackPlan(); Hook();