$fn=64; // --- Parameters --- hex_radius = 50; // Outer radius of the main hex base base_height = 16; // Height of the front base/lip total_height = 85; // Total height of the back support tablet_thickness = 13.5; // Width of the tablet slot slot_depth = 10; // Depth of the tablet slot into the base slot_angle = 18; // Lean angle of the tablet (degrees) // Hex pattern parameters hr = 7.5; // Radius of decorative hex holes dx = 16; // Horizontal spacing of hex holes dz = 14; // Vertical spacing of hex holes difference() { // Main hexagonal body cylinder(r=hex_radius, h=total_height, $fn=6); // Front cutout (removes top front to create the flat base) // Leaves the backrest starting at y = -10 translate([-hex_radius - 1, -hex_radius - 10, base_height]) cube([hex_radius * 2 + 2, hex_radius + 10, total_height + 1]); // Tablet slot (angled backwards) translate([-hex_radius - 1, -10, base_height]) rotate([slot_angle, 0, 0]) translate([0, -tablet_thickness, -slot_depth]) cube([hex_radius * 2 + 2, tablet_thickness, total_height + 10]); // Thumb groove for easy swiping/home button access translate([0, -hex_radius * 0.866, base_height]) scale([1.5, 1, 1]) cylinder(r=12, h=20, center=true); // Decorative hex holes (pointy-topped for easy 3D printing without supports) for(x = [-3 : 3]) { for(z = [0 : 5]) { z_off = (abs(x) % 2 == 1) ? dz / 2 : 0; translate([x * dx, 0, base_height + 15 + z * dz + z_off]) rotate([90, 0, 0]) rotate([0, 0, 30]) cylinder(r=hr, h=hex_radius * 3, center=true, $fn=6); } } // Top angled chamfer for a sleeker profile translate([-hex_radius - 1, -hex_radius - 1, total_height]) rotate([-8, 0, 0]) cube([hex_radius * 2 + 2, hex_radius * 2 + 2, 40]); }