Another approach to assembly solver (A2plus)

Discussion about the development of the Assembly workbench.
kbwbe
Posts: 953
Joined: Tue Apr 10, 2018 3:12 pm
Location: Germany, near Köln (Cologne)

Re: Another approach to assembly solver (A2plus)

Postby kbwbe » Wed Jan 22, 2020 6:52 pm

dan-miel wrote:
Mon Jan 20, 2020 5:16 am

Code: Select all

  File "C:\Users\dan-m\AppData\Roaming\FreeCAD\Mod\A2plus\a2plib.py", line 323, in fit_rotation_axis_to_surface1
    uv = sum( [ [ (u,v) for u in linspace(0,1,n_u)] for v in linspace(0,1,n_v) ], [] )
<class 'NameError'>: name 'linspace' is not defined
Hi Dan,
this error is fixed in Version 0.4.40c.
KBWBE

https://github.com/kbwbe/A2plus
latest release: v0.4.47a, installable via FreeCAD's addon manager
Tutorial: gripper assembly https://www.youtube.com/watch?v=QMxcQ5tssWk
Documentation: https://www.freecadweb.org/wiki/A2plus_Workbench
dan-miel
Posts: 131
Joined: Thu Sep 13, 2018 12:29 am
Location: Spokane WA. USA

Re: Another approach to assembly solver (A2plus)

Postby dan-miel » Thu Jan 23, 2020 1:41 am

kbwbe wrote:
Wed Jan 22, 2020 6:52 pm
this error is fixed in Version 0.4.40c.
Thank you
PavelK
Posts: 2
Joined: Sat Apr 04, 2015 3:59 pm

Re: Another approach to assembly solver (A2plus)

Postby PavelK » Sat Jan 25, 2020 7:35 pm

Hi,
I need center two panels together. They have a slightly different dimensions and different holes, openings.
In my case Center OfMass constraint does not work.
How to center both panel to be their outer dimensions aligned to each other
S2.FCStd
Panels
(58.06 KiB) Downloaded 11 times
?
It looks that I need something like "Geometric center" constraint...
Thanks,
Pavel
kbwbe
Posts: 953
Joined: Tue Apr 10, 2018 3:12 pm
Location: Germany, near Köln (Cologne)

Re: Another approach to assembly solver (A2plus)

Postby kbwbe » Sun Jan 26, 2020 7:56 pm

PavelK wrote:
Sat Jan 25, 2020 7:35 pm
Hi,
I need center two panels together. They have a slightly different dimensions and different holes, openings.
In my case Center OfMass constraint does not work.
How to center both panel to be their outer dimensions aligned to each other S2.FCStd?
It looks that I need something like "Geometric center" constraint...
Probably you do not need a new constraint. You could use the mounting holes to align "panel" to "subpanel" with axisCoincident or circularEdge constraints.

But the mounting holes do not fit together.

P.S. If something does not fit, which constraint should be used ? You have to position the parts somehow manually.
mismatch.png
mismatch.png (22.19 KiB) Viewed 553 times
KBWBE

https://github.com/kbwbe/A2plus
latest release: v0.4.47a, installable via FreeCAD's addon manager
Tutorial: gripper assembly https://www.youtube.com/watch?v=QMxcQ5tssWk
Documentation: https://www.freecadweb.org/wiki/A2plus_Workbench
dan-miel
Posts: 131
Joined: Thu Sep 13, 2018 12:29 am
Location: Spokane WA. USA

Re: Another approach to assembly solver (A2plus)

Postby dan-miel » Mon Jan 27, 2020 5:05 pm

kbwbe
When the solver runs and it errors, how possible would it be to have it record the error but keep running to the end instead of stopping at the first error?
If two parts are being solved and nether one is rigid, could one be fixed, solved, and have the fixed state returned to float after being solved? This might reduce the number of p"art did not move" errors and could be listed as a floating error.
Lastly could the errors, perhaps, be reported to a dropdown window instead of having the dialog popup. There are times that I know I'm making an error but I want to fix it later, at the moment I just want the constraints solved with the errors not fixed.

Thanks.
Dan Miel
Turro75
Posts: 175
Joined: Mon Aug 15, 2016 10:23 pm

Re: Another approach to assembly solver (A2plus)

Postby Turro75 » Fri Jan 31, 2020 11:30 am

Hi Klaus,

I successfully tried the sketch feature....wowowowowow!!!! amazing!
this make a lot easier the pattern placement.

I got the sketch item reported in the partlist, would it possible hide it from the list?

thanks again

Valerio
kbwbe
Posts: 953
Joined: Tue Apr 10, 2018 3:12 pm
Location: Germany, near Köln (Cologne)

Re: Another approach to assembly solver (A2plus)

Postby kbwbe » Fri Jan 31, 2020 12:05 pm

Turro75 wrote:
Fri Jan 31, 2020 11:30 am
I successfully tried the sketch feature....wowowowowow!!!! amazing!
this make a lot easier the pattern placement.
Thank you !
Turro75 wrote:
Fri Jan 31, 2020 11:30 am
I got the sketch item reported in the partlist, would it possible hide it from the list?
Sure. At weekend.

