A2plus bench - constraints always greyed out

Discussion about the development of the Assembly workbench.
Forum rules
Be nice to others! Respect the FreeCAD code of conduct!
Post Reply
SimonH_freeCAD
Posts: 15
Joined: Sat Nov 23, 2019 5:55 pm
Location: Bristol

A2plus bench - constraints always greyed out

Post by SimonH_freeCAD »

Hi

I am running 0.18 and just imported A2PLUS bench V 0.4.42a

I imported a few parts I created ( random cuboids ) and a couple of fastenings. Unfortunately whatever I do , the constraints are all grey and are never active so I cannot use them.

I guess I am doing something dumb!! Any advice would be much appreciated

Thanks Simon

[attachment=0]a2plus.png
Attachments
a2plus.png
a2plus.png (155.47 KiB) Viewed 1037 times
kbwbe
Veteran
Posts: 1052
Joined: Tue Apr 10, 2018 3:12 pm
Location: Germany, near Köln (Cologne)

Re: A2plus bench - constraints always greyed out

Post by kbwbe »

SimonH_freeCAD wrote: Tue Feb 04, 2020 10:17 pm I imported a few parts I created ( random cuboids ) and a couple of fastenings. Unfortunately whatever I do , the constraints are all grey and are never active so I cannot use them.
1) You should not use part containers within the assembly. Just import your parts from other files. (Also converted parts are ok somehow)
2) The suitable constraints get active, when you are selecting something. E.g. an linear edge on one part and another linear edge on another part.

Have a short look at this video for using the basics of A2plus: https://www.youtube.com/watch?v=QMxcQ5tssWk
Also a reading the A2plus documentation often helps: https://www.freecadweb.org/wiki/A2plus_Workbench
KBWBE

https://github.com/kbwbe/A2plus
latest release: v0.4.56, installable via FreeCAD's addon manager
Tutorial: gripper assembly https://www.youtube.com/watch?v=QMxcQ5tssWk
Documentation: https://www.freecadweb.org/wiki/A2plus_Workbench
SimonH_freeCAD
Posts: 15
Joined: Sat Nov 23, 2019 5:55 pm
Location: Bristol

Re: A2plus bench - constraints always greyed out

Post by SimonH_freeCAD »

Hi KBWBE,

Many thanks for your reply. In fact I did read the excellent documentation and look at the video. I just missed one tiny detail ......to use CTRL key when selecting. I have corrected my error and all is well.

Now I can use the constraints and am practicing with some example designs.

Many thanks once again for your help,

Simon Hildebrand
dan-miel
Posts: 391
Joined: Thu Sep 13, 2018 12:29 am
Location: Spokane WA. USA

Re: A2plus bench - constraints always greyed out

Post by dan-miel »

SimonH_freeCAD wrote: Sun Feb 09, 2020 2:56 pm I just missed one tiny detail ......to use CTRL key when selecting.
I think adding code so parts can be selected without the control key would be beneficial for:
1: New users who forget the key:
2: People who like myself has trouble using the control key.

I'm trying to write some code for my use but I'm not the sharpest pencil. The link below, hopefully, leads to a a2p_constraintDialog.py that may eliminated the use of the control key. Code below 1100 is kbwbe's code, above, I added. It seems to work in FreeCAD 18 but not 19. I'll put this in the api help in a few hours.
To use the file replace the file in your FreeCAD\Mod\A2plus folder. Better make a backup. It is A2plus version VO4.42c.
If it works. everything is the same as before except no control key and there is a popup if you forget to click the accept button.

This is my first time using GitHub let me know what doesn't work.

https://github.com/DanMiel/No-control-key-for-A2plus
vocx
Veteran
Posts: 5197
Joined: Thu Oct 18, 2018 9:18 pm

Re: A2plus bench - constraints always greyed out

Post by vocx »

dan-miel wrote: Sun Feb 09, 2020 7:54 pm ...
This is my first time using GitHub let me know what doesn't work.
...
If you want to learn more about Git and all that, see Source code management. This page is intended for FreeCAD development, but the same information can be applied to any other project, in this case, A2plus.

In particular, instead of providing just a single file, you should fork the entire A2plus repository, then modify this fork. Then it's easy to create a pull request and compare your modifications with the original code.
Always add the important information to your posts if you need help. Also see Tutorials and Video tutorials.
To support the documentation effort, and code development, your donation is appreciated: liberapay.com/FreeCAD.
Post Reply