add new print-friendly folder, and update rbuild accordingly. also refactor+fix xBar
This commit is contained in:
@ -4,43 +4,4 @@ include <./mainRail.scad>
|
|||||||
include <./yBar.scad>
|
include <./yBar.scad>
|
||||||
include <./xBar.scad>
|
include <./xBar.scad>
|
||||||
|
|
||||||
translate(v=[12,2,18])
|
// TODO
|
||||||
mainRail();
|
|
||||||
|
|
||||||
translate(v=[12,2 + 200,18])
|
|
||||||
mirror(v=[0,1,0])
|
|
||||||
*mainRail();
|
|
||||||
|
|
||||||
translate(v=[12 + 216,2,18])
|
|
||||||
mirror(v=[1,0,0])
|
|
||||||
*mainRail();
|
|
||||||
|
|
||||||
translate(v=[12 + 216,2 + 200,18])
|
|
||||||
rotate(a=[0,0,180])
|
|
||||||
*mainRail();
|
|
||||||
|
|
||||||
*xyPlane();
|
|
||||||
|
|
||||||
translate(v=[0,0,250])
|
|
||||||
mirror(v=[0,0,1])
|
|
||||||
*xyPlane();
|
|
||||||
|
|
||||||
module xyPlane() {
|
|
||||||
yBar();
|
|
||||||
|
|
||||||
translate(v = [240, 0, 0])
|
|
||||||
mirror(v = [1, 0, 0])
|
|
||||||
yBar();
|
|
||||||
|
|
||||||
translate(v = [30, 0, 0])
|
|
||||||
xBar();
|
|
||||||
|
|
||||||
translate(v = [30, 206, 0])
|
|
||||||
mirror(v = [0, 1, 0])
|
|
||||||
xBar();
|
|
||||||
}
|
|
||||||
|
|
||||||
yBar();
|
|
||||||
|
|
||||||
translate(v = [30, 0, 0])
|
|
||||||
xBar();
|
|
||||||
5
rack/print/hingeModule_P1.scad
Normal file
5
rack/print/hingeModule_P1.scad
Normal file
@ -0,0 +1,5 @@
|
|||||||
|
include <../side/hingeModule.scad>
|
||||||
|
|
||||||
|
// Oriented for 3d printing.
|
||||||
|
// Supports generally not required (? need to print to test)
|
||||||
|
hingeModule();
|
||||||
6
rack/print/hingeModule_P2.scad
Normal file
6
rack/print/hingeModule_P2.scad
Normal file
@ -0,0 +1,6 @@
|
|||||||
|
include <../side/hingeModule.scad>
|
||||||
|
|
||||||
|
// Oriented for 3d printing.
|
||||||
|
// Supports generally not required (? need to print to test)
|
||||||
|
mirror(v=[1,0,0])
|
||||||
|
hingeModule();
|
||||||
5
rack/print/magnetModule_P1.scad
Normal file
5
rack/print/magnetModule_P1.scad
Normal file
@ -0,0 +1,5 @@
|
|||||||
|
include <../side/magnetModule.scad>
|
||||||
|
|
||||||
|
// Oriented for 3d printing.
|
||||||
|
// Supports generally not required (? need to print to test)
|
||||||
|
magnetModule();
|
||||||
6
rack/print/magnetModule_P2.scad
Normal file
6
rack/print/magnetModule_P2.scad
Normal file
@ -0,0 +1,6 @@
|
|||||||
|
include <../side/magnetModule.scad>
|
||||||
|
|
||||||
|
// Oriented for 3d printing.
|
||||||
|
// Supports generally not required (? need to print to test)
|
||||||
|
mirror(v=[1,0,0])
|
||||||
|
magnetModule();
|
||||||
14
rack/print/mainRail_P.scad
Normal file
14
rack/print/mainRail_P.scad
Normal file
@ -0,0 +1,14 @@
|
|||||||
|
include <../mainRail.scad>
|
||||||
|
|
||||||
|
// Oriented for 3d printing.
|
||||||
|
// Supports not required.
|
||||||
|
multmatrix(mainRailPrintOrientation)
|
||||||
|
mainRail();
|
||||||
|
|
||||||
|
|
||||||
|
mainRailPrintOrientation = [
|
||||||
|
[cos(-90), 0, sin(-90), railTotalHeight],
|
||||||
|
[0, 1, 0, 0 ],
|
||||||
|
[-sin(-90), 0, cos(-90), 0 ],
|
||||||
|
[0, 0, 0, 1 ]
|
||||||
|
];
|
||||||
5
rack/print/sideWallLeft_P.scad
Normal file
5
rack/print/sideWallLeft_P.scad
Normal file
@ -0,0 +1,5 @@
|
|||||||
|
include <../side/sideWallLeft.scad>
|
||||||
|
|
||||||
|
// Oriented for 3d printing.
|
||||||
|
// Supports generally not required (? need to print to test)
|
||||||
|
sideWallLeft();
|
||||||
5
rack/print/sideWallRight_P.scad
Normal file
5
rack/print/sideWallRight_P.scad
Normal file
@ -0,0 +1,5 @@
|
|||||||
|
include <../side/sideWallRight.scad>
|
||||||
|
|
||||||
|
// Oriented for 3d printing.
|
||||||
|
// Supports generally not required (? need to print to test)
|
||||||
|
sideWallRight();
|
||||||
5
rack/print/xBar_P.scad
Normal file
5
rack/print/xBar_P.scad
Normal file
@ -0,0 +1,5 @@
|
|||||||
|
include <../xBar.scad>
|
||||||
|
|
||||||
|
// Oriented for 3d printing.
|
||||||
|
// Supports generally not required: depending on roundness.
|
||||||
|
xBar();
|
||||||
5
rack/print/yBar_P.scad
Normal file
5
rack/print/yBar_P.scad
Normal file
@ -0,0 +1,5 @@
|
|||||||
|
include <../yBar.scad>
|
||||||
|
|
||||||
|
// Oriented for 3d printing.
|
||||||
|
// Supports required at XY wall connections, and depending on roundness
|
||||||
|
yBar();
|
||||||
@ -2,6 +2,7 @@ include <../config.scad>
|
|||||||
include <./sideWallVariables.scad>
|
include <./sideWallVariables.scad>
|
||||||
include <../sharedVariables.scad>
|
include <../sharedVariables.scad>
|
||||||
include <../../helper/halfspace.scad>
|
include <../../helper/halfspace.scad>
|
||||||
|
include <../../helper/screws.scad>
|
||||||
|
|
||||||
|
|
||||||
module hingeModule() {
|
module hingeModule() {
|
||||||
|
|||||||
@ -4,6 +4,7 @@ include <./sideWallVariables.scad>
|
|||||||
include <../sharedVariables.scad>
|
include <../sharedVariables.scad>
|
||||||
include <../../helper/halfspace.scad>
|
include <../../helper/halfspace.scad>
|
||||||
include <../../misc/magnet.scad>
|
include <../../misc/magnet.scad>
|
||||||
|
include <../../helper/screws.scad>
|
||||||
|
|
||||||
module magnetModule() {
|
module magnetModule() {
|
||||||
|
|
||||||
|
|||||||
@ -13,11 +13,12 @@ include <./hingeModule.scad>
|
|||||||
echo("Side Wall Height", sideWallZ);
|
echo("Side Wall Height", sideWallZ);
|
||||||
echo("Side Wall Depth", sideWallY);
|
echo("Side Wall Depth", sideWallY);
|
||||||
|
|
||||||
module sideWall() {
|
*sideWallBase();
|
||||||
|
|
||||||
|
module sideWallBase() {
|
||||||
|
|
||||||
applyHingeConnector()
|
applyHingeConnector()
|
||||||
applyMagnetConnector()
|
applyMagnetConnector()
|
||||||
applyEpicVentilation()
|
|
||||||
applyHandle()
|
applyHandle()
|
||||||
sideWallBase();
|
sideWallBase();
|
||||||
|
|
||||||
@ -96,29 +97,13 @@ module sideWall() {
|
|||||||
children(0);
|
children(0);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
module sideWallMagnetMountRotated() {
|
module sideWallMagnetMountRotated() {
|
||||||
rotate(a=[0,90,0])
|
rotate(a=[0,90,0])
|
||||||
sideWallMagnetMount();
|
sideWallMagnetMount();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
module applyEpicVentilation() {
|
|
||||||
children(0);
|
|
||||||
}
|
|
||||||
|
|
||||||
module applyHandle() {
|
module applyHandle() {
|
||||||
children(0);
|
children(0);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
sideWall();
|
|
||||||
|
|
||||||
translate(v=[10,sideWallSlotToXZ,-2])
|
|
||||||
mirror(v=[1,0,0])
|
|
||||||
*magnetModule();
|
|
||||||
|
|
||||||
translate(v=[3,100,0])
|
|
||||||
mirror(v=[0,1,0])
|
|
||||||
*hingeModule();
|
|
||||||
15
rack/side/sideWallLeft.scad
Normal file
15
rack/side/sideWallLeft.scad
Normal file
@ -0,0 +1,15 @@
|
|||||||
|
include <./sideWallBase.scad>
|
||||||
|
|
||||||
|
|
||||||
|
*sideWallLeft();
|
||||||
|
|
||||||
|
module sideWallLeft() {
|
||||||
|
|
||||||
|
applyEpicVentilation()
|
||||||
|
sideWallBase();
|
||||||
|
|
||||||
|
module applyEpicVentilation() {
|
||||||
|
children(0);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
15
rack/side/sideWallRight.scad
Normal file
15
rack/side/sideWallRight.scad
Normal file
@ -0,0 +1,15 @@
|
|||||||
|
include <./sideWallBase.scad>
|
||||||
|
|
||||||
|
*sideWallRight();
|
||||||
|
|
||||||
|
module sideWallRight() {
|
||||||
|
|
||||||
|
applyEpicVentilation()
|
||||||
|
mirror(v=[1,0,0])
|
||||||
|
sideWallBase();
|
||||||
|
|
||||||
|
module applyEpicVentilation() {
|
||||||
|
children(0);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
@ -1,6 +1,7 @@
|
|||||||
|
|
||||||
include <../config.scad>
|
include <../config.scad>
|
||||||
include <../sharedVariables.scad>
|
include <../sharedVariables.scad>
|
||||||
|
include <../../misc/magnet.scad>
|
||||||
|
|
||||||
sideWallConnW = 7;
|
sideWallConnW = 7;
|
||||||
sideWallConnD = 20;
|
sideWallConnD = 20;
|
||||||
|
|||||||
@ -1,13 +1,10 @@
|
|||||||
include <../helper/sphericalFilet.scad>
|
|
||||||
include <../helper/cylindricalFilet.scad>
|
include <../helper/cylindricalFilet.scad>
|
||||||
include <../helper/screws.scad>
|
include <../helper/screws.scad>
|
||||||
include <./config.scad>
|
include <./config.scad>
|
||||||
include <./derivedConfig.scad>
|
|
||||||
include <./xyBarConnector.scad>
|
include <./xyBarConnector.scad>
|
||||||
|
|
||||||
// Temporary
|
// Temporary
|
||||||
include <./yBar.scad>
|
include <./yBar.scad>
|
||||||
include <./mainRail.scad>
|
|
||||||
|
|
||||||
// It's actually the railSlotToInnerYEdge of the yBar, it'll be nice to be able to refer to it like yBar.railSlotToInnerYEdge
|
// It's actually the railSlotToInnerYEdge of the yBar, it'll be nice to be able to refer to it like yBar.railSlotToInnerYEdge
|
||||||
xBarDepth = maxUnitWidth - 2*railSlotToInnerYEdge;
|
xBarDepth = maxUnitWidth - 2*railSlotToInnerYEdge;
|
||||||
@ -22,7 +19,11 @@ xBarRoundness = baseRoundness;
|
|||||||
|
|
||||||
module xBar() {
|
module xBar() {
|
||||||
|
|
||||||
module positive() {
|
applyYBarConnector()
|
||||||
|
xBarBase();
|
||||||
|
|
||||||
|
module xBarBase() {
|
||||||
|
intersection() {
|
||||||
mirror(v = [0, 1, 0])
|
mirror(v = [0, 1, 0])
|
||||||
rotate(a = [0, 0, -90])
|
rotate(a = [0, 0, -90])
|
||||||
difference() {
|
difference() {
|
||||||
@ -31,9 +32,12 @@ module xBar() {
|
|||||||
translate(v = [xBarWallThickness, xBarWallThickness, xBarWallThickness])
|
translate(v = [xBarWallThickness, xBarWallThickness, xBarWallThickness])
|
||||||
cylindricalFiletEdge(xBarWidth, xBarDepth-2*xBarWallThickness, xBarHeight, xBarRoundness);
|
cylindricalFiletEdge(xBarWidth, xBarDepth-2*xBarWallThickness, xBarHeight, xBarRoundness);
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
module xBar() {
|
// Shave off bottom corners to reduce elephant's foot at where xBar and YBar join
|
||||||
|
halfspace(vpos = [1, 0, 1], p = [0.6, 0, 0]);
|
||||||
|
halfspace(vpos = [-1, 0, 1], p = [xBarDepth-0.6, 0, 0]);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
module mirrorOtherCorner() {
|
module mirrorOtherCorner() {
|
||||||
children(0);
|
children(0);
|
||||||
@ -45,31 +49,17 @@ module xBar() {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// TODO refactor - probably better off mirroring the side faces and hulling the shell
|
module applyYBarConnector() {
|
||||||
difference() {
|
apply_pn() {
|
||||||
union() {
|
|
||||||
intersection() {
|
|
||||||
positive();
|
|
||||||
halfspace(vpos = [1, 0, 1], p = [0.5, 0, 0]);
|
|
||||||
|
|
||||||
halfspace(vpos = [-1, 0, 1], p = [xBarDepth-0.5, 0, 0]);
|
|
||||||
}
|
|
||||||
|
|
||||||
yBarConnectorFromXLug();
|
|
||||||
|
|
||||||
mirrorOtherCorner()
|
mirrorOtherCorner()
|
||||||
yBarConnectorFromXLug();
|
yBarConnectorFromXLug();
|
||||||
}
|
|
||||||
|
|
||||||
union() {
|
|
||||||
yBarConnectorFromX_N();
|
|
||||||
|
|
||||||
mirrorOtherCorner()
|
mirrorOtherCorner()
|
||||||
yBarConnectorFromX_N();
|
yBarConnectorFromX_N();
|
||||||
|
|
||||||
|
children(0);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
|
||||||
xBar();
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
@ -48,9 +48,7 @@ module yBarConnectorFromXLug() {
|
|||||||
scale(v=[0.90,0.95,0.90])
|
scale(v=[0.90,0.95,0.90])
|
||||||
cube(size = [3, 10, 6], center = true);
|
cube(size = [3, 10, 6], center = true);
|
||||||
|
|
||||||
mirror(v=[0,0,1])
|
|
||||||
halfspace(vpos=[0,0,1], p=[0,0,0]);
|
halfspace(vpos=[0,0,1], p=[0,0,0]);
|
||||||
|
|
||||||
halfspace(vpos=[1,0,0], p=[-2,0,0]);
|
halfspace(vpos=[1,0,0], p=[-2,0,0]);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
14
rbuild.sh
14
rbuild.sh
@ -1,7 +1,7 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
|
|
||||||
STL_TARGET_DIR=stl
|
STL_TARGET_DIR=stl
|
||||||
RACK_DIR=rack
|
RACK_DIR=rack/print
|
||||||
RACK_TARGET_DIR="$STL_TARGET_DIR"/"$RACK_DIR"
|
RACK_TARGET_DIR="$STL_TARGET_DIR"/"$RACK_DIR"
|
||||||
|
|
||||||
echo "Starting build"
|
echo "Starting build"
|
||||||
@ -17,9 +17,10 @@ rbuild() {
|
|||||||
build_scad "$item"
|
build_scad "$item"
|
||||||
elif [[ "$command" == "clean" ]]; then
|
elif [[ "$command" == "clean" ]]; then
|
||||||
clean_scad "$item"
|
clean_scad "$item"
|
||||||
|
else
|
||||||
|
echo "Command not supported 😔";
|
||||||
fi
|
fi
|
||||||
|
|
||||||
echo "That all folks"
|
|
||||||
}
|
}
|
||||||
|
|
||||||
build_scad() {
|
build_scad() {
|
||||||
@ -50,7 +51,14 @@ build_scad_file() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
build_scad_dir() {
|
build_scad_dir() {
|
||||||
echo "build_scad_dir TODO"
|
|
||||||
|
for ITEM in "$RACK_DIR"/*.scad; do
|
||||||
|
|
||||||
|
local base_item="$(basename "${ITEM}")";
|
||||||
|
|
||||||
|
build_scad_file "${base_item%.*}";
|
||||||
|
done
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
clean_scad_file() {
|
clean_scad_file() {
|
||||||
|
|||||||
327882
stl/rack/fullAssembly.stl
327882
stl/rack/fullAssembly.stl
File diff suppressed because it is too large
Load Diff
27302
stl/rack/mainRail.stl
27302
stl/rack/mainRail.stl
File diff suppressed because it is too large
Load Diff
4650
stl/rack/print/hingeModule_P1.stl
Normal file
4650
stl/rack/print/hingeModule_P1.stl
Normal file
File diff suppressed because it is too large
Load Diff
4650
stl/rack/print/hingeModule_P2.stl
Normal file
4650
stl/rack/print/hingeModule_P2.stl
Normal file
File diff suppressed because it is too large
Load Diff
5630
stl/rack/print/magnetModule_P1.stl
Normal file
5630
stl/rack/print/magnetModule_P1.stl
Normal file
File diff suppressed because it is too large
Load Diff
5630
stl/rack/print/magnetModule_P2.stl
Normal file
5630
stl/rack/print/magnetModule_P2.stl
Normal file
File diff suppressed because it is too large
Load Diff
27302
stl/rack/print/mainRail_P.stl
Normal file
27302
stl/rack/print/mainRail_P.stl
Normal file
File diff suppressed because it is too large
Load Diff
13974
stl/rack/print/sideWallLeft_P.stl
Normal file
13974
stl/rack/print/sideWallLeft_P.stl
Normal file
File diff suppressed because it is too large
Load Diff
13974
stl/rack/print/sideWallRight_P.stl
Normal file
13974
stl/rack/print/sideWallRight_P.stl
Normal file
File diff suppressed because it is too large
Load Diff
5182
stl/rack/print/xBar_P.stl
Normal file
5182
stl/rack/print/xBar_P.stl
Normal file
File diff suppressed because it is too large
Load Diff
36318
stl/rack/print/yBar_P.stl
Normal file
36318
stl/rack/print/yBar_P.stl
Normal file
File diff suppressed because it is too large
Load Diff
8934
stl/rack/xBar.stl
8934
stl/rack/xBar.stl
File diff suppressed because it is too large
Load Diff
34218
stl/rack/yBar.stl
34218
stl/rack/yBar.stl
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user