Import CR_BOX.scad from thingiverse
This commit is contained in:
parent
e6e360dc3e
commit
6efc25d0fc
|
@ -0,0 +1,44 @@
|
||||||
|
/* [Filter] */
|
||||||
|
filterThiccness = 100.0; //mm
|
||||||
|
|
||||||
|
/* [Piece] */
|
||||||
|
//Length, width, height. Size of the piece including the wall thiccness
|
||||||
|
pieceDimensions = [150, 150, 25];
|
||||||
|
pieceWallThiccness = 1.2; //mm
|
||||||
|
bottomThiccness = 1.0; //mm
|
||||||
|
mirrored = false;
|
||||||
|
insideCornerStyle = 2; //[0:Cut Corner, 1:Don't cut corner, 2:Rounded corner]
|
||||||
|
|
||||||
|
/* [OpenSCAD] [Settings] */
|
||||||
|
$fn = 100;
|
||||||
|
|
||||||
|
module filter(filterDimensions = [100, 1000, 1000]){
|
||||||
|
cube(filterDimensions);
|
||||||
|
}
|
||||||
|
|
||||||
|
mirror([mirrored? 1 : 0, 0, 0]){
|
||||||
|
difference(){
|
||||||
|
translate([-pieceWallThiccness, -pieceWallThiccness, -bottomThiccness]){
|
||||||
|
cube(pieceDimensions);
|
||||||
|
}
|
||||||
|
#filter([filterThiccness, 1000, 1000]);
|
||||||
|
#translate([filterThiccness + pieceWallThiccness, filterThiccness, 0]){
|
||||||
|
rotate([0, 0, -90]){
|
||||||
|
filter([filterThiccness, 1000, 1000]);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
//Corner cutter
|
||||||
|
if(insideCornerStyle == 0){
|
||||||
|
translate([filterThiccness + pieceWallThiccness, filterThiccness + pieceWallThiccness, -bottomThiccness]){
|
||||||
|
cube(pieceDimensions);
|
||||||
|
}
|
||||||
|
}else if(insideCornerStyle == 1){
|
||||||
|
//nothing lol
|
||||||
|
}else if(insideCornerStyle == 2){
|
||||||
|
radius = pieceDimensions.x - (filterThiccness + pieceWallThiccness);
|
||||||
|
#translate([pieceDimensions.x, pieceDimensions.y, -bottomThiccness]){
|
||||||
|
cylinder(r=radius, h=pieceDimensions.z);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
Loading…
Reference in New Issue