Assembly3 preview

Discussion about the development of the Assembly workbench.
Forum rules
Be nice to others! Respect the FreeCAD code of conduct!
User avatar
OficineRobotica
Posts: 433
Joined: Thu Feb 21, 2019 8:17 am
Contact:

Re: Assembly3 preview

Post by OficineRobotica »

While working on the CNC assembly, wich in itself is comprised of allot of assemblies and sub assemblies, I realized that I was struggling allot with the fact that icons in the tree being very small they all seem the same and I tough that color coding them in some way will help allot. For now I'vd done only the main "assembly" and the "add new assembly" icon(for consistency in the ui).
assemblyIcon.jpg
assemblyIcon.jpg (375.51 KiB) Viewed 2740 times
Although it might not seem as a big difference in the screenshot, while working with nested assemblies it really helps having a different color representation for different elements in the tree. I will experience with the other icons too but I don't want the tree to become a rainbow of colors witch is counterproductive in itself.
realthunder wrote: Sun Jun 28, 2020 10:02 am First, make sure you are using the latest asm3. I mean the assembly3 workbench. If you've previously clone my asm3 module in your FreeCAD user directory, my AppImage will load that instead of the embedded one. Simply delete the module in your user directory will do.
Do you think that this little modification is worth while to be included in your code? It makes sense from a usability point of view.
By the way, I just discovered the link multiplication function and I just love it for placing screws. There are so many hidden gems in your code.

For who wants to use the icons they are to be placed in your .FreeCAD/Mod/FreeCAD_assembly3-master/freecad/asm3/Gui/Resources/icons/ folder if you have cloned the asm3 repository from github.

treeIcons.zip
(7.96 KiB) Downloaded 61 times
Check out my Youtube channel at: https://www.youtube.com/@OficineRobotica
User avatar
f3nix
Posts: 346
Joined: Sat May 30, 2015 11:58 am

Re: Assembly3 preview

Post by f3nix »

OficineRobotica wrote: Sat Jun 27, 2020 4:46 am CNC progress:
cnc.jpeg
cnc.jpeg (440.05 KiB) Viewed 2662 times
Hi.
Sorry for OT.

Very nice rendering... ;) Waiting for more :)

Cheers,
Mateusz
User avatar
OficineRobotica
Posts: 433
Joined: Thu Feb 21, 2019 8:17 am
Contact:

Re: Assembly3 preview

Post by OficineRobotica »

realthunder wrote: Sun Jun 28, 2020 10:02 am And this problem only surface when you use link with scale, worse link array with scale. Because link does not have geometry, normal link can simply forward the linked object's geometry, while scale has to generate new geometries. I am aware of this issue, and added a bunch for shape caches to lessen the problem. But apparently there is some problem with the cache. I'll look into it.
I made this test file to try to understand the behavior a bit more. I don't think this is related to link with scale because I am able to always reproduce the freeze now with regular links. The freeze is irreversible. To reproduce the freeze it is enough to force the solver to throw a error message of any kind then try to select something in the tree. If the tree isn't touched the freeze does not occur. The situation can be saved with a undo right after the solver error message and not touching the tree.
freeze_asm3.jpeg
freeze_asm3.jpeg (263.86 KiB) Viewed 2566 times
To reproduce:
-select the highlighted face only and add a "PlaneAlignment" constarint
-there will be a error message sayng that it needs 2 planar surfaces
-click something in the tree -> irrecoverable freeze

Seccond issue:
This might be me that I am getting wrong but Why do I get so many redundant constraints error messages when clearly(in my ignorant opinion) there are none?
In the second file linked there are 2 planar surfaces aligned and there are at least other 2 dof's of freedom but I get redundant constraint's with 0 dof's. The bodies were intentionally modeled toponaming unsafe for testing purpose. The sketches are mapped on faces but the pads are all along the normals so there should be no "wrong" angle between the surfaces for the solver to complain. Am I doing something wrong?
redundandConstraints.jpeg
redundandConstraints.jpeg (384.64 KiB) Viewed 2566 times
testASM3.FCStd
(69.2 KiB) Downloaded 76 times
testASM3_1.FCStd
(65.53 KiB) Downloaded 76 times
f3nix wrote: Wed Jul 01, 2020 12:49 am Very nice rendering... ;) Waiting for more :)
Cheers,
Mateusz
I want to have at least 80% of the cnc remodeled in asm3 and I will do a user showcase with the project and the real thing. Things should move a bit faster now as the plasma cutter has arrived so all the steel reinforcements can be cutted faster and with the design that I want. Thank you so much for your kind words.
Check out my Youtube channel at: https://www.youtube.com/@OficineRobotica
User avatar
OficineRobotica
Posts: 433
Joined: Thu Feb 21, 2019 8:17 am
Contact:

Re: Assembly3 preview

Post by OficineRobotica »

Also, with second file, if selecting the smaller face first -> select bigger face second->planeAlignment constraint and this strange thing will happen:
redundandConstraints1.jpeg
redundandConstraints1.jpeg (354.32 KiB) Viewed 2540 times
with the file in this state touching the tree in any way will freeze FC. Contrary if selecting first the bigger face the solver will immediately through an error.

I really hope this report helps in some way. Cheers

EDIT: In this case I saw afterwords where the redundant constraint lies(the second plane alignment). But this doesn't change the fact that if the user does stupid things FC tends to freeze.
Check out my Youtube channel at: https://www.youtube.com/@OficineRobotica
realthunder
Veteran
Posts: 2190
Joined: Tue Jan 03, 2017 10:55 am

Re: Assembly3 preview

Post by realthunder »

OficineRobotica wrote: Wed Jul 01, 2020 5:43 pm Also, with second file, if selecting the smaller face first -> select bigger face second->planeAlignment constraint and this strange thing will happen:
redundandConstraints1.jpeg

with the file in this state touching the tree in any way will freeze FC. Contrary if selecting first the bigger face the solver will immediately through an error.
Looks like the problem you have is that as soon as asm3 solver throws any error message, clicking the tree view will freeze, am I right? Strange, I can't reproduce any of it in my computer. I notice that you are using your own clone of asm3 in your FreeCAD user directory. Is it the latest? I make the AppImage prefer the user directory clone so that the user can update asm3 workbench independent of AppImage, or doing customization like your icons. But for testing purpose, can you please temporary move the asm3 directory out of your user directory and then run the AppImage so it will use the bundled asm3, and see if the same problem occurs?
Try Assembly3 with my custom build of FreeCAD at here.
And if you'd like to show your support, you can donate through patreon, liberapay, or paypal
User avatar
OficineRobotica
Posts: 433
Joined: Thu Feb 21, 2019 8:17 am
Contact:

Re: Assembly3 preview

Post by OficineRobotica »

realthunder wrote: Thu Jul 02, 2020 12:14 am Looks like the problem you have is that as soon as asm3 solver throws any error message, clicking the tree view will freeze, am I right?
Yup....That's exactly wright. Tested with the cloned asm3 directory removed as you advised. I also disabled the tree view overlay to see if the cause could be that. I can always reproduce the freeze. Can it be that your FC version is more up to date respect to master than what us user can download from your repository? We could ignore this at the moment and I will retest when you release the next update. I'm using your latest appimage build but I will link the info none the less. Thank you for looking into this.

Code: Select all

