Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Geometry Check on BOP #129

Open
easyw opened this issue Dec 2, 2017 · 6 comments
Open

Geometry Check on BOP #129

easyw opened this issue Dec 2, 2017 · 6 comments

Comments

@easyw
Copy link
Owner

easyw commented Dec 2, 2017

Hi @Shackmeister and all developers,
I've just updated the 'cq_cad_tools.py' adding two new functions:

  1. checkUnion(doc)
  2. checkBOP(shape)

and a source file to run these functions (I included all the functions in the file so to be able to run it easily)
checkBOP-example.py
I attached here also a wrong STEP model, not correctly union-ed and with wrong geometries to make some tests.
resistor-wrong-BOP.zip
uploaded also on the repo...

It is suggested to generate/export a STEP model, then close the file generator and import the STEP file;
then run the checkUnion function to see if the STEP file is correcty union-ed in a single part and run the checkBOP function to see if there are errors on the STEP shape.

This is going to be a quite robust check on the generated files... still in some case I found BOP check is not perfect, but it is for sure much better than the previous state.

Requirements:

  • FreeCAD 0.17 12703 or later
@Shackmeister
Copy link
Contributor

this sounds cool :D can you please try and add this in the new Resistor repo? :) would be nice with an example

@easyw
Copy link
Owner Author

easyw commented Dec 2, 2017

@Shackmeister
now the 'Resistor_SMD' repo has a Union & BOP check
NB the BOP check is working ONLY with FC0.17 12703 or later (it will be skipped for previous FC releases)

@poeschlr
Copy link
Contributor

poeschlr commented Dec 2, 2017

This means my freecad is too old. (For some reason the last build for fedora was 48 days ago.)
Well i can use my ubuntu vm. Maybe there is a newer version for this operating system.

@easyw
Copy link
Owner Author

easyw commented Dec 2, 2017

@poeschlr
for BOP check this commit should be enough
FreeCAD/FreeCAD@2a6a58e
but we had some issue with CQ fillet in previous FC0.17 releases...
may be your release could work fine...
you can simple test BOP check with the example files I linked above

@easyw
Copy link
Owner Author

easyw commented Dec 2, 2017

a working models generator with Union and BOP check is ready here:
https://github.com/easyw/kicad-3d-models-in-freecad/tree/master/cadquery/FCAD_script_generator/Resistor_SMD

@poeschlr
Copy link
Contributor

poeschlr commented Dec 3, 2017

I tested it with your example file and my freecad version indeed discovered that the resistor is invalid.
So i included this test in my updated phoenix contact scripts.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants