Skip to content

Commit

Permalink
Fix hex socket head screw length
Browse files Browse the repository at this point in the history
Fixes incorrect threaded length for screws with length l larger than threshold threading length L
  • Loading branch information
Yanai1701 authored and berndhahnebach committed Oct 19, 2020
1 parent 28e2234 commit dd53a1d
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions openscad/hex_socket/hex_socket.scad
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
*/
module hex_socket1(d1,d2,b1,b2,b3,k_max,s,t,L,h_max,l){
b = (l <= L) ? l - k_max - h_max :
b = (l <= L) ? l - k_max - h_max :
l < 125 ? b1 :
l < 200 ? b2 :
b3;
Expand All @@ -43,7 +43,7 @@ module hex_socket1(d1,d2,b1,b2,b3,k_max,s,t,L,h_max,l){

module hex_socket2(d1,d2,b,k,s,t_min,L,l){
h_unthreaded = (l<= L) ? 0 : l - b;
h_threaded = (l<= L) ? l : l - b;
h_threaded = (l<= L) ? l : b;

BOLTS_check_dimension_positive(h,"l too short");

Expand All @@ -59,4 +59,3 @@ module hex_socket2(d1,d2,b,k,s,t_min,L,l){
translate([0,0,-k]) BOLTS_hex_socket_neg(t_min,s);
}
}

0 comments on commit dd53a1d

Please sign in to comment.