$fn=64; // --- Parameters --- drill_dia = 48; // Inner diameter for drill chuck/nose wall = 5; // Wall thickness holster_len = 85; // Length of the holster tube angle = 30; // Mounting angle (degrees from vertical) back_w = 90; // Backplate width back_h = 140; // Backplate height back_t = 8; // Backplate thickness corner_r = 5; // Corner radius for backplate bit_dia = 7.5; // Hole size for 1/4" hex bits (includes clearance) bit_depth = 12; // Depth of bit holes num_bits = 5; // Number of bit storage holes outer_dia = drill_dia + wall*2; // --- Helper Module --- module rounded_rect(w, h, t, r) { hull() { for(x = [-w/2+r, w/2-r]) { for(y = [-h/2+r, h/2-r]) { translate([x, y, 0]) cylinder(r=r, h=t); } } } } // --- Main Model --- module holster() { difference() { union() { // Main backplate rounded_rect(back_w, back_h, back_t, corner_r); // Bit storage block (integrated at the bottom) translate([0, -back_h/2 + 15, 0]) rounded_rect(back_w, 30, back_t + 16, corner_r); // Holster tube translate([0, -15, back_t]) rotate([-angle, 0, 0]) cylinder(h=holster_len, d=outer_dia); } // Flatten the back (removes any tube protrusion below the backplate) translate([0, 0, -50]) cube([back_w*2, back_h*2, 100], center=true); // Hollow out the holster tube for the drill chuck translate([0, -15, back_t]) rotate([-angle, 0, 0]) translate([0, 0, wall]) // Leave a solid base lip cylinder(h=holster_len + 10, d=drill_dia); // Pass-through hole at the bottom for attached drill bits translate([0, -15, back_t]) rotate([-angle, 0, 0]) translate([0, 0, -10]) cylinder(h=wall + 20, d=25); // Slot for the drill handle (cutout on the side facing away from the wall) translate([0, -15, back_t]) rotate([-angle, 0, 0]) translate([0, -outer_dia/2, holster_len/2 + 20]) cube([drill_dia * 0.85, outer_dia, holster_len], center=true); // Bit storage holes for(i = [0 : num_bits-1]) { spacing = (back_w - 20) / (num_bits - 1); x_pos = -back_w/2 + 10 + i*spacing; // Main bit hole translate([x_pos, -back_h/2 + 15, back_t + 16 - bit_depth]) cylinder(h=bit_depth + 2, d=bit_dia); // Chamfer for easy insertion translate([x_pos, -back_h/2 + 15, back_t + 16 - 1]) cylinder(h=1.05, d1=bit_dia, d2=bit_dia + 2.5); } // Countersunk mounting holes hole_x = back_w/2 - 12; hole_y_top = back_h/2 - 12; hole_y_bot = -back_h/2 + 45; for(x = [-hole_x, hole_x]) { for(y = [hole_y_top, hole_y_bot]) { translate([x, y, -1]) { // Screw shaft cylinder(h=back_t + 20, d=5); // Countersink translate([0, 0, back_t - 2]) cylinder(h=3, d1=5, d2=11); // Screw head clearance translate([0, 0, back_t + 0.9]) cylinder(h=10, d=11); } } } } } // Render the model (oriented flat on its back for 3D printing) holster();