Moved Z endstops to bottom of towers. Improved wiring rendering.
@@ -2028,6 +2028,8 @@ module extrude_2d_hollow(wall=2, height=50, twist=90, slices=60)
|
||||
|
||||
function vector2d_angle(v1,v2) = atan2(v1[1],v1[0]) - atan2(v2[1],v2[0]);
|
||||
function vector3d_angle(v1,v2) = acos((v1*v2)/(norm(v1)*norm(v2)));
|
||||
function normalize(v) = v/norm(v);
|
||||
|
||||
|
||||
function slice(arr,st,end) = let(
|
||||
s=st<0?(len(arr)+st):st,
|
||||
@@ -2261,6 +2263,87 @@ module extrude_2dpath_along_spiral(polyline, h, r, twist=360) {
|
||||
}
|
||||
|
||||
|
||||
// Quaternions are stored internally as a 4-value vector:
|
||||
// [X, Y, Z, W] = W + Xi + Yj + Zk
|
||||
function _Quat(a,s,w) = [a[0]*s, a[1]*s, a[2]*s, w];
|
||||
function Quat(ax, ang) = _Quat(ax/norm(ax), sin(ang/2), cos(ang/2));
|
||||
|
||||
function Q_Ident() = [0, 0, 0, 1];
|
||||
|
||||
function Q_Add_S(q, s) = [q[0], q[1], q[2], q[3]+s];
|
||||
function Q_Sub_S(q, s) = [q[0], q[1], q[2], q[3]-s];
|
||||
function Q_Mul_S(q, s) = [q[0]*s, q[1]*s, q[2]*s, q[3]*s];
|
||||
function Q_Div_S(q, s) = [q[0]/s, q[1]/s, q[2]/s, q[3]/s];
|
||||
|
||||
function Q_Add(a, b) = [a[0]+b[0], a[1]+b[1], a[2]+b[2], a[3]+b[3]];
|
||||
function Q_Sub(a, b) = [a[0]-b[0], a[1]-b[1], a[2]-b[2], a[3]-b[3]];
|
||||
function Q_Mul(a, b) = [
|
||||
a[3]*b[0] + a[0]*b[3] + a[1]*b[2] - a[2]*b[1],
|
||||
a[3]*b[1] - a[0]*b[2] + a[1]*b[3] + a[2]*b[0],
|
||||
a[3]*b[2] + a[0]*b[1] - a[1]*b[0] + a[2]*b[3],
|
||||
a[3]*b[3] - a[0]*b[0] - a[1]*b[1] - a[2]*b[2],
|
||||
];
|
||||
function Q_Dot(a, b) = a[0]*b[0] + a[1]*b[1] + a[2]*b[2] + a[3]*b[3];
|
||||
|
||||
function Q_Neg(q) = [-q[0], -q[1], -q[2], -q[3]];
|
||||
function Q_Conj(q) = [-q[0], -q[1], -q[2], q[3]];
|
||||
function Q_Norm(q) = sqrt(q[0]*q[0] + q[1]*q[1] + q[2]*q[2] + q[3]*q[3]);
|
||||
function Q_Normalize(q) = q/Q_Norm(q);
|
||||
function Q_Dist(q1, q2) = Q_Norm(Q_Sub(q1-q2));
|
||||
|
||||
|
||||
// Returns the 3x3 rotation matrix for the given normalized quaternion q.
|
||||
function Q_Matrix3(q) = [
|
||||
[1-2*q[1]*q[1]-2*q[2]*q[2], 2*q[0]*q[1]-2*q[2]*q[3], 2*q[0]*q[2]+2*q[1]*q[3]],
|
||||
[ 2*q[0]*q[1]+2*q[2]*q[3], 1-2*q[0]*q[0]-2*q[2]*q[2], 2*q[1]*q[2]-2*q[0]*q[3]],
|
||||
[ 2*q[0]*q[2]-2*q[1]*q[3], 2*q[1]*q[2]+2*q[0]*q[3], 1-2*q[0]*q[0]-2*q[1]*q[1]]
|
||||
];
|
||||
|
||||
|
||||
// Returns the 4x4 rotation matrix for the given normalized quaternion q.
|
||||
function Q_Matrix4(q) = [
|
||||
[1-2*q[1]*q[1]-2*q[2]*q[2], 2*q[0]*q[1]-2*q[2]*q[3], 2*q[0]*q[2]+2*q[1]*q[3], 0],
|
||||
[ 2*q[0]*q[1]+2*q[2]*q[3], 1-2*q[0]*q[0]-2*q[2]*q[2], 2*q[1]*q[2]-2*q[0]*q[3], 0],
|
||||
[ 2*q[0]*q[2]-2*q[1]*q[3], 2*q[1]*q[2]+2*q[0]*q[3], 1-2*q[0]*q[0]-2*q[1]*q[1], 0],
|
||||
[ 0, 0, 0, 1]
|
||||
];
|
||||
|
||||
|
||||
// Returns the vector v after rotating it by the quaternion q.
|
||||
function Q_Rot_Vector(v,q) = Q_Mul(Q_Mul(q,concat(v,0)),Q_Conj(q));
|
||||
|
||||
|
||||
// Rotates all children by the given quaternion q.
|
||||
module Qrot(q) {
|
||||
multmatrix(Q_Matrix4(q)) {
|
||||
children();
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
function points_along_path3d(
|
||||
polyline, // The 2D polyline to drag along the 3D path.
|
||||
path, // The 3D polyline path to follow.
|
||||
q=Q_Ident(), // Used in recursion
|
||||
n=0 // Used in recursion
|
||||
) = let(
|
||||
end = len(path)-1,
|
||||
v1 = (n == 0)? [0, 0, 1] : normalize(path[n]-path[n-1]),
|
||||
v2 = (n == end)? normalize(path[n]-path[n-1]) : normalize(path[n+1]-path[n]),
|
||||
crs = cross(v1, v2),
|
||||
axis = norm(crs) <= 0.001? [0, 0, 1] : crs,
|
||||
ang = vector3d_angle(v1, v2),
|
||||
hang = ang * (n==0? 1.0 : 0.5),
|
||||
hrot = Quat(axis, hang),
|
||||
arot = Quat(axis, ang),
|
||||
roth = Q_Mul(hrot, q),
|
||||
rotm = Q_Mul(arot, q)
|
||||
) concat(
|
||||
[for (i = [0:len(polyline)-1]) Q_Rot_Vector(point3d(polyline[i]),roth) + path[n]],
|
||||
(n == end)? [] : points_along_path3d(polyline, path, rotm, n+1)
|
||||
);
|
||||
|
||||
|
||||
// Takes a closed 2D polyline path, centered on the XY plane, and
|
||||
// extrudes it perpendicularly along a 3D polyline path, forming a solid.
|
||||
// polyline = Array of points of a polyline path, to be extruded.
|
||||
@@ -2275,20 +2358,7 @@ module extrude_2dpath_along_3dpath(polyline, path, tilt=true, convexity=10) {
|
||||
pline_count = len(polyline);
|
||||
path_count = len(path);
|
||||
|
||||
poly_points = [
|
||||
for (p = [0:path_count-1]) let (
|
||||
ppt1 = path[p],
|
||||
ppt0 = (p==0)? ppt1 : path[p-1],
|
||||
ppt2 = (p==(path_count-1))? ppt1 : path[p+1],
|
||||
v = ppt2 - ppt0,
|
||||
xyr = hypot(v[1], v[0]),
|
||||
az = atan2(v[1], v[0]),
|
||||
alt = atan2(v[2], xyr),
|
||||
rotx = matrix3_xrot(90+(tilt?alt:0)),
|
||||
rotz = matrix3_zrot(az-90),
|
||||
rotm = rotz * rotx
|
||||
) for (b = [0:pline_count-1]) rotm*point3d(polyline[b])+ppt1
|
||||
];
|
||||
poly_points = points_along_path3d(polyline, path);
|
||||
|
||||
poly_faces = concat(
|
||||
[[for (b = [0:pline_count-1]) b]],
|
||||
|
||||
|
Before Width: | Height: | Size: 54 KiB After Width: | Height: | Size: 54 KiB |
|
Before Width: | Height: | Size: 40 KiB After Width: | Height: | Size: 40 KiB |
|
Before Width: | Height: | Size: 54 KiB After Width: | Height: | Size: 54 KiB |
|
Before Width: | Height: | Size: 41 KiB After Width: | Height: | Size: 41 KiB |
|
Before Width: | Height: | Size: 50 KiB After Width: | Height: | Size: 50 KiB |
|
Before Width: | Height: | Size: 40 KiB After Width: | Height: | Size: 40 KiB |
|
Before Width: | Height: | Size: 53 KiB After Width: | Height: | Size: 53 KiB |
|
Before Width: | Height: | Size: 32 KiB After Width: | Height: | Size: 32 KiB |
|
Before Width: | Height: | Size: 36 KiB After Width: | Height: | Size: 45 KiB |
|
Before Width: | Height: | Size: 38 KiB After Width: | Height: | Size: 40 KiB |
|
Before Width: | Height: | Size: 55 KiB After Width: | Height: | Size: 54 KiB |
|
Before Width: | Height: | Size: 56 KiB After Width: | Height: | Size: 49 KiB |
|
Before Width: | Height: | Size: 26 KiB After Width: | Height: | Size: 26 KiB |
|
Before Width: | Height: | Size: 20 KiB After Width: | Height: | Size: 20 KiB |
|
Before Width: | Height: | Size: 27 KiB After Width: | Height: | Size: 27 KiB |
|
Before Width: | Height: | Size: 13 KiB After Width: | Height: | Size: 13 KiB |
|
Before Width: | Height: | Size: 30 KiB After Width: | Height: | Size: 30 KiB |
|
Before Width: | Height: | Size: 15 KiB After Width: | Height: | Size: 15 KiB |
|
Before Width: | Height: | Size: 83 KiB After Width: | Height: | Size: 83 KiB |
|
Before Width: | Height: | Size: 62 KiB After Width: | Height: | Size: 62 KiB |
|
Before Width: | Height: | Size: 74 KiB After Width: | Height: | Size: 74 KiB |
|
Before Width: | Height: | Size: 29 KiB After Width: | Height: | Size: 29 KiB |
|
Before Width: | Height: | Size: 76 KiB After Width: | Height: | Size: 76 KiB |
|
Before Width: | Height: | Size: 58 KiB After Width: | Height: | Size: 58 KiB |
|
Before Width: | Height: | Size: 78 KiB After Width: | Height: | Size: 78 KiB |
|
Before Width: | Height: | Size: 52 KiB After Width: | Height: | Size: 52 KiB |
|
Before Width: | Height: | Size: 70 KiB After Width: | Height: | Size: 70 KiB |
|
Before Width: | Height: | Size: 61 KiB After Width: | Height: | Size: 62 KiB |
|
Before Width: | Height: | Size: 69 KiB After Width: | Height: | Size: 68 KiB |
|
Before Width: | Height: | Size: 52 KiB After Width: | Height: | Size: 52 KiB |
|
Before Width: | Height: | Size: 38 KiB After Width: | Height: | Size: 41 KiB |
|
Before Width: | Height: | Size: 21 KiB After Width: | Height: | Size: 14 KiB |
|
Before Width: | Height: | Size: 142 KiB After Width: | Height: | Size: 142 KiB |
|
Before Width: | Height: | Size: 102 KiB After Width: | Height: | Size: 102 KiB |
|
Before Width: | Height: | Size: 122 KiB After Width: | Height: | Size: 122 KiB |
|
Before Width: | Height: | Size: 107 KiB After Width: | Height: | Size: 108 KiB |
|
Before Width: | Height: | Size: 138 KiB After Width: | Height: | Size: 139 KiB |
|
Before Width: | Height: | Size: 110 KiB After Width: | Height: | Size: 111 KiB |
|
Before Width: | Height: | Size: 153 KiB After Width: | Height: | Size: 154 KiB |
|
Before Width: | Height: | Size: 120 KiB After Width: | Height: | Size: 120 KiB |
|
Before Width: | Height: | Size: 67 KiB After Width: | Height: | Size: 68 KiB |
|
Before Width: | Height: | Size: 72 KiB After Width: | Height: | Size: 73 KiB |
|
Before Width: | Height: | Size: 160 KiB After Width: | Height: | Size: 160 KiB |
|
Before Width: | Height: | Size: 124 KiB After Width: | Height: | Size: 124 KiB |
|
Before Width: | Height: | Size: 164 KiB After Width: | Height: | Size: 164 KiB |
|
Before Width: | Height: | Size: 120 KiB After Width: | Height: | Size: 120 KiB |
|
Before Width: | Height: | Size: 109 KiB After Width: | Height: | Size: 109 KiB |
|
Before Width: | Height: | Size: 112 KiB After Width: | Height: | Size: 112 KiB |
|
Before Width: | Height: | Size: 102 KiB After Width: | Height: | Size: 102 KiB |
|
Before Width: | Height: | Size: 94 KiB After Width: | Height: | Size: 95 KiB |
@@ -197,17 +197,21 @@ UL {
|
||||
<table><tr><td class="befor"><img src="z_tower_assembly_3_before.png"></td><td class="arrow"><img src="arrow.png"></td><td class="after"><img src="z_tower_assembly_3_after.png"></td></tr></table>
|
||||
</li>
|
||||
<li class="step"><h3>Step 4</h3>
|
||||
<div class="desc">Attach a Z tower rail assembly to the top of each tower base assembly. Superglue these together if the attachment is wobbly in any way.</div>
|
||||
<div class="desc">Insert a microswitch into the tower base assembly. Route the wiring down to the base of the tower.</div>
|
||||
<table><tr><td class="befor"><img src="z_tower_assembly_4_before.png"></td><td class="arrow"><img src="arrow.png"></td><td class="after"><img src="z_tower_assembly_4_after.png"></td></tr></table>
|
||||
</li>
|
||||
<li class="step"><h3>Step 5</h3>
|
||||
<div class="desc">Slide the lifter assembly (motor and lifter rods) into the motor mount on the Z base segment of the topwer assembly.</div>
|
||||
<div class="desc">Attach a Z tower rail assembly to the top of each tower base assembly. Superglue these together if the attachment is wobbly in any way.</div>
|
||||
<table><tr><td class="befor"><img src="z_tower_assembly_5_before.png"></td><td class="arrow"><img src="arrow.png"></td><td class="after"><img src="z_tower_assembly_5_after.png"></td></tr></table>
|
||||
</li>
|
||||
<li class="step"><h3>Step 6</h3>
|
||||
<div class="desc">Attach a cable chain joiner mount to the front-size of the left Z tower, above the top hole of the bottom rail segment.</div>
|
||||
<div class="desc">Slide the lifter assembly (motor and lifter rods) into the motor mount on the Z base segment of the tower assembly.</div>
|
||||
<table><tr><td class="befor"><img src="z_tower_assembly_6_before.png"></td><td class="arrow"><img src="arrow.png"></td><td class="after"><img src="z_tower_assembly_6_after.png"></td></tr></table>
|
||||
</li>
|
||||
<li class="step"><h3>Step 7</h3>
|
||||
<div class="desc">Attach a cable chain joiner mount to the front-size of the left Z tower, above the top hole of the bottom rail segment.</div>
|
||||
<table><tr><td class="befor"><img src="z_tower_assembly_7_before.png"></td><td class="arrow"><img src="arrow.png"></td><td class="after"><img src="z_tower_assembly_7_after.png"></td></tr></table>
|
||||
</li>
|
||||
</ul>
|
||||
</li>
|
||||
<li class="section"><h2>Extruder Assembly</h2>
|
||||
@@ -281,16 +285,12 @@ UL {
|
||||
<li class="section"><h2>Top Brace Assembly</h2>
|
||||
<ul>
|
||||
<li class="step"><h3>Step 1</h3>
|
||||
<div class="desc">Attach a limit microswitch, with wiring, to the Z rail endcap. Orient the switch as shown. Do this again to make another Z endcap.</div>
|
||||
<div class="desc">Attach a bridge side brace onto either side of a bridge center brace.</div>
|
||||
<table><tr><td class="befor"><img src="top_brace_assembly_1_before.png"></td><td class="arrow"><img src="arrow.png"></td><td class="after"><img src="top_brace_assembly_1_after.png"></td></tr></table>
|
||||
</li>
|
||||
<li class="step"><h3>Step 2</h3>
|
||||
<div class="desc">Attach a bridge side brace onto either side of a bridge center brace.</div>
|
||||
<table><tr><td class="befor"><img src="top_brace_assembly_2_before.png"></td><td class="arrow"><img src="arrow.png"></td><td class="after"><img src="top_brace_assembly_2_after.png"></td></tr></table>
|
||||
</li>
|
||||
<li class="step"><h3>Step 3</h3>
|
||||
<div class="desc">Attach a Z rail endstop onto either side of the bridge brace assembly.</div>
|
||||
<table><tr><td class="befor"><img src="top_brace_assembly_3_before.png"></td><td class="arrow"><img src="arrow.png"></td><td class="after"><img src="top_brace_assembly_3_after.png"></td></tr></table>
|
||||
<table><tr><td class="befor"><img src="top_brace_assembly_2_before.png"></td><td class="arrow"><img src="arrow.png"></td><td class="after"><img src="top_brace_assembly_2_after.png"></td></tr></table>
|
||||
</li>
|
||||
</ul>
|
||||
</li>
|
||||
|
||||
|
Before Width: | Height: | Size: 23 KiB After Width: | Height: | Size: 23 KiB |
|
Before Width: | Height: | Size: 16 KiB After Width: | Height: | Size: 16 KiB |
|
Before Width: | Height: | Size: 27 KiB After Width: | Height: | Size: 27 KiB |
|
Before Width: | Height: | Size: 26 KiB After Width: | Height: | Size: 26 KiB |
|
Before Width: | Height: | Size: 39 KiB After Width: | Height: | Size: 39 KiB |
|
Before Width: | Height: | Size: 23 KiB After Width: | Height: | Size: 23 KiB |
|
Before Width: | Height: | Size: 30 KiB After Width: | Height: | Size: 30 KiB |
|
Before Width: | Height: | Size: 21 KiB After Width: | Height: | Size: 21 KiB |
|
Before Width: | Height: | Size: 28 KiB After Width: | Height: | Size: 28 KiB |
|
Before Width: | Height: | Size: 21 KiB After Width: | Height: | Size: 21 KiB |
|
Before Width: | Height: | Size: 47 KiB After Width: | Height: | Size: 30 KiB |
|
Before Width: | Height: | Size: 39 KiB After Width: | Height: | Size: 21 KiB |
|
Before Width: | Height: | Size: 30 KiB After Width: | Height: | Size: 29 KiB |
|
Before Width: | Height: | Size: 21 KiB After Width: | Height: | Size: 22 KiB |
|
Before Width: | Height: | Size: 29 KiB |
|
Before Width: | Height: | Size: 23 KiB |
|
Before Width: | Height: | Size: 99 KiB After Width: | Height: | Size: 99 KiB |
|
Before Width: | Height: | Size: 78 KiB After Width: | Height: | Size: 78 KiB |
|
Before Width: | Height: | Size: 64 KiB After Width: | Height: | Size: 64 KiB |
|
Before Width: | Height: | Size: 57 KiB After Width: | Height: | Size: 57 KiB |
|
Before Width: | Height: | Size: 43 KiB After Width: | Height: | Size: 43 KiB |
|
Before Width: | Height: | Size: 52 KiB After Width: | Height: | Size: 52 KiB |
|
Before Width: | Height: | Size: 72 KiB After Width: | Height: | Size: 72 KiB |
|
Before Width: | Height: | Size: 65 KiB After Width: | Height: | Size: 65 KiB |
|
Before Width: | Height: | Size: 101 KiB After Width: | Height: | Size: 101 KiB |
|
Before Width: | Height: | Size: 64 KiB After Width: | Height: | Size: 64 KiB |
|
Before Width: | Height: | Size: 119 KiB After Width: | Height: | Size: 119 KiB |
|
Before Width: | Height: | Size: 89 KiB After Width: | Height: | Size: 89 KiB |
|
Before Width: | Height: | Size: 111 KiB After Width: | Height: | Size: 111 KiB |
|
Before Width: | Height: | Size: 70 KiB After Width: | Height: | Size: 70 KiB |
|
Before Width: | Height: | Size: 115 KiB After Width: | Height: | Size: 115 KiB |
|
Before Width: | Height: | Size: 117 KiB After Width: | Height: | Size: 117 KiB |
|
Before Width: | Height: | Size: 95 KiB After Width: | Height: | Size: 94 KiB |
|
Before Width: | Height: | Size: 76 KiB After Width: | Height: | Size: 75 KiB |
|
Before Width: | Height: | Size: 74 KiB After Width: | Height: | Size: 74 KiB |
|
Before Width: | Height: | Size: 62 KiB After Width: | Height: | Size: 61 KiB |
|
Before Width: | Height: | Size: 90 KiB After Width: | Height: | Size: 89 KiB |
|
Before Width: | Height: | Size: 49 KiB After Width: | Height: | Size: 48 KiB |
|
Before Width: | Height: | Size: 70 KiB After Width: | Height: | Size: 70 KiB |
|
Before Width: | Height: | Size: 36 KiB After Width: | Height: | Size: 36 KiB |
|
Before Width: | Height: | Size: 82 KiB After Width: | Height: | Size: 82 KiB |
|
Before Width: | Height: | Size: 51 KiB After Width: | Height: | Size: 51 KiB |
|
Before Width: | Height: | Size: 47 KiB After Width: | Height: | Size: 47 KiB |
|
Before Width: | Height: | Size: 23 KiB After Width: | Height: | Size: 23 KiB |
|
Before Width: | Height: | Size: 83 KiB After Width: | Height: | Size: 83 KiB |
|
Before Width: | Height: | Size: 62 KiB After Width: | Height: | Size: 62 KiB |
|
Before Width: | Height: | Size: 36 KiB After Width: | Height: | Size: 36 KiB |
|
Before Width: | Height: | Size: 22 KiB After Width: | Height: | Size: 22 KiB |