Commit 95b1635f by Hubert

added handlecaps

1 parent 718e7105
include<vars.scad>
include<modules.scad>
module handleShape(x,y,z,extra,bool){
translate([
x/2 - handleWidth/2 - offset,
-( offset+1 ),
z-(2.06+roundborderInner+strength*3)
]) {
hull() {
translate([-extra,0,-1])cube([handleWidth+extra*2,5,1]);
translate([handleCorner,0,handleCorner-handleHeight]) rotate([-90,0,0]) union() {
cylinder(r=handleCorner+extra,h=5);
translate([handleWidth-handleCorner*2,0,0]) cylinder(r=handleCorner+extra,h=5);
}
}
if(bool==true) {
hull() {
translate([-strength*2,0,-1.5])
cube([handleWidth+strength*4,1,1]);
translate([-strength*2,0.85,-(1+handleHeight+strength)])
cube([handleWidth+strength*4,1,1]);
}
}
}
}
include<cuts.scad>
include<screws.scad>
include<pipes.scad>
include<handles.scad>
module volume(x,y,z,extra) {
......@@ -99,41 +80,47 @@ module mirroredgrates(x,y,z) {
}
}
module eurobox(x,y,z,handle) {
color("#888") translate([offset, offset, roundborderInner+strength]) {
difference () {
union() {
intersection() {
union() {
innerWall(x,y,z);
mirroredgrates(x,y,z);
grateZ(x,y,base);
grateZ(x,y,z-(roundborderInner+strength*2));
grateZ(x,y,z-(2.06+roundborderInner+strength*3));
if (handle==true) {
handleShape(x,y,z,strength,bool=false);
translate([0,y-4,0])mirror([0,1,0]){
module eurobox(x,y,z,handle,pipes,drilled,screws,locked) {
difference() {
color("#888") translate([offset, offset, roundborderInner+strength]) {
difference () {
union() {
intersection() {
union() {
innerWall(x,y,z);
mirroredgrates(x,y,z);
grateZ(x,y,base);
grateZ(x,y,z-(roundborderInner+strength*2));
grateZ(x,y,z-(2.06+roundborderInner+strength*3));
if (handle==true) {
handleShape(x,y,z,strength,bool=false);
translate([0,y-4,0])mirror([0,1,0]){
handleShape(x,y,z,strength,bool=false);
}
}
}
}
intersection() {
shapeZ(x,y,z);
translate([-offset,-offset,-(roundborderInner+strength)]) cube([x,y,z]);
intersection() {
shapeZ(x,y,z);
translate([-offset,-offset,-(roundborderInner+strength)]) cube([x,y,z]);
}
}
}
}
union() {
volume(x,y,z,0);
if (handle==true) {
handleShape(x,y,z,0,bool=true);
translate([0,y-offset*2,0])mirror([0,1,0]){
union() {
volume(x,y,z,0);
if (handle==true) {
handleShape(x,y,z,0,bool=true);
translate([0,y-offset*2,0])mirror([0,1,0]){
handleShape(x,y,z,0,bool=true);
}
}
}
}
}
if ( drilled ) drills(x,y,z);
}
if ( screws ) screws(x,y,z, locked=locked, exploded=exploded ? [-5,-5,0]:[0,0,0]);
if ( pipes ) pipes(z, exploded=exploded ? [-5,0,0]:[0,0,0]);
if ( handlecaps ) handles(x,y,z,exploded=exploded ? [0,-5,0]:[0,0,0]);
}
/* eurobox(30,40,22,true); */
......
include<eurobox.scad>
include<lid.scad>
include<cuts.scad>
include<screws.scad>
include<pipes.scad>
locked = true;
translate([0,0,2]) euroboxlid(30,40);
translate([0,0,-7]) {
difference() {
translate([0,0,-7])
eurobox(30,40,7,handle=false);
}
}
translate([0,0,6.3]) {
difference() {
eurobox(30,40,22,handle=true);
drills(30,40,22);
}
screws(30,40,22, locked=locked);
pipes(22);
}
translate([0,0,6.3+21.3/* +4 */]) {
difference() {
eurobox(30,40,22,handle=true);
drills(30,40,22);
}
screws(30,40,22, locked=locked);
pipes(22);
}
translate([0,0,6.3])
eurobox(30,40,22,
handle=true,
handlecaps=true,
pipes=true,
drilled=true,
screws=true,
locked=true,
exploded=false
);
translate([0,0,6.3+21.3/* +4 */])
eurobox(30,40,22,
handle=true,
handlecaps=true,
pipes=true,
drilled=true,
screws=true,
locked=true,
exploded=false
);
This diff could not be displayed because it is too large.
include<vars.scad>
include<modules.scad>
/* handleShape(10,10,10); */
module handle(x,y,z,exploded) {
overlap=0.05;
over=0.2;
translate([offset, offset, roundborderInner+strength]) {
difference() {
intersection() {
/* #handleShape(x,y,z,strength,bool=true); */
/* difference() { */
/* handleShape(x,y,z,0,bool=false); */
translate([x/2-8.5-overlap,-2.2-overlap-over,z-6.31-overlap])
/* difference() { */
cube([12.635+(overlap*2),1.7+(overlap*2)+(over*2),3+(overlap*2)]);
/* #translate([-1,1.2,0]) cube([2,0.7,2]); */
/* } */
handleShape(x,y,z,0,bool=true, borders=true);
translate([x/2-8.5-overlap,-2.2-overlap-over,z-6.31-overlap]) {
union() {
translate([-1,1.25+over,0]) cube([15,0.7,4]);
translate([4,-1,3-over*2]) cube([4.3,3,4]);
translate([4,0.8,-3.5]) cube([4.3,1,4]);
}
}
/* } */
/* translate([0,y-4,0])mirror([0,1,0]){ */
/* handleShape(x,y,z,strength,bool=false); */
/* } */
}
translate([x/2-8.5-overlap,-2.2-overlap-over,z-6.31-overlap])
translate([1,1,1])
cube([10.8,2,1]);
}
}
}
module handles(x,y,z,exploded) {
translate(exploded) {
handle(x,y,z,exploded);
}
mirror([0,1,0]) translate(exploded) translate([0,-y,0]) {
handle(x,y,z,exploded);
}
}
......@@ -24,3 +24,32 @@ module shapeZ(x,y,z) {
);
}
}
module handleShape(x,y,z,extra,bool){
translate([
x/2 - handleWidth/2 - offset,
-( offset+1 ),
z-(2.06+roundborderInner+strength*3)
]) {
hull() {
translate([-extra,0,-1])cube([handleWidth+extra*2,5,1]);
translate([handleCorner,0,handleCorner-handleHeight]) rotate([-90,0,0]) union() {
cylinder(r=handleCorner+extra,h=5);
translate([handleWidth-handleCorner*2,0,0]) cylinder(r=handleCorner+extra,h=5);
}
}
if(borders==true) translate([-strength*2,0+gratesize+1,-4.5])
cube([handleWidth+strength*4,2,6]);
if(bool==true) {
if(borders==true) translate([-strength*2,0,-0.5])
cube([handleWidth+strength*4,1,2]);
hull() {
translate([-strength*2,0,-1.5])
cube([handleWidth+strength*4,1,1]);
translate([-strength*2,0.85,-(1+handleHeight+strength)])
cube([handleWidth+strength*4,1,1]);
}
}
}
}
......@@ -20,8 +20,8 @@ module sidepipe(z) {
}
}
module pipes(z) {
translate([1,6,0]) {
module pipes(z,exploded) {
translate(exploded) translate([1,6,0]) {
color("#fff") sidepipe(z);
color("#fff") translate([0,0,1.1]) {
pushInAdapterStraignt();
......
......@@ -86,9 +86,9 @@ module cornerscrews(z, locked) {
}
module screws(x,y,z, locked) {
cornerscrews(22,locked);
mirror([0,1,0]) translate([0,-y,0]) cornerscrews(22, locked);
mirror([1,0,0]) translate([-x,0,0]) cornerscrews(22, locked);
mirror([1,0,0]) translate([-x,y,0]) mirror([0,1,0]) cornerscrews(22, locked);
module screws(x,y,z, locked, exploded) {
translate(exploded) cornerscrews(22,locked);
mirror([0,1,0]) translate(exploded) translate([0,-y,0]) cornerscrews(22, locked);
mirror([1,0,0]) translate(exploded) translate([-x,0,0]) cornerscrews(22, locked);
mirror([1,0,0]) translate([-x,y,0]) mirror([0,1,0]) translate(exploded) cornerscrews(22, locked);
}
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!