GD&T Workbench for FreeCAD
Forum rules
Be nice to others! Respect the FreeCAD code of conduct!
Be nice to others! Respect the FreeCAD code of conduct!
GD&T Workbench for FreeCAD
Hi all,
During the development of my final master's work in university I developed a module to solve the problem of Geometric Dimensioning and Tolerancing (GD&T).
Abstract
The project is aimed at the development of a labeling software module for Geometric Dimensioning and Tolerancing (GD&T) in 2D and 3D technical drawings. The main contributions of this software are:
Allows the GD&T information to be added to the design itself, thus linking design, manufacturing and quality specifications.
Implements the ISO16792 standard for both 2D and 3D parts.
Incorporates a homogeneous graphical interface and integrated with the technical design tools and 3D.
There is no precedent developed as free software.
The implementation of the software is done as a module of the parametric modeling free software application FreeCAD. This is a multiplatform project since the development of the module is done with Python and FreeCAD has compilations for multiple Operating Systems.
GitHub repository: https://github.com/juanvanyo/FreeCAD-GDT
I add some screenshots:
During the development of my final master's work in university I developed a module to solve the problem of Geometric Dimensioning and Tolerancing (GD&T).
Abstract
The project is aimed at the development of a labeling software module for Geometric Dimensioning and Tolerancing (GD&T) in 2D and 3D technical drawings. The main contributions of this software are:
Allows the GD&T information to be added to the design itself, thus linking design, manufacturing and quality specifications.
Implements the ISO16792 standard for both 2D and 3D parts.
Incorporates a homogeneous graphical interface and integrated with the technical design tools and 3D.
There is no precedent developed as free software.
The implementation of the software is done as a module of the parametric modeling free software application FreeCAD. This is a multiplatform project since the development of the module is done with Python and FreeCAD has compilations for multiple Operating Systems.
GitHub repository: https://github.com/juanvanyo/FreeCAD-GDT
I add some screenshots:
Last edited by juanvanyo on Fri Apr 28, 2017 11:30 am, edited 1 time in total.
Re: GD&T Workbenk for FreeCAD
Wow, looks great. Have no clue how to use it More to learn. Thanks
Need help? Feel free to ask, but please read the guidelines first
Re: GD&T Workbenk for FreeCAD
Hi,
looks very interesting. good job
Does it work on both 0.16 and 0.17?
do you have a short tutorial or a short workflow explanation?
on both I have this error while trying to create an annotation plane :
looks very interesting. good job
Does it work on both 0.16 and 0.17?
do you have a short tutorial or a short workflow explanation?
on both I have this error while trying to create an annotation plane :
Code: Select all
Running the Python command 'dd_annotationPlane' failed:
Traceback (most recent call last):
File "/Volumes/doc/Thierry/Library/Preferences/FreeCAD/Mod/FreeCAD-GDT/annotationPlane.py", line 38, in Activated
showGrid()
File "/Volumes/doc/Thierry/Library/Preferences/FreeCAD/Mod/FreeCAD-GDT/GDT.py", line 230, in showGrid
FreeCADGui.Snapper.show()
File "/Applications/FreeCAD/FreeCAD 016.app/Contents/Mod/Draft/DraftSnap.py", line 1193, in show
self.setTrackers()
File "/Applications/FreeCAD/FreeCAD 016.app/Contents/Mod/Draft/DraftSnap.py", line 1221, in setTrackers
self.grid = DraftTrackers.gridTracker()
File "/Applications/FreeCAD/FreeCAD 016.app/Contents/Mod/Draft/DraftTrackers.py", line 782, in __init__
self.reset()
File "/Applications/FreeCAD/FreeCAD 016.app/Contents/Mod/Draft/DraftTrackers.py", line 836, in reset
self.update()
File "/Applications/FreeCAD/FreeCAD 016.app/Contents/Mod/Draft/DraftTrackers.py", line 793, in update
if i/float(self.mainlines) == i/self.mainlines:
float division by zero
Re: GD&T Workbenk for FreeCAD
I think there is a problem with the attributes of the grid, which I try to get from the configurations of the Part module. Maybe if you enter the Preferences configuration of the Part module, the problem will be solved.nemesis wrote:Hi,
looks very interesting. good job
Does it work on both 0.16 and 0.17?
do you have a short tutorial or a short workflow explanation?
on both I have this error while trying to create an annotation plane :Code: Select all
Running the Python command 'dd_annotationPlane' failed: Traceback (most recent call last): File "/Volumes/doc/Thierry/Library/Preferences/FreeCAD/Mod/FreeCAD-GDT/annotationPlane.py", line 38, in Activated showGrid() File "/Volumes/doc/Thierry/Library/Preferences/FreeCAD/Mod/FreeCAD-GDT/GDT.py", line 230, in showGrid FreeCADGui.Snapper.show() File "/Applications/FreeCAD/FreeCAD 016.app/Contents/Mod/Draft/DraftSnap.py", line 1193, in show self.setTrackers() File "/Applications/FreeCAD/FreeCAD 016.app/Contents/Mod/Draft/DraftSnap.py", line 1221, in setTrackers self.grid = DraftTrackers.gridTracker() File "/Applications/FreeCAD/FreeCAD 016.app/Contents/Mod/Draft/DraftTrackers.py", line 782, in __init__ self.reset() File "/Applications/FreeCAD/FreeCAD 016.app/Contents/Mod/Draft/DraftTrackers.py", line 836, in reset self.update() File "/Applications/FreeCAD/FreeCAD 016.app/Contents/Mod/Draft/DraftTrackers.py", line 793, in update if i/float(self.mainlines) == i/self.mainlines: float division by zero
Tonight I will try to make a short explanation of the workflow.
Re: GD&T Workbenk for FreeCAD
Hi,
your images looks very impressive.
My problem: after downloading to ~/.FreeCAD/Mod and unzip the file a directory FreeCAD-GDT-master with all your files is in Mod. After restarting FreeCAD I can't see a WB "GD&T
There are a lot of other WB I installed in Mod and they work correct. So, I can't find my mistake.
My configuration:
OS: Ubuntu 16.04.2 LTS
Word size of OS: 64-bit
Word size of FreeCAD: 64-bit
Version: 0.17.10950 (Git)
Build type: None
Branch: master
Hash: 6368b2f822cf838ee6c50ebf62480ff86c214317
Python version: 2.7.12
Qt version: 4.8.7
Coin version: 4.0.0a
OCC version: 7.1.0
your images looks very impressive.
My problem: after downloading to ~/.FreeCAD/Mod and unzip the file a directory FreeCAD-GDT-master with all your files is in Mod. After restarting FreeCAD I can't see a WB "GD&T
There are a lot of other WB I installed in Mod and they work correct. So, I can't find my mistake.
My configuration:
OS: Ubuntu 16.04.2 LTS
Word size of OS: 64-bit
Word size of FreeCAD: 64-bit
Version: 0.17.10950 (Git)
Build type: None
Branch: master
Hash: 6368b2f822cf838ee6c50ebf62480ff86c214317
Python version: 2.7.12
Qt version: 4.8.7
Coin version: 4.0.0a
OCC version: 7.1.0
Re: GD&T Workbenk for FreeCAD
Problem solved with my last update. It was due to a conflict with the Draft module. You may have to enter the Draft module preferences (Grid and snapping) and put the following values: Main lines every 10, Grid size 100.nemesis wrote:Hi,
looks very interesting. good job
Does it work on both 0.16 and 0.17?
do you have a short tutorial or a short workflow explanation?
on both I have this error while trying to create an annotation plane :Code: Select all
Running the Python command 'dd_annotationPlane' failed: Traceback (most recent call last): File "/Volumes/doc/Thierry/Library/Preferences/FreeCAD/Mod/FreeCAD-GDT/annotationPlane.py", line 38, in Activated showGrid() File "/Volumes/doc/Thierry/Library/Preferences/FreeCAD/Mod/FreeCAD-GDT/GDT.py", line 230, in showGrid FreeCADGui.Snapper.show() File "/Applications/FreeCAD/FreeCAD 016.app/Contents/Mod/Draft/DraftSnap.py", line 1193, in show self.setTrackers() File "/Applications/FreeCAD/FreeCAD 016.app/Contents/Mod/Draft/DraftSnap.py", line 1221, in setTrackers self.grid = DraftTrackers.gridTracker() File "/Applications/FreeCAD/FreeCAD 016.app/Contents/Mod/Draft/DraftTrackers.py", line 782, in __init__ self.reset() File "/Applications/FreeCAD/FreeCAD 016.app/Contents/Mod/Draft/DraftTrackers.py", line 836, in reset self.update() File "/Applications/FreeCAD/FreeCAD 016.app/Contents/Mod/Draft/DraftTrackers.py", line 793, in update if i/float(self.mainlines) == i/self.mainlines: float division by zero
Re: GD&T Workbenk for FreeCAD
I think your issue has been fixed with my latest update. Thanks for your interest.akredd wrote:Hi,
your images looks very impressive.
My problem: after downloading to ~/.FreeCAD/Mod and unzip the file a directory FreeCAD-GDT-master with all your files is in Mod. After restarting FreeCAD I can't see a WB "GD&T
There are a lot of other WB I installed in Mod and they work correct. So, I can't find my mistake.
My configuration:
OS: Ubuntu 16.04.2 LTS
Word size of OS: 64-bit
Word size of FreeCAD: 64-bit
Version: 0.17.10950 (Git)
Build type: None
Branch: master
Hash: 6368b2f822cf838ee6c50ebf62480ff86c214317
Python version: 2.7.12
Qt version: 4.8.7
Coin version: 4.0.0a
OCC version: 7.1.0
Re: GD&T Workbenk for FreeCAD
Operation of the module:
When doing a GD&T labeling, the first thing to do is to define an annotation plane on which the annotations we make will be painted. To do this, first select a face of the piece and click the command on the toolbar add annotation plane. This will define a plane on that face and we can also apply an offset to place our annotation plane to the height we want in parallel on the selected face. Defining an annotation plane.
The next step we must do is to create a datum reference or a geometric tolerance. Although it is important to note that if the first thing to be created is a geometric tolerance, it can not contain any datum system since there will not be any created yet. However, this can be added later by modifying the geometric tolerance from the inventory of GD&T elements.
In any case, when creating a datum reference or a geometric characteristic, the user must choose some parameters that will define the element to be created. These include the annotation plane on which the annotation will be represented. Everything followed should select a point on the plane. Point on which will start the representation of the frame that will encapsulate the data of our annotation.
In addition, at any time, you can create a datum system with the datum reference elements that have been created and this system can be applied to the geometric tolerances that we consider appropriate. This will indicate that said geometric tolerance will be applied to the face or faces corresponding to the annotation with respect to the datum references that make up the associated datum system.
Subsequently, if you want to apply a datum reference or a geometric tolerance to a face or faces that already have an annotation associated with it, this module will automatically detect which annotation is and it will add the new element to that annotation.
Therefore, the running of our module could be summarized in that we have to add geometric tolerances to our design but in order to carry this out, we would first have to create different elements like annotation planes to place our annotation in the desired place, or Datum references and datum systems to provide necessary information to our geometric tolerances. So we have to create different elements until we have our piece completely labeled with all the geometric tolerances that we need to indicate.
Commands:
When doing a GD&T labeling, the first thing to do is to define an annotation plane on which the annotations we make will be painted. To do this, first select a face of the piece and click the command on the toolbar add annotation plane. This will define a plane on that face and we can also apply an offset to place our annotation plane to the height we want in parallel on the selected face. Defining an annotation plane.
The next step we must do is to create a datum reference or a geometric tolerance. Although it is important to note that if the first thing to be created is a geometric tolerance, it can not contain any datum system since there will not be any created yet. However, this can be added later by modifying the geometric tolerance from the inventory of GD&T elements.
In any case, when creating a datum reference or a geometric characteristic, the user must choose some parameters that will define the element to be created. These include the annotation plane on which the annotation will be represented. Everything followed should select a point on the plane. Point on which will start the representation of the frame that will encapsulate the data of our annotation.
In addition, at any time, you can create a datum system with the datum reference elements that have been created and this system can be applied to the geometric tolerances that we consider appropriate. This will indicate that said geometric tolerance will be applied to the face or faces corresponding to the annotation with respect to the datum references that make up the associated datum system.
Subsequently, if you want to apply a datum reference or a geometric tolerance to a face or faces that already have an annotation associated with it, this module will automatically detect which annotation is and it will add the new element to that annotation.
Therefore, the running of our module could be summarized in that we have to add geometric tolerances to our design but in order to carry this out, we would first have to create different elements like annotation planes to place our annotation in the desired place, or Datum references and datum systems to provide necessary information to our geometric tolerances. So we have to create different elements until we have our piece completely labeled with all the geometric tolerances that we need to indicate.
Commands:
- Add Annotation Plane Add Datum Feature Add Datum System Add Geometric Tolerance Inventory of the elements of GD&T
Re: GD&T Workbenk for FreeCAD
This is awesome. Great work Juan!
It's a pity though that this info will surely be lost at STEP export as I doubt FreeCAD's STEP exporter supports this.
It's a pity though that this info will surely be lost at STEP export as I doubt FreeCAD's STEP exporter supports this.
Re: GD&T Workbenk for FreeCAD
Actually occ step importer does super it, and i suppose exporter too. So with some work it should be possible to include it in step. But don't know if it is somehow possible to make this available for modules if there is no gd&t data type in the part workbench, where the exporter lives.NormandC wrote:It's a pity though that this info will surely be lost at STEP export as I doubt FreeCAD's STEP exporter supports this.
https://www.opencascade.com/comment/19633
Great work by the way!