Development of a fairly advanced Freecad plugin/workbench/module

Need help, or want to share a macro? Post here!
Forum rules
Be nice to others! Respect the FreeCAD code of conduct!
Post Reply
Adouglas
Posts: 9
Joined: Wed Aug 31, 2016 9:37 pm

Development of a fairly advanced Freecad plugin/workbench/module

Post by Adouglas »

Hey everyone, I am trying to investigate making a module for freecad that does a few things associated with a new digital fabrication tool I am involved with developing.

I have been investigating Fusion 360 but would greatly prefer to put the development time and effort into using open source software. The thing I I have never been able to actually use Freecad for modelling, due to lack of sophistication and bugs. I could never even get the path workbench working. That's why I spent so much time with fusion, and investigating it's api to do what I need to do.

I need to : Import, analyze and divide the model into sections that only contain surfaces that can be reached by a selection of end mills. They just have to be thin enough, but no thinner than necessary for the tool to reach. I have a lot of ideas on how to do this by creating the relevant point arrays and vectors and things, but it needs work. There are some details I am skipping here.

Then the model surfaces and solids needs to be sliced with various planes.

Then, probably the hardest part, I need to essentially implement a system that does fully automatic 3d tool path generation to produce the relevant surfaces, with rest milling. There are too many layers to program manually. Rest milling is a process where basically you do as much as you can with the largest tool in your set, then move to the smaller tool, and so on, until you have used all the tools. It uses the larger tools to remove material wherever they can reach. This is simpler than it sounds, I believe. The industry has not done it more because they have different priorities than because it is so hard. There are a lot of details that need to be dealt with , though.

I fear the documentation and state of development re features and bugs may not be enough in FreeCAD. For fusion, it is pretty good as far as I have been able to tell. For freecad I have already run aground; for fusion, I can go read up on the API right now and proceed with understanding and doing things, but freecad seems to have no such well written introductions. It also remains a mystery to me why the path workbench seems so non functional, given the amount of work that seems to have gone into it; I can't have the same thing happen with my project.

Is FreeCAD ready for this or should I submit to autodesk?
chrisb
Veteran
Posts: 54280
Joined: Tue Mar 17, 2015 9:14 am

Re: Development of a fairly advanced Freecad plugin/workbench/module

Post by chrisb »

Ping me if you don't get answers here. I can then move the topic to Path forum.
A Sketcher Lecture with in-depth information is available in English, auf Deutsch, en français, en español.
User avatar
onekk
Veteran
Posts: 6222
Joined: Sat Jan 17, 2015 7:48 am
Contact:

Re: Development of a fairly advanced Freecad plugin/workbench/module

Post by onekk »

It depends, on what you want to achieve, automatich path generation, is possible, also automatic gcode generation, is possible, (I have already done that).

For plane "slicing", there are some tools on FreeCAD, for automating things you need scripting, and for this documentation is lacking but not totally, there are tons of lines of code around in the forum to lear with.

Plus a more "detailed" question will almost surely obtains at least one or two different solutions, as many "coders" are reading this forum.

Plus "Path" workbench is not "unfunctional" is simply a little rough and "in progress" many people already use it to produce things.

Regards

Carlo D.
GitHub page: https://github.com/onekk/freecad-doc.
- In deep articles on FreeCAD.
- Learning how to model with scripting.
- Various other stuffs.

Blog: https://okkmkblog.wordpress.com/
User avatar
onekk
Veteran
Posts: 6222
Joined: Sat Jan 17, 2015 7:48 am
Contact:

Re: Development of a fairly advanced Freecad plugin/workbench/module

Post by onekk »

kwahoo wrote: Sun May 23, 2021 7:36 pm Have you read this book https://github.com/qingfengxia/FreeCAD_Mod_Dev_Guide ?
No very interesting, I will read it.

Thanks

Carlo D.
GitHub page: https://github.com/onekk/freecad-doc.
- In deep articles on FreeCAD.
- Learning how to model with scripting.
- Various other stuffs.

Blog: https://okkmkblog.wordpress.com/
User avatar
Pauvres_honteux
Posts: 728
Joined: Sun Feb 16, 2014 12:05 am
Location: Far side of the moon

Re: Development of a fairly advanced Freecad plugin/workbench/module

Post by Pauvres_honteux »

Adouglas wrote: Fri May 21, 2021 4:16 am ... only contain surfaces that can be reached by a selection of end mills.

... do as much as you can with the largest tool in your set, then move to the smaller tool, and so on, until you have used all the tools. It uses the larger tools to remove material wherever they can reach.
To aid you a bit in your quest for the ultimate path generation program, I suggest a principle to start from:

Bubble mesh

With this principle you will get hold of the smallest radius there is in your model or in a certain area. From that information you decrease the tool radius with a nice round number(pun intended) to not get stuttering, then check if the resulting endmill suggestion is 1) feasible, 2) in your toolbox.

Iterate over all areas till they are all covered. Now you can do the same but for rough milling. The course milling head must fit between adjacent surfaces and be a wee smaller, to not get stuttering.

Sum up all info and caculate your paths.
And et voila!
Post Reply