Shelf raiser with hexagon structure for walls
by dezzi ·
This is a shelf riser (legs) with sturdy hex ribs. Recommended usage: print 2 or 3 of these and screw them to a wooden shelf. Params configurable: shelf dimensions; frame depth; hex ribs depth and wall thickness, amount of hexagons in ribs; screw holes diameter. Perfectly printable at Bambu A1 mini in current sizing (175x175mm).
Screenshots
Prompt
design a rectangular frame with honeycomb structure inside. frame perimeter should be rounded square. 175mm width, 175mm height
OpenSCAD Code
// Rounded Rectangular Honeycomb Frame
// Dimensions: 175mm x 175mm
// --- Parameters ---
frame_width = 175;
frame_height = 175;
frame_depth = 24; // Thickness of the outer rim
honeycomb_depth = 8; // Thickness of the honeycomb lattice
frame_border = 5; // Width of the outer solid rim
corner_radius = 15; // Roundness of the frame corners
hex_radius = 28; // Size of individual honeycomb cells
hex_wall = 1.5; // Thickness of the honeycomb ribs
honeycomb_seed = 48; // Change this number to shift the pattern
// --- Screw Hole Parameters ---
show_screwholes = true; // Toggle screwholes ON/OFF
screw_radius = 2.5; // Radius of the hole (5mm diameter)
screw_dist_apart = 80; // Distance between the two holes
screw_z_percent = 0.70; // Center position at 70% of frame depth
$fn = 60;
// --- Calculations ---
// Calculate dynamic screw height
calculated_screw_z = frame_depth * screw_z_percent;
// Generate pseudo-random offsets based on seed
seed_offsets = rands(-hex_radius, hex_radius, 2, honeycomb_seed);
offset_x = seed_offsets[0];
offset_y = seed_offsets[1];
// --- Main Render ---
union() {
// 1. Outer Border Frame
difference() {
rounded_square(frame_width, frame_height, frame_depth, corner_radius);
// Interior Cutout
translate([0, 0, -1])
rounded_square(frame_width - frame_border*2, frame_height - frame_border*2, frame_depth + 2, corner_radius - frame_border);
// Optional Teardrop Screwholes
if (show_screwholes) {
hole_y_pos = frame_height/2 - frame_border/2;
// Right Hole
translate([screw_dist_apart/2, hole_y_pos, calculated_screw_z])
teardrop_hole(screw_radius, frame_border + 2);
// Left Hole
translate([-screw_dist_apart/2, hole_y_pos, calculated_screw_z])
teardrop_hole(screw_radius, frame_border + 2);
}
}
// 2. Honeycomb Fill
intersection() {
rounded_square(frame_width - frame_border, frame_height - frame_border, honeycomb_depth, corner_radius - frame_border/2);
translate([offset_x, offset_y, 0])
honeycomb_grid(frame_width + hex_radius*2, frame_height + hex_radius*2, honeycomb_depth, hex_radius, hex_wall);
}
}
// --- Modules ---
module teardrop_hole(r, length) {
// Rotated to pierce through the Y-axis wall
rotate([90, 0, 0])
translate([0, 0, -length/2])
hull() {
cylinder(h=length, r=r);
// Pointed top for support-free printing
rotate([0, 0, 45])
cube([r, r, length]);
}
}
module rounded_square(w, h, z, r) {
translate([-w/2 + r, -h/2 + r, 0])
hull() {
cylinder(h=z, r=r);
translate([w - 2*r, 0, 0]) cylinder(h=z, r=r);
translate([0, h - 2*r, 0]) cylinder(h=z, r=r);
translate([w - 2*r, h - 2*r, 0]) cylinder(h=z, r=r);
}
}
module honeycomb_grid(width, height, depth, r, wall) {
x_spacing = r * 1.5;
y_spacing = r * sqrt(3);
translate([-width/2, -height/2, 0])
for (x = [0 : x_spacing : width]) {
for (y = [0 : y_spacing : height]) {
y_offset = (floor(x / x_spacing) % 2 == 0) ? 0 : y_spacing / 2;
translate([x, y + y_offset, 0])
difference() {
cylinder(h=depth, r=r, $fn=6);
translate([0, 0, -0.5])
cylinder(h=depth + 1, r=r - wall, $fn=6);
}
}
}
}