For those who are missing the context, this post is following that one : https://forum.freecadweb.org/viewtopic.php?f=20&t=42928
KBWBE

https://github.com/kbwbe/A2plus
latest release: v0.4.47a, installable via FreeCAD's addon manager
Tutorial: gripper assembly https://www.youtube.com/watch?v=QMxcQ5tssWk
Documentation: https://www.freecadweb.org/wiki/A2plus_Workbench
dan-miel
Posts: 131
Joined: Thu Sep 13, 2018 12:29 am
Location: Spokane WA. USA

Re: Another approach to assembly solver (A2plus)

Postby dan-miel » Sat Feb 01, 2020 5:05 am

dan-miel wrote:
Wed Jan 22, 2020 1:28 am
Unit1, I found the problem I was having in this file.
Unit1
I changed gears on displaying the constraints. I found you need to be able to see small movements to detect the movement in your model.
The attached program puts the information into a table. As you move the mouse over the constraints name's and the name of features, the parts highlight in the window. Clicking in the third column, constraint name, runs that mate. The eigth column show the part that moved, the ninth column shows the number of parts moved( one part is fixed or rigid so there should always be 1) and the amount of movement in each plane. I believe the output will be what you have in your FreeCAD settings, mm for you? Below are some rows I copied which are in inches. In the basics video below I show a conflicting constraint where two constraints are trying to control a part but Unit1's model doesn't seem to have conflicting parts. The error's in Unit1's broken mate's seem to be made by excessive movements, many are smaller than eight decimal places. I am starting to wonder what is the acceptable rounding factor and what are errors? It seems that SW was around eight decimal places but it has been a few years for me. kbwbe, anyone, thoughts?
The macro can be copied to your macro folder and ran using the macro toolbar in FreeCAD.




Parts moved = 1 x 0.0000000035551267 in y -0.0000000304798460 in z 0.0000000000000000 in
Parts moved = 1 x 0.0000000013026745 in y 0.0000000000423130 in z -0.0000000000000001 in
Parts moved = 1 x 0.0000000000000000 in y -0.0000000002153577 in z 0.0000000003500380 in
Parts moved = 1 x -0.0000000020769450 in y 0.0000000000000000 in z 0.0000000000000000 in

Videos are not the main subject but here is a link to a video showing the basic features of the macro tool below https://youtu.be/GRtySM_Vpk4 1min 30sec
and a video showing the results of using it on a large model. https://youtu.be/0Oa8n6jIDF8 1min 30sec
fc_tofu
Posts: 652
Joined: Sun Jan 05, 2020 4:56 pm

Re: Another approach to assembly solver (A2plus)

Postby fc_tofu » Sat Feb 01, 2020 4:22 pm

kbwbe wrote:
Sun Jun 10, 2018 11:09 am
...
I developed a small prototype of yet another solver. It is in a very early state now and is only capable to handle plane/circularedge/axis-constraints.
...
Hi, hbwbe,

I made some menu and tooltip polish at A2plus 0.4.36 for personal use, according to some unruled but common adopted menu design rules like below,
- menu, 1st letter uppercase in each notional word (or each word)
- menu, 3 ellipsis dots following text (no space character between) means to open dialog (except warning/confirm dialog)
- menu, no space character in 1st level
- menu, allowed punctuation types whitelist
- menu, levels no more than x
- menu, items no more than x in each level
- menu, letters (including punctuations) no more than x
- tooltip/statustip, 1st letter uppercase in first word
- tooltip/statustip, letters (including punctuations) no more than x
- tooltip/statustip, following period mark (or other, or not)
fsc_2020-01-31_032329.jpg
fsc_2020-01-31_032329.jpg (148.42 KiB) Viewed 305 times
fsc_2020-02-02_043246.jpg
fsc_2020-02-02_043246.jpg (100.46 KiB) Viewed 305 times
Some "msg" part unfinished, for I can hardly find them in runtime.

Changes in "InitGui.py", I made "#rv" mark for review purpose. Other files, I changed directly without leaving mark.

If you find some changes useful and can be merged into your next version, I'm glad, please tell me what to do.
Last edited by fc_tofu on Sat Feb 01, 2020 8:43 pm, edited 4 times in total.
kbwbe
Posts: 953
Joined: Tue Apr 10, 2018 3:12 pm
Location: Germany, near Köln (Cologne)

Re: Another approach to assembly solver (A2plus)

Postby kbwbe » Sat Feb 01, 2020 8:32 pm

fc_tofu wrote:
Sat Feb 01, 2020 4:22 pm
I made some menu and tooltip polish at A2plus 0.4.36 for personal use...
Hi @fc_tofu,
the structured menu really looks better. Please upload the InitGui.py file.
Thank you.
KBWBE

https://github.com/kbwbe/A2plus
latest release: v0.4.47a, installable via FreeCAD's addon manager
Tutorial: gripper assembly https://www.youtube.com/watch?v=QMxcQ5tssWk
Documentation: https://www.freecadweb.org/wiki/A2plus_Workbench