Making hole feature configurable

Have some feature requests, feedback, cool stuff to share, or want to know where FreeCAD is going? This is the place.
Forum rules
Be nice to others! Read the FreeCAD code of conduct!
Post Reply
chrisb
Veteran
Posts: 54150
Joined: Tue Mar 17, 2015 9:14 am

Making hole feature configurable

Post by chrisb »

We had a discussion about the PartDesign hole feature in the german forum. It seems that all configuration options are defined in the C++ source code. The structure there seems to be very clear but a user cannot change it without compiling FreeCAD.

It seems to be very sensible to have a separate file containing this information. The currently implemented data is incomplete and almost for sure has to be. Because implementing all different tolerance lines of the ISO might make it hard to use and even then any non standard part needed for a design would be missing.

A first challenge would be, which format to use. A second to find someone to implement it. It might be a task for the eager Brazilian programming group; sorry I cannot find the topic.

We have a new member in the german forum who has access to the standard documents and is willing to contribute to the contents.
eivindkvedalen wrote:Eivind
This is your baby - and it's a nice one! - what do you think?
A Sketcher Lecture with in-depth information is available in English, auf Deutsch, en français, en español.
User avatar
NormandC
Veteran
Posts: 18589
Joined: Sat Feb 06, 2010 9:52 pm
Location: Québec, Canada

Re: Making hole feature configurable

Post by NormandC »

chrisb wrote: Thu Aug 02, 2018 5:24 pm It seems to be very sensible to have a separate file containing this information.
That's a good idea. In the commercial program I use at work, it's done that way: the hole specs are in a simple tabulated text file that you can edit.

But the Hole parameters are so complex, I wonder if it would be possible.
ulrich1a
Veteran
Posts: 1957
Joined: Sun Jul 07, 2013 12:08 pm

Re: Making hole feature configurable

Post by ulrich1a »

NormandC wrote: Thu Aug 02, 2018 7:26 pm But the Hole parameters are so complex, I wonder if it would be possible.
There exist a DIN standard for hole parameters that tries just to do this. The data are already available in the FreeCAD sources: https://github.com/FreeCAD/FreeCAD/blob ... andards.py

This is the formerly hole feature programmed in python from Jan Rheinländer. Though these data are from 2012 and have to be checked.

The current hole feature in FreeCAD uses a programmatic approach to calculate hole parameters for example for cap screws. This does produce unusable holes and can be considered as a bug.

Ulrich
eivindkvedalen
Posts: 602
Joined: Tue Jan 29, 2013 10:35 pm

Re: Making hole feature configurable

Post by eivindkvedalen »

chrisb wrote: Thu Aug 02, 2018 5:24 pm
eivindkvedalen wrote:Eivind
This is your baby - and it's a nice one! - what do you think?
If we can tabulate each and every entry, that would be nice, and I don't mind changing the code (either myself, or someone else). This could be as easy as just using a text file.

Eivind
chrisb
Veteran
Posts: 54150
Joined: Tue Mar 17, 2015 9:14 am

Re: Making hole feature configurable

Post by chrisb »

My proposal would be to handle this similar to the Path's tooltable.
A Sketcher Lecture with in-depth information is available in English, auf Deutsch, en français, en español.
akredd
Posts: 71
Joined: Wed Mar 19, 2014 8:31 pm
Location: D-02733 Cunewalde

Re: Making hole feature configurable

Post by akredd »

chrisb wrote: Thu Aug 02, 2018 5:24 pm We have a new member in the german forum who has access to the standard documents and is willing to contribute to the contents.
Tht's me.
ulrich1a wrote: Thu Aug 02, 2018 8:10 pm There exist a DIN standard for hole parameters that tries just to do this. The data are already available in the FreeCAD sources: https://github.com/FreeCAD/FreeCAD/blob ... andards.py

This is the formerly hole feature programmed in python from Jan Rheinländer. Though these data are from 2012 and have to be checked.
I will have a look at that code. I hope, I can read it (I'm not a programmer - more a user). Than I can check the DIN and ISO if these standards are available for me (I'm quiet shure, they are). But I can answer not till next week.

Andreas
akredd
Posts: 71
Joined: Wed Mar 19, 2014 8:31 pm
Location: D-02733 Cunewalde

Re: Making hole feature configurable

Post by akredd »

I had a first look at some Standards. There are changes meanwhile, so that we should think indeed think about external tables...
DIN 13-1/1999 seams to be up to date.
DIN 74/2003 is up to date
DIN 76-2 I have not found jet, but run-outs and undercuts are also in DIN 76-1/2016. That is a very new standard.
DIN 974-1/1991 is replaced by DIN 974-1/2008. Row 3 is deleted because the according Standard DIN 7980 doesn't exist any more.
ISO 273 and 15065 I must search and the values of DIN 76-2 i couldn't confirm (must search that standard).

There is an other thread in the Open discussion forum: https://forum.freecadweb.org/viewtopic.php?f=8&t=28798
We should combine both affords - creating a Library WB and make it configurable. At work we use - with Creo - from Part Solution. There are most Standards and Standard Parts described in tables. Have a look here: https://partsolutions.com/partsolutions/.
I try to make some screenshot next days as an example.

Andreas

PS: I found DIN 76-1, -2 and -3. It seems that there is a small mistake in the code of Standards.py at line 44. There it should be "DIN 76-1". Part 2 of that standard deals with pipe thread according to DIN ISO 228-1 and part 3 deals with metric trlpezoidal screw threads etc. These two parts surely not the first thing we need. ISO 273 i found as DIN EN 20273 as mentioned in the code as alias. 1992 is up to date. DIN EN ISO 15065 from 2005 is up to date too.
Post Reply