JohK / nutsnbolts

A OpenSCAD library that allows for simple creation of nuts and bolts and respective nut catches and screw holes
GNU General Public License v3.0
267 stars 41 forks source link

M10 hole_threaded makes too small hole (about M8 dimensions?) #20

Closed hsuonsivu closed 2 years ago

hsuonsivu commented 2 years ago

I seem to get too small hole with hole_threaded. I use difference from object with

translate([0,0,bodyh+1]) hole_threaded("M10", l=40, thread="modeled");

I printed a bolt and screw with the following: include <nutsnbolts/materials.scad>; include <nutsnbolts/cyl_head_bolt.scad>;

$fn=120;

screw("M10x20", thread="modeled"); //

translate([20,0,10]) nut("M10", thread="modeled"); //

Resulting bolt seems to fit real M10 nut, but printed nut is way too small, and will not fit printed bolt, not even forced.

M10 bolts and nuts I had in hand has outside diameter about 9.74 to 9.83 and nut inner diameter 8.44 to 8.55 mm. Standard should be 10mm. Printed M10 is 9.20 and 7mm so measurements are too small, and printed nut and bolt do not fit each other at all.

We compared with nuts and bolts printed with blender tools, and those fit fine, after fixing the pitch of M10 to 1.5, seems to be wrong there as well, but diameters are ok.

JohK commented 2 years ago

Hmm. The library's intent was to enable better documentation of bolt properties in code, not to print bolts and nuts. (From a mechanical engineering viewpoint: no one ever manufactures their own standard bolts, but you use them all the time in designs and need to document which ones you chose for your BOM.)

The standards give absolute minimum and maximum dimensions for thread diameters if I remember correctly... yet the database of this library only holds a single value. I doubt that for real hardware that is the case for inner and outer threads. This is why for 3-D printing I introduced the clearance parameters, because in the end everybodys printer is calibrated differently anyways...

It would be quite an extensive fix to add real thread modelling with correct dimensions ( + a lot of testing) as an afterthought, to have it work automatically for printed threads.

Anyways, currently the clearances are not respected for modelled threads (nut, hole_threaded). For your application the simplest solution may be to implement those - if you do, please send me a patch and I will incorporate the feature.

I hope this helps.

voxpelli commented 2 years ago

If you want to print threads, look at eg: https://github.com/rcolyer/threads-scad