add features
This commit is contained in:
@ -70,6 +70,13 @@ function screwRadiusSlacked(screwType) =
|
|||||||
? m4RadiusSlacked
|
? m4RadiusSlacked
|
||||||
: error("Unsupported screw type");
|
: error("Unsupported screw type");
|
||||||
|
|
||||||
|
function hexNutThickness(screwType) =
|
||||||
|
(screwType == "m3")
|
||||||
|
? m3HexNutThickness
|
||||||
|
: (screwType == "m4")
|
||||||
|
? m4HexNutThickness
|
||||||
|
: error("Unsupported screw type");
|
||||||
|
|
||||||
|
|
||||||
module counterSunkHead_N(screwType, screwExtension=0, headExtension=0) {
|
module counterSunkHead_N(screwType, screwExtension=0, headExtension=0) {
|
||||||
|
|
||||||
@ -89,13 +96,19 @@ module counterSunkHead_N(screwType, screwExtension=0, headExtension=0) {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
module hexNut(screwType) {
|
module hexNut(screwType, center=true) {
|
||||||
color([0, 1, 1])
|
color([0, 1, 1])
|
||||||
if (screwType == "m3") {
|
if (screwType == "m3") {
|
||||||
translate(v = [0, 0,-m3HexNutThickness/2])
|
translate(v = [0, 0,-m3HexNutThickness/2])
|
||||||
difference() {
|
difference() {
|
||||||
cylinder(r=m3HexNutWidthAcrossCorners/2, h=m3HexNutThickness, $fn=6);
|
cylinder(r=m3HexNutWidthAcrossCorners/2, h=m3HexNutThickness, $fn=6);
|
||||||
cylinder(r=m3Radius,h=inf10);
|
cylinder(r=m3Radius,h=inf10, center=true);
|
||||||
|
}
|
||||||
|
} else if (screwType == "m4") {
|
||||||
|
translate(v = [0, 0,-m4HexNutThickness/2])
|
||||||
|
difference() {
|
||||||
|
cylinder(r=m4HexNutWidthAcrossCorners/2, h=m4HexNutThickness, $fn=6);
|
||||||
|
cylinder(r=m4Radius,h=inf10, center=true);
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
error("Unsupported screw type");
|
error("Unsupported screw type");
|
||||||
|
|||||||
BIN
media/micro.png
Normal file
BIN
media/micro.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 67 KiB |
BIN
media/mini.png
Normal file
BIN
media/mini.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 72 KiB |
BIN
media/miniTall.png
Normal file
BIN
media/miniTall.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 80 KiB |
BIN
media/miniWide.png
Normal file
BIN
media/miniWide.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 61 KiB |
@ -15,9 +15,7 @@ assemblyInstructions();
|
|||||||
module assemblyInstructions () {
|
module assemblyInstructions () {
|
||||||
|
|
||||||
// Instruction List (in order)
|
// Instruction List (in order)
|
||||||
// TODO: add steps to glue magnets and add heatset inserts
|
// render()
|
||||||
|
|
||||||
render()
|
|
||||||
// addHeatSetInsertsYBar(at=$t);
|
// addHeatSetInsertsYBar(at=$t);
|
||||||
// addMagnetsToMagnetModules(at=$t);
|
// addMagnetsToMagnetModules(at=$t);
|
||||||
// addMagnetsToSideWall(at=$t);
|
// addMagnetsToSideWall(at=$t);
|
||||||
@ -33,8 +31,18 @@ module assemblyInstructions () {
|
|||||||
// screwFeet(at=$t);
|
// screwFeet(at=$t);
|
||||||
// attachXYPlates(at=$t);
|
// attachXYPlates(at=$t);
|
||||||
|
|
||||||
// end instructions
|
|
||||||
finalDouble();
|
// Final builds:
|
||||||
|
// render()
|
||||||
|
// finalSingle();
|
||||||
|
// finalDouble();
|
||||||
|
|
||||||
|
|
||||||
|
// Features:
|
||||||
|
render()
|
||||||
|
slideInNuts(at=$t);
|
||||||
|
// stackable(at=$t); // recommended at least 15 frames for animation
|
||||||
|
// sideSwivel(at=$t);
|
||||||
|
|
||||||
|
|
||||||
module addHeatSetInsertsYBar(at=0) {
|
module addHeatSetInsertsYBar(at=0) {
|
||||||
@ -270,7 +278,7 @@ module assemblyInstructions () {
|
|||||||
insertDowelsIntoSideWall(at=1);
|
insertDowelsIntoSideWall(at=1);
|
||||||
}
|
}
|
||||||
|
|
||||||
module attachXYTrays(at=0) {
|
module attachXYTrays(at=0,r=0) {
|
||||||
|
|
||||||
t = lerp(a=10,b=0,t=at);
|
t = lerp(a=10,b=0,t=at);
|
||||||
|
|
||||||
@ -283,31 +291,22 @@ module assemblyInstructions () {
|
|||||||
multmatrix(upperXYTrayTrans) {
|
multmatrix(upperXYTrayTrans) {
|
||||||
attachSideConnectorModulesToYBars(at=1);
|
attachSideConnectorModulesToYBars(at=1);
|
||||||
|
|
||||||
|
mirrorAllTrayCornersFromYBarSpace()
|
||||||
multmatrix(yBarMainRailConnectorTrans)
|
multmatrix(yBarMainRailConnectorTrans)
|
||||||
singleScrew(t=t);
|
singleScrew(t=t);
|
||||||
|
|
||||||
multmatrix(yBarMirrorOtherCornerTrans * yBarMainRailConnectorTrans)
|
|
||||||
singleScrew(t=t);
|
|
||||||
|
|
||||||
multmatrix(xBarSpaceToYBarSpace * xBarMirrorOtherCornerTrans * yBarSpaceToXBarSpace * yBarMirrorOtherCornerTrans * yBarMainRailConnectorTrans)
|
|
||||||
singleScrew(t=t);
|
|
||||||
|
|
||||||
multmatrix(xBarSpaceToYBarSpace * xBarMirrorOtherCornerTrans * yBarSpaceToXBarSpace * yBarMirrorOtherCornerTrans * yBarMirrorOtherCornerTrans * yBarMainRailConnectorTrans)
|
|
||||||
singleScrew(t=t);
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
propUpBottomXYTraywithSideWalls(at=1,r=0);
|
propUpBottomXYTraywithSideWalls(at=1,r=r);
|
||||||
}
|
}
|
||||||
|
|
||||||
module attachXYPlates(at=0) {
|
module attachXYPlates(at=0,r=0) {
|
||||||
|
|
||||||
t = lerp(a=10,b=0,t=at);
|
t = lerp(a=10,b=0,t=at);
|
||||||
|
|
||||||
// TODO fix xyPlate transformations
|
// TODO fix xyPlate transformations
|
||||||
function xyPlateToYBarTrans() = translate(v=[6,6,0]) * yBarBasePlateConnectorTrans;
|
function xyPlateToYBarTrans() = translate(v=[6,6,0]) * yBarBasePlateConnectorTrans;
|
||||||
|
|
||||||
attachXYTrays(at=1);
|
attachXYTrays(at=1,r=r);
|
||||||
|
|
||||||
multmatrix(xyPlateToYBarTrans())
|
multmatrix(xyPlateToYBarTrans())
|
||||||
xyPlateWithScrews(t=t);
|
xyPlateWithScrews(t=t);
|
||||||
@ -358,11 +357,11 @@ module assemblyInstructions () {
|
|||||||
stackConnectorFeet();
|
stackConnectorFeet();
|
||||||
}
|
}
|
||||||
|
|
||||||
module insertFeet(at=0) {
|
module insertFeet(at=0,r=0) {
|
||||||
|
|
||||||
t = lerp(a=10,b=0,t=at);
|
t = lerp(a=10,b=0,t=at);
|
||||||
|
|
||||||
attachXYPlates(at=1);
|
attachXYPlates(at=1,r=r);
|
||||||
|
|
||||||
multmatrix(feetToYBarTrans(t=t))
|
multmatrix(feetToYBarTrans(t=t))
|
||||||
slideHexNutToFeet(at=1);
|
slideHexNutToFeet(at=1);
|
||||||
@ -371,7 +370,7 @@ module assemblyInstructions () {
|
|||||||
slideHexNutToFeet(at=1);
|
slideHexNutToFeet(at=1);
|
||||||
}
|
}
|
||||||
|
|
||||||
module screwFeet(at=0) {
|
module screwFeet(at=0,r=0) {
|
||||||
|
|
||||||
t = lerp(a=20, b=0, t=at);
|
t = lerp(a=20, b=0, t=at);
|
||||||
|
|
||||||
@ -392,18 +391,108 @@ module assemblyInstructions () {
|
|||||||
multmatrix(yBarMirrorOtherCornerTrans)
|
multmatrix(yBarMirrorOtherCornerTrans)
|
||||||
screwToFeetModule();
|
screwToFeetModule();
|
||||||
|
|
||||||
insertFeet(at=1);
|
insertFeet(at=1,r=r);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
module finalSingle() {
|
module finalSingle(r=0) {
|
||||||
|
screwFeet(at=1,r=r);
|
||||||
|
}
|
||||||
|
|
||||||
|
module finalDouble(r=0) {
|
||||||
|
multmatrix(secondStackTrans)
|
||||||
|
attachXYPlates(at=1,r=r);
|
||||||
|
|
||||||
|
screwFeet(at=1,r=r);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
module slideInNuts(at=0) {
|
||||||
|
|
||||||
|
t = lerp(a=15,b=0,t=at);
|
||||||
|
|
||||||
screwFeet(at=1);
|
screwFeet(at=1);
|
||||||
|
|
||||||
|
slideInScrew(t=t, i=1);
|
||||||
|
slideInScrew(t=t, i=4);
|
||||||
|
|
||||||
|
module slideInScrew(t=0, i=1) {
|
||||||
|
translate(v = [railScrewHoleToOuterEdge + t, railFrontThickness/2, railFootThickness+(10*i)])
|
||||||
|
multmatrix(yBarMainRailConnectorTrans)
|
||||||
|
rotate(a = [90, 0, 0])
|
||||||
|
hexNut(mainRailScrewType);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
module finalDouble() {
|
module slideInStackConnectorNut(at=0) {
|
||||||
translate(v=[0,0,140])
|
|
||||||
|
t = lerp(a=10,b=0,t=at);
|
||||||
|
|
||||||
|
module slidingNut(t=0) {
|
||||||
|
translate(v=[connectorRectWidth/2,connectorRectDepth/2 - t,connectorBottomToScrew+stackConnectorDualSpacing/2])
|
||||||
|
rotate(a=[90,0,0])
|
||||||
|
rotate(a=[0,90,0])
|
||||||
|
hexNut(rackFrameScrewType);
|
||||||
|
}
|
||||||
|
|
||||||
|
slidingNut(t=t);
|
||||||
|
|
||||||
|
mirror(v=[0,0,1])
|
||||||
|
slidingNut(t=t);
|
||||||
|
|
||||||
|
translate(v=[0,connectorRectDepth,0])
|
||||||
|
mirror(v=[0,1,0])
|
||||||
|
stackConnectorDual();
|
||||||
|
}
|
||||||
|
|
||||||
|
module stackable(at=0) {
|
||||||
|
|
||||||
|
t1 = lerp(a=0, b=1, t=min(3*at, 1));
|
||||||
|
t2 = lerp(a=30, b=0, t=min(max(3*at-1,0),1));
|
||||||
|
t3 = lerp(a=15, b=0, t=max(3*at-2, 0));
|
||||||
|
|
||||||
|
module stackConnectors() {
|
||||||
|
mirrorAllTrayCornersFromYBarSpace()
|
||||||
|
multmatrix(stackConnectorTrans(t=0))
|
||||||
|
slideInStackConnectorNut(t1);
|
||||||
|
}
|
||||||
|
|
||||||
|
module singleTrayScrews() {
|
||||||
|
screwTrans = feetToYBarTrans(t=0) * translate(v=[-t3 - 9,0,connectorBottomToScrew]) * rotate(a=[0,-90,0]);
|
||||||
|
|
||||||
|
mirrorAllTrayCornersFromYBarSpace()
|
||||||
|
multmatrix(screwTrans)
|
||||||
|
caseScrewB();
|
||||||
|
}
|
||||||
|
|
||||||
|
translate(v=[0,0,t2/2])
|
||||||
|
stackConnectors();
|
||||||
|
|
||||||
|
if (at >= 2/3) {
|
||||||
|
multmatrix(secondStackTrans)
|
||||||
|
singleTrayScrews();
|
||||||
|
|
||||||
|
multmatrix(upperXYTrayTrans)
|
||||||
|
singleTrayScrews();
|
||||||
|
}
|
||||||
|
|
||||||
|
translate(v=[0,0,t2])
|
||||||
|
multmatrix(secondStackTrans)
|
||||||
attachXYPlates(at=1);
|
attachXYPlates(at=1);
|
||||||
|
|
||||||
screwFeet(at=1);
|
screwFeet(at=1);
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
module sideSwivel(at=0) {
|
||||||
|
|
||||||
|
r = lerp(a=0,b=2*110,t=at) % 110;
|
||||||
|
|
||||||
|
finalSingle(r=r);
|
||||||
|
}
|
||||||
|
|
||||||
|
module parametric() {
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
xBarSpaceToYBarSpace =
|
xBarSpaceToYBarSpace =
|
||||||
@ -426,6 +515,25 @@ module assemblyInstructions () {
|
|||||||
yBarStackConnectorTrans *
|
yBarStackConnectorTrans *
|
||||||
mirror(v=[0,1,0]);
|
mirror(v=[0,1,0]);
|
||||||
|
|
||||||
|
function stackConnectorTrans(t=0) =
|
||||||
|
upperXYTrayTrans *
|
||||||
|
yBarStackConnectorTrans;
|
||||||
|
|
||||||
|
module mirrorAllTrayCornersFromYBarSpace() {
|
||||||
|
children(0);
|
||||||
|
|
||||||
|
multmatrix(yBarMirrorOtherCornerTrans)
|
||||||
|
children(0);
|
||||||
|
|
||||||
|
multmatrix(xBarSpaceToYBarSpace * xBarMirrorOtherCornerTrans * yBarSpaceToXBarSpace * yBarMirrorOtherCornerTrans)
|
||||||
|
children(0);
|
||||||
|
|
||||||
|
multmatrix(xBarSpaceToYBarSpace * xBarMirrorOtherCornerTrans * yBarSpaceToXBarSpace * yBarMirrorOtherCornerTrans * yBarMirrorOtherCornerTrans)
|
||||||
|
children(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
secondStackTrans = upperXYTrayTrans * mirror(v=[0,0,1]);
|
||||||
|
|
||||||
|
|
||||||
module caseScrewA() {
|
module caseScrewA() {
|
||||||
color([0,1,1]) {
|
color([0,1,1]) {
|
||||||
|
|||||||
@ -104,20 +104,6 @@ module stackConnectorPlug() {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
module stackConnectorDual() {
|
|
||||||
|
|
||||||
space = 0.5; // extra space inbetween
|
|
||||||
|
|
||||||
translate(v=[0,0,space])
|
|
||||||
stackConnectorPlug();
|
|
||||||
|
|
||||||
mirror(v=[0,0,1])
|
|
||||||
stackConnectorPlug();
|
|
||||||
|
|
||||||
cube(size=[connectorRectWidth+connectorRectPlugSlack, connectorRectDepth+connectorRectPlugSlack, space]);
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
module stackConnectorBottom() {
|
module stackConnectorBottom() {
|
||||||
|
|
||||||
height = 2; // space between bottom and floor
|
height = 2; // space between bottom and floor
|
||||||
|
|||||||
7
rack/features.scad
Normal file
7
rack/features.scad
Normal file
@ -0,0 +1,7 @@
|
|||||||
|
include <./assemblyGuide.scad>
|
||||||
|
|
||||||
|
features();
|
||||||
|
|
||||||
|
module features() {
|
||||||
|
|
||||||
|
}
|
||||||
@ -5,8 +5,19 @@ include <./sharedVariables.scad>
|
|||||||
// Distance from midpoint of stack connectors to each other
|
// Distance from midpoint of stack connectors to each other
|
||||||
stackConnectorDx = rackTotalWidth - 2*(connectorXEdgeToYBarXEdge + connectorRectWidth/2);
|
stackConnectorDx = rackTotalWidth - 2*(connectorXEdgeToYBarXEdge + connectorRectWidth/2);
|
||||||
stackConnectorDy = rackTotalDepth - 2*(connectorYEdgeToYBarYEdge + connectorRectDepth/2);
|
stackConnectorDy = rackTotalDepth - 2*(connectorYEdgeToYBarYEdge + connectorRectDepth/2);
|
||||||
|
stackConnectorDualSpacing = 0.5;
|
||||||
|
|
||||||
*stackConnectorFeet();
|
module stackConnectorDual() {
|
||||||
|
translate(v=[0,0,stackConnectorDualSpacing/2])
|
||||||
|
stackConnectorPlug();
|
||||||
|
|
||||||
|
mirror(v=[0,0,1])
|
||||||
|
translate(v=[0,0,stackConnectorDualSpacing/2])
|
||||||
|
stackConnectorPlug();
|
||||||
|
|
||||||
|
translate(v=[0,0,-stackConnectorDualSpacing/2])
|
||||||
|
cube(size=[connectorRectWidth+connectorRectPlugSlack, connectorRectDepth+connectorRectPlugSlack, stackConnectorDualSpacing]);
|
||||||
|
}
|
||||||
|
|
||||||
module stackConnectorFeet() {
|
module stackConnectorFeet() {
|
||||||
|
|
||||||
@ -27,7 +38,6 @@ module stackConnectorFeet() {
|
|||||||
band();
|
band();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
module band() {
|
module band() {
|
||||||
|
|
||||||
intersection() {
|
intersection() {
|
||||||
|
|||||||
Reference in New Issue
Block a user