mirror of
https://github.com/BelfrySCAD/BOSL2.git
synced 2024-12-29 16:29:40 +00:00
reverse ring gears, doc fixes
This commit is contained in:
parent
b584114495
commit
65396cbf48
1 changed files with 52 additions and 31 deletions
83
gears.scad
83
gears.scad
|
@ -97,7 +97,7 @@ function _inherit_gear_thickness(thickness) =
|
|||
// Figure(3D,Med,NoAxes,VPT=[4.62654,-1.10349,0.281802],VPR=[55,0,25],VPD=236.957): Involute Spur Gear
|
||||
// spur_gear(mod=5,teeth=18,pressure_angle=20,thickness=25,shaft_diam=15);
|
||||
// Continues:
|
||||
// The term "involute" refers to the shape of the teeth: the curves of the teeth involutes of circles,
|
||||
// The term "involute" refers to the shape of the teeth: the curves of the teeth are involutes of circles,
|
||||
// which are curves that optimize gear performance.
|
||||
// Figure(2D,Med,NoAxes,VPT=[8,74,0],VPR=[0,0,0],VPD=150): The three marked circles are key references on gear teeth. The pitch circle, which is roughly in the middle of the teeth, is the reference used to define the pitch of teeth on the gear. The pressure angle is the angle the tooth makes with the pitch circle. In this example, the pressure angle is 20 degrees as shown by the red lines.
|
||||
// $fn=128;
|
||||
|
@ -134,7 +134,7 @@ function _inherit_gear_thickness(thickness) =
|
|||
// are specified basic OpenSCAD units, so if you work in millimeters and want to give circular pitch in inches, be
|
||||
// sure to multiply by `INCH`. The diametral pitch is given based on inches under the assumption that OpenSCAD units are millimeters.
|
||||
// .
|
||||
// Basic gears as shown above will mesh when their profile circles are tangent.
|
||||
// Basic gears as shown above will mesh when their pitch circles are tangent.
|
||||
// The critical requirements for two gears to mesh are that
|
||||
// - The teeth are the same size
|
||||
// - The pressure angles are identical
|
||||
|
@ -173,7 +173,8 @@ function _inherit_gear_thickness(thickness) =
|
|||
// }
|
||||
// Continues:
|
||||
// Another clearance requirement can present a serious problem when the number of teeth is low. As the gear rotates, the
|
||||
// teeth may interfere with each other. This may require undercutting the gear teeth to create space, which weakens the teeth.
|
||||
// teeth may interfere with each other. This may require undercutting the gear teeth to create space, which weakens the teeth.
|
||||
// Is is best to avoid gears with very small numbers of teeth when possible.
|
||||
// Figure(2D,Med,NoAxes,VPT=[0.042845,6.5338,-0.0144912],VPR=[0,0,0],VPD=126): The green gear with only five teeth has a severe undercut, which weakens its teeth. This undercut is necessary to avoid interference with the teeth from the other gear during rotation. Note that the yellow rack tooth is deep into the undercut space.
|
||||
// ang=16;
|
||||
// rack2d(mod=5, teeth=3, bottom=15, pressure_angle=14.5, rounding=0);
|
||||
|
@ -189,8 +190,8 @@ function _inherit_gear_thickness(thickness) =
|
|||
// still allowing the gear to mesh with unmodified gears. Profile shifting
|
||||
// changes the diameter at which the gear meshes so it no longer meshes at the pitch circle.
|
||||
// A profile shift of `x`
|
||||
// will increase the mesh distance by approximately `x*m` where `m` is the gear module. The exact adjustment
|
||||
// which you compute with {{gear_dist()}} is a complex calculation that depends on the profile shifts of both meshing gears. This means that profile shifting
|
||||
// will increase the mesh distance by approximately `x*m` where `m` is the gear module. The exact adjustment,
|
||||
// which you compute with {{gear_dist()}}, is a complex calculation that depends on the profile shifts of both meshing gears. This means that profile shifting
|
||||
// can also be used to fine tune the spacing between gears. When the gear has many teeth a negative profile shift may
|
||||
// be able to bring the gears slightly closer together, while still avoiding undercutting.
|
||||
// Profile shifting also changes the effective pressure angle of the gear engagement.
|
||||
|
@ -223,14 +224,31 @@ function _inherit_gear_thickness(thickness) =
|
|||
// and quietly. A disadvantage of helical gears is that they have thrust along the axis of the gear that must be
|
||||
// accomodated. Helical gears also have more sliding friction between the meshing teeth compared to spur gears.
|
||||
// Figure(3D,Med,NoAxes,VPT=[3.5641,-7.03148,4.86523],VPR=[62.7,0,29.2],VPD=263.285): A Helical Gear
|
||||
// spur_gear(mod=5,teeth=18,pressure_angle=20,thickness=35,helical=-29,shaft_diam=15);
|
||||
// spur_gear(mod=5,teeth=18,pressure_angle=20,thickness=35,helical=-29,shaft_diam=15,slices=15);
|
||||
// Continues:
|
||||
// Helical gears have the same compatibility requirements as spur gears, with the additional requirement that
|
||||
// the helical angles must be opposite each other, so a gear with a helical angle of 25 must mesh with one
|
||||
// that has an angle of −25. The pitch circle of a helical gear is larger compared to a spur gear
|
||||
// the helical angles must be opposite each other, so a gear with a helical angle of 35 must mesh with one
|
||||
// that has an angle of −35. The industry convention refers to these as left-handed and right handed. In
|
||||
// this library, positive helical angles produce a left handed gear and negative angles produce a right handed gear.
|
||||
// Figure(3D,Med,NoAxes,VPT=[73.6023,-29.9518,-12.535],VPR=[76,0,1.2],VPD=550.777): Left and right handed helical gears at 35 degrees.
|
||||
// spur_gear(mod=5, teeth=20, helical=35, thickness=70,slices=15);
|
||||
// right(150)
|
||||
// spur_gear(mod=5, teeth=20, helical=-35, thickness=70,slices=15);
|
||||
// down(22)
|
||||
// left(60)
|
||||
// fwd(220)
|
||||
// rot($vpr)
|
||||
// color("black")text3d("left handed right handed",size=18);
|
||||
// down(52)
|
||||
// left(55)
|
||||
// fwd(220)
|
||||
// rot($vpr)
|
||||
// color("black")text3d("helical=35 helical=−35",size=18);
|
||||
// Continues:
|
||||
// The pitch circle of a helical gear is larger compared to a spur gear
|
||||
// by the cosine of the helical angle, so you cannot simply drop helical gears in to replace spur gears without
|
||||
// making other adjustments. This dependence does allow you to make
|
||||
// make much bigger spacing adjustments than are possible with profile shifting---without changing the tooth count.
|
||||
// make much bigger spacing adjustments than are possible with profile shifting—without changing the tooth count.
|
||||
// The {{gear_dist()}} function will also compute the appropriate gear spacing for helical gears.
|
||||
// The effective pressure angle of helical gears is larger than the nominal pressure angle. This can make it possible
|
||||
// to avoid undercutting without having to use profile shifting, so smaller tooth count gears can be more effective
|
||||
|
@ -243,7 +261,7 @@ function _inherit_gear_thickness(thickness) =
|
|||
// zrot(-$t*360/18)
|
||||
// spur_gear(mod=5, teeth=18, pressure_angle=20, thickness=25, helical=29, shaft_diam=15);
|
||||
// Continues:
|
||||
// Helical gears can mesh in a second manner that is different from spur gears at skew, or crossed axis. These are also
|
||||
// Helical gears can mesh in a second manner that is different from spur gears: they can turn on skew, or crossed axes. These are also
|
||||
// sometimes called "screw gears". The general requirement for two non-profile-shifted helical gears to mesh is that the angle
|
||||
// between the gears' axes must equal the sum of the helical angles of the two gears, thus for parallel axes, the helical
|
||||
// angles must sum to zero. If helical gears are profile shifted, then in addition to adjusting the distance between the
|
||||
|
@ -270,27 +288,16 @@ function _inherit_gear_thickness(thickness) =
|
|||
// Subsection: Ring Gears (Internal Gears)
|
||||
// A ring gear (or internal gear) is a gear where the teeth are on the inside of a circle. Such gears must be mated
|
||||
// to a regular (external) gear, which rotates around the inside.
|
||||
// Figure(2D,Med,NoAxes,VPT=[0.491171,1.07815,0.495977],VPD=292.705): A interior or ring gear (yellow) with a mating spur gear (blue)
|
||||
// teeth1=18;
|
||||
// teeth2=30;
|
||||
// ps1=undef;
|
||||
// ps2=auto_profile_shift(teeth=teeth1);
|
||||
// mod=3;
|
||||
// d = gear_dist(mod=mod, teeth1=teeth1, teeth2=teeth2,profile_shift1=ps1, profile_shift2=ps2,helical=0, internal2=true);
|
||||
// ang = 0;
|
||||
// ring_gear2d(mod=mod, teeth=teeth2,profile_shift=ps2,helical=0,backing=4);
|
||||
// zrot(ang*360/teeth2)
|
||||
// color("lightblue")
|
||||
// fwd(d)
|
||||
// spur_gear2d(mod=mod, teeth=teeth1, profile_shift=ps1,gear_spin=-ang*360/teeth1,helical=0);
|
||||
// Figure(3D,Med,NoAxes,VPT=[10.3822,-19.892,16.1929],VPR=[55.7,0,30.6],VPD=401.516): A interior or ring gear
|
||||
// ring_gear(mod=5, teeth=35,thickness=25,$fn=128);
|
||||
// Continues:
|
||||
// Ring gears are subject to all the usual mesh requirements: the teeth must be the same size, the pressure angles must
|
||||
// match and they must have the same helical angle. The {{gear_dist()}} function can give the center separation of
|
||||
// a ring gear and its mating spur gear. But they also have additional complications that tend to arise when the number of
|
||||
// match and they must have opposite helical angles. The {{gear_dist()}} function can give the center separation of
|
||||
// a ring gear and its mating spur gear. Ring gears have additional complications that tend to arise when the number of
|
||||
// teeth is small or the teeth counts of the ring gear and spur gear are too close together. The mating spur gear must
|
||||
// have few enough teeth so that the teeth don't interfere on the other side of the ring. Very small spur gears can interfere
|
||||
// on the tips of the ring gear's teeth.
|
||||
// Figure(2D,Med,NoAxes,VPT=[-1.16111,0.0525612,0.495977],VPD=213.382): The red regions show interference between the two gears: the 18 tooth spur gear does not fit inside the 20 tooth ring gear.
|
||||
// Figure(2D,Med,NoAxes,VPR=[0,0,0],VPT=[-1.16111,0.0525612,0.495977],VPD=213.382): The red regions show interference between the two gears: the 18 tooth spur gear does not fit inside the 20 tooth ring gear.
|
||||
// teeth1=18;
|
||||
// teeth2=20;
|
||||
// ps1=undef;
|
||||
|
@ -355,7 +362,20 @@ function _inherit_gear_thickness(thickness) =
|
|||
// fwd(d)
|
||||
// spur_gear2d(mod=mod, teeth=teeth1, profile_shift=ps1,gear_spin=-ang*360/teeth1,helical=0);
|
||||
// }
|
||||
|
||||
// Figure(3D,Med,NoAxes,VPT=[2.48983,2.10149,0.658081],VPR=[70.4,0,123],VPD=237.091): A helical ring gear (yellow) mating with the compatible spur gear (blue)
|
||||
// $fn=128;
|
||||
// teeth1=18;
|
||||
// teeth2=30;
|
||||
// ps1=undef;
|
||||
// ps2=auto_profile_shift(teeth=teeth1);
|
||||
// mod=3;
|
||||
// d = gear_dist(mod=mod, teeth1=teeth1, teeth2=teeth2,profile_shift1=ps1, profile_shift2=ps2,helical=30, internal2=true);
|
||||
// ang = 0;
|
||||
// ring_gear(mod=mod, teeth=teeth2,profile_shift=ps2,backing=4,helical=30,thickness=15);
|
||||
// zrot(ang*360/teeth2)
|
||||
// color("lightblue")
|
||||
// fwd(d)
|
||||
// spur_gear(mod=mod, teeth=teeth1, profile_shift=ps1,gear_spin=-ang*360/teeth1,helical=-30,thickness=15);
|
||||
|
||||
// Section: Gears
|
||||
|
||||
|
@ -1001,7 +1021,7 @@ module ring_gear(
|
|||
) {
|
||||
circ_pitch = _inherit_gear_pitch("ring_gear()",pitch, circ_pitch, diam_pitch, mod);
|
||||
PA = _inherit_gear_pa(pressure_angle);
|
||||
helical = _inherit_gear_helical(helical);
|
||||
helical = _inherit_gear_helical(helical); //Maybe broken???
|
||||
thickness = _inherit_gear_thickness(thickness);
|
||||
checks =
|
||||
assert(is_finite(profile_shift), "Profile shift for ring gears must be numerical")
|
||||
|
@ -1032,7 +1052,7 @@ module ring_gear(
|
|||
ar+backing
|
||||
: 2*ar - rr; // default case
|
||||
circum = 2 * PI * pr;
|
||||
twist = 360*thickness*tan(helical)/circum;
|
||||
twist = 360*thickness*tan(-helical)/circum;
|
||||
slices = default(slices, ceil(twist/360*segs(pr)+1));
|
||||
attachable(anchor,spin,orient, h=thickness, r=pr) {
|
||||
zrot(gear_spin)
|
||||
|
@ -1970,8 +1990,8 @@ module bevel_gear(
|
|||
// Example: Left Handed
|
||||
// worm(circ_pitch=8, d=30, l=50, starts=3, left_handed=true, $fn=72);
|
||||
// Example: Called as Function
|
||||
vnf = worm(circ_pitch=8, d=35, l=50, starts=2, left_handed=true, pressure_angle=20, $fn=72);
|
||||
vnf_polyhedron(vnf);
|
||||
// vnf = worm(circ_pitch=8, d=35, l=50, starts=2, left_handed=true, pressure_angle=20, $fn=72);
|
||||
// vnf_polyhedron(vnf);
|
||||
|
||||
function worm(
|
||||
circ_pitch,
|
||||
|
@ -2688,6 +2708,7 @@ function _adendum(
|
|||
mod * (1 + profile_shift);
|
||||
|
||||
|
||||
|
||||
/// Function: _dedendum()
|
||||
/// Usage:
|
||||
/// ddn = _dedendum(circ_pitch=, [clearance], [profile_shift]);
|
||||
|
|
Loading…
Reference in a new issue