Bed David

This commit is contained in:
wardwouts 2026-03-21 10:46:44 +01:00
parent 3786b1ee9e
commit 850333ea1b
13 changed files with 1215 additions and 5 deletions

150
Bed_David/assembly.scad Normal file
View file

@ -0,0 +1,150 @@
include <dimlines.scad>
include <dimensions.scad>
use <posts.scad>
use <horizontals.scad>
// The posts
post_foot_wall();
translate([beam_width + matress_width, 0, 0])
post_foot_room();
translate([0, bed_length - beam_depth, 0])
post_head_wall();
translate([beam_width + matress_width, bed_length-beam_depth, 0])
post_head_room();
translate([beam_width + matress_width, beam_depth + step_width, 0])
post_stairs();
translate([beam_width + matress_width, bed_length - step_width - beam_depth*2, 0])
post_head_standoff();
// The horizontals
// Foot end
translate([beam_width, 0, bed_height-beam_width])
horizontal_headfootend();
color("black"){
translate([beam_width, 0, bed_height+1*beam_width])
rotate([90,0,0])
dimensions(length=matress_width);
}
translate([beam_width, 0, 0])
horizontal_headfootend();
color("black"){
translate([-beam_width, 0, 1*beam_width])
rotate([90,-90,0])
dimensions(length=((bed_height-bed_box_height)/5)-beam_width);
}
translate([beam_width, 0, bed_height-bed_box_height])
horizontal_headfootend();
color("black"){
translate([-beam_width, 0, 1*beam_width+(bed_height-bed_box_height)])
rotate([90,-90,0])
dimensions(length=bed_box_height-2*beam_width);
}
translate([beam_width, 0, (bed_height-bed_box_height)/5])
horizontal_headfootend();
color("black"){
translate([-beam_width, 0, 1*beam_width+(bed_height-bed_box_height)/5])
rotate([90,-90,0])
dimensions(length=((bed_height-bed_box_height)/5)-beam_width);
}
translate([beam_width, 0, ((bed_height-bed_box_height)/5)*2])
horizontal_headfootend();
color("black"){
translate([-beam_width, 0, 1*beam_width+((bed_height-bed_box_height)/5)*2])
rotate([90,-90,0])
dimensions(length=((bed_height-bed_box_height)/5)-beam_width);
}
translate([beam_width, 0, ((bed_height-bed_box_height)/5)*3])
horizontal_headfootend();
color("black"){
translate([-beam_width, 0, 1*beam_width+((bed_height-bed_box_height)/5)*3])
rotate([90,-90,0])
dimensions(length=((bed_height-bed_box_height)/5)-beam_width);
}
translate([beam_width, 0, ((bed_height-bed_box_height)/5)*4])
horizontal_headfootend();
color("black"){
translate([-beam_width, 0, 1*beam_width+((bed_height-bed_box_height)/5)*4])
rotate([90,-90,0])
dimensions(length=((bed_height-bed_box_height)/5)-beam_width);
}
echo(str("#### Step distance: ", (bed_height-bed_box_height)/5));
// Head end
translate([beam_width, bed_length-beam_depth, bed_height-beam_width])
horizontal_headfootend();
translate([beam_width, bed_length-beam_depth, bed_height-bed_box_height])
horizontal_headfootend();
translate([beam_width, bed_length-beam_depth, 0])
horizontal_headfootend();
// Long horizontals
translate([0, beam_depth, bed_height-beam_depth])
horizontal_long();
translate([0, beam_depth, bed_height-bed_box_height])
horizontal_long();
translate([0, beam_depth, 0])
horizontal_long();
// Medium long horizontals
translate([matress_width+beam_width,beam_depth*2 + step_width, bed_height-beam_depth])
horizontal_medium_long_top();
translate([matress_width+beam_width,beam_depth*2 + step_width, bed_height-bed_box_height])
horizontal_medium_long();
// Steps
translate([matress_width+beam_width,beam_depth, bed_height-bed_box_height])
step();
translate([matress_width+beam_width,beam_depth, 0])
step();
translate([matress_width+beam_width,beam_depth, (bed_height-bed_box_height)/5])
step();
translate([matress_width+beam_width,beam_depth, ((bed_height-bed_box_height)/5)*2])
step();
translate([matress_width+beam_width,beam_depth, ((bed_height-bed_box_height)/5)*3])
step();
translate([matress_width+beam_width,beam_depth, ((bed_height-bed_box_height)/5)*4])
step();
// Reinforcement verticals
translate([0, ((bed_length - beam_depth)/ 2), bed_height-bed_box_height+beam_depth])
reinforce_vert();
color("black"){
translate([0, beam_width, bed_height+beam_width])
rotate([90,0,90])
dimensions(length=((bed_length-beam_width*3)/2));
translate([0, beam_width+(bed_length-beam_width)/2, bed_height+beam_width])
rotate([90,0,90])
dimensions(length=((bed_length-beam_width*3)/2));
}
translate([matress_width + beam_width, (bed_length - beam_depth)/2, bed_height-bed_box_height+beam_depth])
reinforce_vert();
color("black"){
translate([matress_width+beam_width*2, beam_width*2+step_width, bed_height+beam_width])
rotate([90,0,90])
dimensions(length=(bed_length-beam_width)/2-(beam_width*2+step_width));
translate([matress_width+beam_width*2, beam_width+(bed_length-beam_width)/2, bed_height+beam_width])
rotate([90,0,90])
dimensions(length=(bed_length-beam_width)/2-(beam_width*2+step_width));
}
// Head end extra post
translate([matress_width+beam_width, bed_length - beam_depth - step_width, 0])
step();
translate([matress_width+beam_width, bed_length - beam_depth - step_width, bed_height-bed_box_height])
step();
color("black"){
translate([matress_width+beam_width*2, bed_length-beam_depth-step_width, bed_height+beam_width])
rotate([90,0,90])
dimensions(length=step_width);
}