Screw Maker

Need help, or want to share a macro? Post here!
Forum rules
Be nice to others! Respect the FreeCAD code of conduct!
popsmike
Posts: 2
Joined: Sat Jun 13, 2015 4:38 pm

Re: Screw Maker

Post by popsmike »

cox wrote:Welcome to the FreeCAD forum popsmike,

Just out of curiosity i googled 3.5 mm ISO2010 and I could not find any on exactly 3.5 mm.
According to some tables I found 2.5mm 3mm 4mm

Do you have spec. on it?

http://www.globalfastener.com/standards ... _2991.html
Sorry for the long delay, Im not entirely sure about the specs for these but i will do some digging to find out for you.

Many thanks for your prompt reply and I am looking forward to future use of the program.

EDIT: Sorry Just noticed the update, thanks very much for your help.
ulrich1a
Veteran
Posts: 1957
Joined: Sun Jul 07, 2013 12:08 pm

Re: Screw Maker

Post by ulrich1a »

After a long pause with other things I got some time to work on the screw maker library. Here is version 2.0.
screw_maker2_0.py.zip
Real zip-file
(32.15 KiB) Downloaded 11650 times
It should be a little bit faster. The making of the real thread is definitely faster. I could make work it on a wider range of thread diameters, see picture. The document with the shown screws has a size of 2.5 megabyte.
There may be still some issues with some types of screws or combinations of diameters and length and type of screws.
I could not test all combinations, if they produce a valid shape. Most of them should do it. Please report any issues.

I added a screw-tap in order to facilitate cutting of inner threads with real thread.
Nuts are added and two other screw-types.

I hope Shaise is able to integrate this new version in the fastener workbench. I applied the standard python way, so screw maker can be used both as macro and as a python library.
I will make a github version, but have first to learn how to make it.

Have fun
Ulrich
Attachments
More_screws_with_real_thread.png
More_screws_with_real_thread.png (155.54 KiB) Viewed 19428 times
triplus
Veteran
Posts: 9471
Joined: Mon Dec 12, 2011 4:45 pm

Re: Screw Maker

Post by triplus »

Don't have the time to try it out today but this sounds great!
User avatar
shaise
Posts: 470
Joined: Thu Jun 11, 2015 8:11 am

Re: Screw Maker

Post by shaise »

Great!

I will update Fasteners workbench with this new version.

shai
User avatar
shaise
Posts: 470
Joined: Thu Jun 11, 2015 8:11 am

Re: Screw Maker

Post by shaise »

Ulrich,

I see you have added plenty of new types, nice!
The M sizes in parentheses - does it mean they are less standard?

shai
ulrich1a
Veteran
Posts: 1957
Joined: Sun Jul 07, 2013 12:08 pm

Re: Screw Maker

Post by ulrich1a »

shaise wrote:The M sizes in parentheses - does it mean they are less standard?
Those diameters in parenthesis were regular in former german DIN-standards. Some of the ISO-standards still have them, but there those diameters are in parenthesis, with a remark, that those values are not recommended.
I left most of those values out in the former versions of screwmaker. (Also because it was less work ;) ) But there was a special request to include M3.5 in one forum post. So I thought, it would be best to reflect in screwmaker, what the standards are saying: Have them available but show their state.
One could consider to put those values at the end of the selection list. I am not sure, what would be more practically from users point.

I did not include your changes to screwmaker for the fastener workbench. I wanted to have a version for now, that is both usable as library and as macro. (As long as screwmaker/fastener workbench is not part of FreeCAD. ;) ) If your changes still allow to run screwmaker as macro, I would put them in my version too. This would allow us to have a common version with less work.

Ulrich
User avatar
shaise
Posts: 470
Joined: Thu Jun 11, 2015 8:11 am

Re: Screw Maker

Post by shaise »

Hi Ulrich,

Yes, over the versions I have added too many changes to help me use the macro. This time I will do my best to minimize the changes and move most of my code outside the screwmaker file. I will also make sure it works as a stand alone macro.
Thank you for your investment, it is extremely tedious to collect and implement so many screws with so many details.

shai
User avatar
shaise
Posts: 470
Joined: Thu Jun 11, 2015 8:11 am

Re: Screw Maker

Post by shaise »

Hi Ulrich,

I have updated the Fasteners workbench to use your V2.0 Screw Maker.
This time, I tried to do as little as possible changes to your code. The only change is did is the option that CreateScrew will return a only a shape, rather then generate a UI object. The file can still work as a stand-alone FreeCAD macro. You can find the revised file at github:
https://github.com/shaise/FreeCAD_Faste ... w_maker.py
As you have added Nuts to the macro, I have deprecated my own nut version.

Thank you so very much for you work!

shai
triplus
Veteran
Posts: 9471
Joined: Mon Dec 12, 2011 4:45 pm

Re: Screw Maker

Post by triplus »

I did a few quick tests and can confirm making threads is faster. I like the new additions like threaded nuts.

I noticed using thread on nuts does produce a bit unusually formed first/last turn of the thread. Is that intended behaviour?
ulrich1a
Veteran
Posts: 1957
Joined: Sun Jul 07, 2013 12:08 pm

Re: Screw Maker

Post by ulrich1a »

triplus wrote:I like the new additions like threaded nuts.
Thanks!
triplus wrote:I noticed using thread on nuts does produce a bit unusually formed first/last turn of the thread. Is that intended behaviour?
Most nuts have a chamfer between 30° to 45° at the inner thread. This chamfer cuts some material from the first/last turn.
You may test this and create a nut without thread. Then create a screw tap of approriate size and length and make the inner thread yourself. (The screw tap is the last item in the list of screws standards.) If everything is allright, it should create the same geometry as the nut created with real thread from the macro.

Ulrich
Post Reply