OS: KDE neon User Edition 5.19 (KDE//usr/share/xsessions/plasma)
Word size of OS: 64-bit
Word size of FreeCAD: 64-bit
Version: 0.19.21300 +2367 (Git) AppImage
Build type: Release
Branch: LinkStage3
Hash: daf93f78cc3809ec0b63f8da8ee9002750f5f169
Python version: 3.7.6
Qt version: 5.12.1
Coin version: 4.0.0
OCC version: 7.4.0
Locale: English/United States (en_US)
freeze_asm3_1.jpeg
freeze_asm3_1.jpeg (369.65 KiB) Viewed 2463 times
Check out my Youtube channel at: https://www.youtube.com/@OficineRobotica
User avatar
jpg87
Posts: 809
Joined: Thu Mar 16, 2017 7:16 am
Location: Limoges - France
Contact:

Re: Assembly3 preview

Post by jpg87 »

OficineRobotica wrote: Thu Jul 02, 2020 5:40 am...
cncOficineRobotica.jpg
cncOficineRobotica.jpg (361.04 KiB) Viewed 2430 times
Hello,
I have been following your setbacks on this thread for some time and I do not understand everything in your approach: why all these "Locked" constraints? How did you position your parts before immobilizing them?

I found the idea of ​​using a scale coefficient on an axis interesting to create a family of profiles of different lengths, but I had the same problems as you with the assembly.
On the other hand, by creating from a profile file 50x50 several profile files 50x50x700 and 50x50x1000, I did not have any problem :
asm3cncOfRob.FCStd
(234.82 KiB) Downloaded 89 times
Now, with regard to your last tests (testASM3_1), the surfaces Elem001 and Elem003 are the same (ditto for Elem002 and Elem004) so ​​the two constraints PlaneAlignment and PlaneAlignment001 are identical, hence the problems of the solver :
cncOficineRoboticaTest1.jpg
cncOficineRoboticaTest1.jpg (87.5 KiB) Viewed 2430 times
Already in the creation of your Body and Body001 pieces, why is the Refine property disabled in the creation of the pads? If it was activated you would have this on the screen and it would be more obvious that the surfaces indicated previously are one :
cncOficineRoboticaTest1b.jpg
cncOficineRoboticaTest1b.jpg (43.71 KiB) Viewed 2430 times
My website : http://help-freecad-jpg87.fr updated 2023/11/06
User avatar
OficineRobotica
Posts: 433
Joined: Thu Feb 21, 2019 8:17 am
Contact:

Re: Assembly3 preview

Post by OficineRobotica »

jpg87 wrote: Thu Jul 02, 2020 7:29 am
why all these "Locked" constraints? How did you position your parts before immobilizing them?
In that particular file I was trying to skip the solver with the lock constraints and understand where the freeze of the ui may lie. We haven't yet noticed that the culprit was a solver error combined with the tree click event. Bare in mind that this freeze of the ui doesn't happen with the master branch It was a test file not a "correct" workflow methodology. In fact the main cnc file has alignment constraints.
planeAlignment.jpeg
planeAlignment.jpeg (461.49 KiB) Viewed 2409 times
I found the idea of ​​using a scale coefficient on an axis interesting to create a family of profiles of different lengths, but I had the same problems as you with the assembly.
On the other hand, by creating from a profile file 50x50 several profile files 50x50x700 and 50x50x1000, I did not have any problem :
This is the route that I adopted also. No more problems with scale this way but one must admit that importing just one body and scaling as per necesity was kind of cool and fast workflow wise.
Now, with regard to your last tests (testASM3_1), the surfaces Elem001 and Elem003 are the same (ditto for Elem002 and Elem004) so ​​the two constraints PlaneAlignment and PlaneAlignment001 are identical, hence the problems of the solver :

Already in the creation of your Body and Body001 pieces, why is the Refine property disabled in the creation of the pads? If it was activated you would have this on the screen and it would be more obvious that the surfaces indicated previously are one :
That really skipped me. Thank you. But to my defense the refine property was off by default and to be honest I really didn't think about it.

For the admins: I promise that later today I will make a user sowcase thread so we don't pollute this thread anymore. :D I'm pretty sure there some more experienced users will catch other errors too
Check out my Youtube channel at: https://www.youtube.com/@OficineRobotica
catman
Posts: 412
Joined: Fri Jan 11, 2019 10:42 pm

Re: Assembly3 preview

Post by catman »

I continue to struggle with selecting the right constraints in Assembly 3. In order to avoid solver errors each joint must have a set of constraints that eactly sum to 6DOF (degree of freedom). Not 7, not 5 but 6. Problem is that I keep forgetting which one consumes how many "DOFs".

@realthunder
Would it be possible to have this info in the tool tip? Like "DOF 5" for a constraint that fixes five DOFs.
Or maybe order them in the tool bar with descending DOF?

Thanks
realthunder
Veteran
Posts: 2190
Joined: Tue Jan 03, 2017 10:55 am

Re: Assembly3 preview

Post by realthunder »

catman wrote: Wed Jul 15, 2020 4:41 pm @realthunder
Would it be possible to have this info in the tool tip? Like "DOF 5" for a constraint that fixes five DOFs.
Or maybe order them in the tool bar with descending DOF?
It's been requested multiple times. I'll see what I can do.
Try Assembly3 with my custom build of FreeCAD at here.
And if you'd like to show your support, you can donate through patreon, liberapay, or paypal
Post Reply