Updates to leaf_arm and plate function
Printing position now set by plate function. leaf_arm now takes an optional child element.
This commit is contained in:
@@ -42,7 +42,7 @@ SideW=tol+BackW;
|
||||
|
||||
echo("Reference Diameter (MeshD): ", MeshD);
|
||||
//rot=90*$t;
|
||||
rot=1;
|
||||
rot=3;
|
||||
|
||||
//meshed(rot=rot);
|
||||
|
||||
@@ -50,9 +50,16 @@ $fa = ($preview) ? 17 : .1;
|
||||
$fs = ($preview) ? 3 : .1;
|
||||
$incolor = true;
|
||||
|
||||
gear_hinge(rot=rot, box=false, rounded_case=true);
|
||||
plate_hinge();
|
||||
//gear_hinge(rot=rot, box=false, rounded_case=true);
|
||||
//translate([50,0,0]) gear_hinge(rot=rot, box=false, box_top=true);
|
||||
|
||||
module plate_hinge() {
|
||||
rot = 90 - 5;
|
||||
gear_hinge(rot=rot, box=false, rounded_case=true);
|
||||
|
||||
}
|
||||
|
||||
module gear_hinge(
|
||||
box=true,
|
||||
rounded_case=false,
|
||||
@@ -82,8 +89,7 @@ module gear_hinge(
|
||||
|
||||
module gear_track_block() {
|
||||
difference() {
|
||||
//CyS(r=MeshD/2 + Module/2, h=width/2, w1=245, w2=250);
|
||||
CyS(r=MeshD/2, h=width, w1=275, w2=310);
|
||||
CyS(r=MeshD/2 +.5, h=width, w1=275, w2=310);
|
||||
CyS(r=ShaftD+.5, h=width, w1=275, w2=310);
|
||||
}
|
||||
}
|
||||
@@ -93,14 +99,14 @@ module gear_track_block() {
|
||||
// currently only used on the blue_gear.
|
||||
// xxx: red_gear maybe should be refactored to use it?
|
||||
module gear_sector(meshd, width) {
|
||||
CyS(r=meshd, h=width, w1=215, w2=00);
|
||||
CyS(r=meshd/2 - 2, h=width, w1=-1, w2=90);
|
||||
CyS(r=meshd, h=width, w1=215, w2=15);
|
||||
CyS(r=meshd/2 - 1.6, h=width, w1=-1, w2=90);
|
||||
}
|
||||
|
||||
// blue_gear - Gear on the left with the track block built into its back side.
|
||||
module blue_gear() {
|
||||
intersection() {
|
||||
spur_gear(n=N1, w=width, m=Module, chamfer=30, helix_angle = helix_angle, add=-tol/2 );
|
||||
spur_gear(n=N1, w=width, m=Module, chamfer=30, helix_angle = helix_angle, add=-tol/4 );
|
||||
difference() {
|
||||
gear_sector(meshd=MeshD, width=width);
|
||||
|
||||
@@ -129,15 +135,16 @@ module red_gear()
|
||||
union() {
|
||||
CyS(r=MeshD/2 - 2, h=width, w1=90, w2=190);
|
||||
intersection() {
|
||||
spur_gear(n=N2, w=width, m=Module, chamfer=30, helix_angle=-helix_angle, add=-tol/2);
|
||||
CyS(r=MeshD, h=width, w1=180, w2=-30);
|
||||
spur_gear(n=N2, w=width, m=Module, chamfer=30, helix_angle=-helix_angle, add=-tol/4);
|
||||
CyS(r=MeshD, h=width, w1=181, w2=-30);
|
||||
|
||||
|
||||
}
|
||||
|
||||
// leaf arm
|
||||
translate([-2,11.6,0]) leaf_arm(left=false, h=width+3.2);
|
||||
// Rear Block
|
||||
translate([-2,11.6,0]) leaf_arm(left=false, h=width+3.2)
|
||||
translate([0,-4+tol,0]) cube([4,10,width+3.2], center=true);
|
||||
// Rear Block
|
||||
gear_track_block();
|
||||
}
|
||||
// Shaft Hole
|
||||
@@ -151,8 +158,8 @@ module red_gear()
|
||||
|
||||
}
|
||||
|
||||
module leaf_arm(left=true, h, angle=false) {
|
||||
dx = 7.51;
|
||||
module leaf_arm(left=true, h, l, angle=false) {
|
||||
dx = 3;
|
||||
difference() {
|
||||
//cube([4,20,width+1], center=true);
|
||||
translate([0,-9.5+dx/2,0]) cube([4,dx,width], center=true);
|
||||
@@ -168,7 +175,11 @@ module leaf_arm(left=true, h, angle=false) {
|
||||
}
|
||||
}
|
||||
}
|
||||
translate([0,-4+tol,0]) cube([4,10,h], center=true);
|
||||
if ($children < 1) {
|
||||
translate([0,-6+tol,0]) cube([4,4,h], center=true);
|
||||
} else {
|
||||
children(0);
|
||||
}
|
||||
}
|
||||
|
||||
module round_case_inner(meshd, shaftd, width, tol) {
|
||||
|
||||
Reference in New Issue
Block a user