hal_glib.py does return wrong homed status if usin

More
04 Mar 2015 01:03 #56432 by newbynobi
Hallo,

I mailed this one also to the developers list.

I am working on gmoccapy to make it able to handle also gantry kins. As
you know there are more joints than axis on a gantry.
I was surprised to see, that hal_glip.py and also hal_actions.py do
return a not_all_homed signal, after all joints are homed!

As far as I see, it is caused because both scripts do check:

if count == axis_count:

but as on a gantry , count will be 4 and axis_count will be 3, it will
return False in case all joints are homed.

I decided to change to:

if count >= axis_count:

and it works like expected, but....

What if a user does have a XYYZ gantry and do home X and Y will be 3
joints with 3 axis, but only 2 axis homed?

Do you see any side affects, if I do change

hal_glib.py line 207
and
hal_actions.py line 88

to be

if count >= axis_count:


IMHO hal_actions.py should not even have the check himself, but better a
connection to the signal from hal_glib.py.
i.e. hal_actions does not have the connection to GStat "not all homed"
so it will not react to changes, if the user does unhome one joint.

Waiting for your comments and possible solutions.

Regards Norbert

Please Log in or Create an account to join the conversation.

Moderators: HansU
Time to create page: 0.054 seconds
Powered by Kunena Forum