$fn = 64; // --- Parameters --- bin_wall_thickness = 5.0; // Thickness of the bin lip/wall hook_width = 15.0; // Total width of the hook (extrusion height) material_thickness = 4.0; // Thickness of the plastic structure inside_clip_depth = 25.0; // How far the clip extends inside the bin outside_drop = 30.0; // How far down the hook goes on the outside hook_depth = 18.0; // How far the hook protrudes outward hook_lip_height = 12.0; // Height of the front retention lip corner_radius = 1.0; // Radius for smoothing all sharp edges // --- Model --- // Rotated to lay flat on the print bed for optimal strength and no supports rotate([90, 0, 0]) linear_extrude(height=hook_width, center=true) // This combination of offsets perfectly rounds all inside and outside corners // without altering the overall dimensions of the part. offset(r=-corner_radius) offset(r=2*corner_radius) offset(r=-corner_radius) difference() { union() { // Inside leg (goes inside the bin) translate([-bin_wall_thickness - material_thickness, -inside_clip_depth]) square([material_thickness, inside_clip_depth + material_thickness]); // Top bridge (rests on top of the bin wall) translate([-bin_wall_thickness - material_thickness, 0]) square([bin_wall_thickness + 2 * material_thickness, material_thickness]); // Outside leg (goes down the outside of the bin) translate([0, -outside_drop]) square([material_thickness, outside_drop + material_thickness]); // Hook base (extends outward) translate([0, -outside_drop]) square([material_thickness + hook_depth, material_thickness]); // Hook lip (points upward to retain items) translate([hook_depth, -outside_drop]) square([material_thickness, hook_lip_height]); } // Lead-in chamfer on the inside leg to make it easier to slide onto the bin translate([-bin_wall_thickness, -inside_clip_depth]) polygon([[1, -1], [-3, -1], [1, 5]]); }