author | Michael Krelin <hacker@klever.net> | 2018-08-21 18:00:15 (UTC) |
---|---|---|
committer | Michael Krelin <hacker@klever.net> | 2018-08-21 18:00:15 (UTC) |
commit | eb49701c13f76640936e7a2a7a138bd92617b147 (patch) (side-by-side diff) | |
tree | e8e4629a861c5e9bfc15a5c6d09e471aa2bc1b38 | |
parent | fc213f6b29f62795ce33d0e0acdea1e6a6b0fffb (diff) | |
download | extrudery-eb49701c13f76640936e7a2a7a138bd92617b147.zip extrudery-eb49701c13f76640936e7a2a7a138bd92617b147.tar.gz extrudery-eb49701c13f76640936e7a2a7a138bd92617b147.tar.bz2 |
adjustments to screw mount depth
-rw-r--r-- | another.scad | 15 |
1 files changed, 11 insertions, 4 deletions
diff --git a/another.scad b/another.scad index 6afa9ef..6ef7299 100644 --- a/another.scad +++ b/another.scad @@ -6,16 +6,17 @@ $fs=0.0125; use <pushfittery.scad>; include <pushfit_data.scad>; module the_extruder( // motor properties gearbox_d = 36, mount_d = 28, // the distance between opposite mounting holes mounthole_depth = 5, + mounthole_min_depth = 3, mounthole_max_depth = 4, protrusion_d = 22, protrusion_h = 2.2, // the dimensions of the protrusion on top of gearbox bore_d = 8, bore_l = 17.6, bore_dd = 7, // pulley properties pulley_d = 11.5, pulley_h=10, pulley_elevation = 1, // pulley elevation above the protrusion teeth_elevation = 7.5, // distance from the bottom of the pulley to its teeth filament_offset = (8.25-(3.0+3.5)/2) - 11.5/2 + 1.75/2, @@ -57,16 +58,18 @@ module the_extruder( protrusion_tolerance_v=.5, // vertical tolerance for the motor protrusion mount_screw_d_tolerance=.4, idler_v_tolerance=.5, knob_bore_d_tolerance=.6, st_nut_h_tolerance=.2, st_nut_d_tolerance=.2,/* TODO: make it st_nut_w_tolerance */ st_screw_d_tolerance=.5, + min_z_shell = 4*layer_height, // the very minimal shell thickness along z-axis. + what="lever", // lever|body|knob|springpad|* left=false, vitamins = true, supports = false, bridges = true, tensioner = true, debug = false ) { fnd = 2*PI; fnr = 2*fnd; @@ -75,20 +78,24 @@ module the_extruder( lever_shell = mount_screwhead_h+0.5; lever_thickness=max(spring_d+spring_d_clearance+layer_height*8,idler_h+idler_v_tolerance+2*lever_shell); lsd = idler_d-idler_clearance*2; longwing=gearbox_d/2+spring_d/2+lsd/2; h_ = (pulley_d+idler_d)/(2*sqrt(2)); ri = sqrt( pow(h_,2) + pow(mount_d/2-h_,2) ); spring_dl = idler_travel*longwing/ri; + mount_min_depth = mounthole_min_depth ? mounthole_min_depth : mounthole_depth-1; + mount_max_depth = mounthole_max_depth ? mounthole_max_depth : mounthole_depth+1; filament_elevation=protrusion_h+pulley_elevation+teeth_elevation; ls_z = filament_elevation; // leverspace mid-z - body_h = max(protrusion_h+bore_l,mount_screw_l-mounthole_depth/2+mount_screwhead_h,ls_z*2); ls_h = lever_thickness+lever_v_clearance; // leverspace height + mount_depth = mount_screw_l - (ls_z+ls_h/2+min_z_shell); + body_h = max(protrusion_h+bore_l,mount_screw_l-mount_depth+mount_screwhead_h+min_z_shell,ls_z*2); + echo("mount depth",mount_depth); module mirrorleft() { mirror([left?0:1,0,0]) children(); } module place_idler() { rotate([0,0,45]) translate([(pulley_d+idler_d)/2,0,0]) children(); @@ -283,22 +290,22 @@ module the_extruder( }//translate rotate translate rotate translate }//union (first child of difference) // protrusion translate([0,0,-1]) cylinder(d=protrusion_d+protrusion_tolerance_h,h=protrusion_h+protrusion_tolerance_v+1,$fn=fnd*(protrusion_d+protrusion_tolerance_h)); // mount screw holes for(zr=[0:90:359]) rotate([0,0,zr]) translate([mount_d/2,0,0]) { - translate([0,0,mount_screw_l-mounthole_depth/2-(bridges?layer_height:-epsilon)]) + translate([0,0,mount_screw_l-mount_depth-(bridges?layer_height:-epsilon)]) mirror([0,0,1]) cylinder(d=mount_screw_d+mount_screw_d_tolerance, - h=mount_screw_l-mounthole_depth/2+1, + h=mount_screw_l-mount_depth+1, $fn=fnd*(mount_screw_d+mount_screw_d_tolerance)); - translate([0,0,mount_screw_l-mounthole_depth/2]) + translate([0,0,mount_screw_l-mount_depth]) cylinder(d=mount_screwhead_d,h=body_h+1,$fn=fnd*mount_screwhead_d); }//for // pushfit translate([0,0,filament_elevation]) rotate([0,0,45]) translate([pulley_d/2+filament_offset,0,0]) rotate([-90,0,0]) translate([0,0,mount_d/sqrt(2)/2+mount_screw_d+epsilon]) rotate([0,0,180]) { |