// fourbar.scad // (c) Simon Brooke 2025; CC-BY-SA include include include include module fourbar_leg(length=1000, chord=100, long_skew=30, lat_skew=30) { h = length * cos(lat_skew) * cos( long_skew); w = length * sin( lat_skew); d = length * sin( long_skew); translate([0, 0-w, 0]) { // upper pivot needs a complex trig transformation! translate([d - (chord/2), w, h + chord]) rotate([0, 90+long_skew, 0]) color("black") cylinder(h=chord, r=12); // lower pivot: translate([0 - chord, 0, (chord/2 * sin(long_skew))]) rotate([0, 90+long_skew, 0]) color("black") cylinder(h=chord, r=12); // aerofoil section sskew([0, long_skew, 0, 0, 0, 0]) rotate([lat_skew, 0, 180]) color("black") airfoil(h=length, L=chord); } } module loawer_bar_end_knuckle(chord=100, pivot_radius=12, rise=8) { l_body=chord * 1.5; w_body=pivot_radius * 2.5; h_axis=pivot_radius * 2.75; difference() { union () { translate([l_body/2, w_body/2, h_axis]) rotate([0, 90, 0]) cyl(h=l_body, r=w_body/2, rounding=5); translate([l_body/2, w_body/2, h_axis/2]) cuboid([l_body, w_body, h_axis], rounding=5, except=TOP); // bulge for wheel axle; the fork insertion end of // a lefty axle is 25mm diameter translate([chord * 1.25, w_body/2, 0]) rotate([90, 0, 0]) cyl(h=w_body, r=25, rounding=5); // fairing for this translate([chord * 1.25, w_body/2, -7.5]) rotate([80, 0, 270]) prismoid([w_body, 35], [w_body, 10], rounding=5, h=l_body/2); } translate([ chord*0.25, -1, pivot_radius * 3]) cube([chord, pivot_radius * 4, pivot_radius * 4]); // scoop for leg-bottom knuckle to rotate within translate([ chord*0.25, w_body/2, h_axis]) rotate([0, 90, 0]) cylinder(h=chord, r=pivot_radius * 1.3); // through hole for pivot axle translate([-1, w_body/2, h_axis]) rotate([0, 90, 0]) cylinder(h=l_body+2, r=pivot_radius/3); // through hole for wheel axle translate([chord * 1.25, w_body +1, 0]) rotate([90, 0, 0]) cylinder(h=w_body-5, r=12.5); } // airfoil stub to be epoxied into the lower bar of // the linkage translate([(chord * 1.25) - 1, 5 - chord, 0]) rotate([90-rise, 0, 180]) airfoil(h=chord, L=chord-2); // root reinforcement for the above translate([chord * 1.25, 5 - chord/3, 9]) rotate([90, 0, 180]) airfoil(h=chord/3, L=chord); translate([(chord * .75), 0, 10]) rotate([90, 0, 0]) prismoid([chord -1, 6], [chord -2, 0], h=(chord/3)); } module fourbar_axle_half( length, chord, long_skew) { shoulder=650; lat_skew=30; rise=8; // I've got something wrong in computing the half-lower-bar // length, and I don't know what. fudge=0; w = ((length * sin(lat_skew) ) + ( shoulder / 2)); l_hlb= w * (1/cos(rise)) + fudge; v_offset=l_hlb * sin(rise); echo("long_skew", long_skew); translate([0, 0, 0 - v_offset]) rotate([90-rise, 0, 180]) color("black") airfoil(h=l_hlb, L=chord); // lower knuckle translate([(0 - (chord*1.25)), l_hlb * cos(rise), 30]) rotate([0, long_skew, 0]) color("black") loawer_bar_end_knuckle(chord, 12, rise); // wheel translate([-50, l_hlb + 72, -40]) rotate([270, 0, 0]) wheel(iso=451); // brake disk translate([-50, l_hlb + 35, -40]) color("silver") rotate([90, 0, 0]) cylinder(h=1.5, r=75); // brake caliper } module fourbar(length=1000, chord=100, long_skew=30, lat_skew=30, shoulder=650) { w = (length * sin( lat_skew)) + ( shoulder / 2); translate([0, 0-(shoulder/2), 0]) fourbar_leg( length, chord, long_skew, lat_skew); translate([0, (shoulder/2), 0]) mirror([0, 1, 0]) fourbar_leg(length, chord, long_skew, lat_skew); fourbar_axle_half(w, chord, long_skew); mirror([0, 1, 0]) fourbar_axle_half(w, chord, long_skew); } translate([-125, 0, 0]) color("blue") loawer_bar_end_knuckle(); translate([0, 77, 0]) wheel(); translate([0, 40, 0]) color("silver") rotate([90, 0, 0]) cylinder(h=1.5, r=75); // fourbar(); // fourbar_axle_half(1000,100, 30);