both-home-* error
08 Feb 2016 23:15 #69794
by acondit
both-home-* error was created by acondit
I posted this earlier in the wrong section.
I am running linuxCNC version 2.7.3.
I am trying to set up a config to use a 7i43 board with pncconf. I tried to set up two home and limit switches (both-home-x) and (both-home-z). However, when I look at the hal file
I get (both-home-y) and (both-home-a).
From Hal file:
# external input signals
# --- BOTH-HOME-Y ---
net both-home-y <= hm2_7i43.0.gpio.026.in
# --- BOTH-HOME-A ---
net both-home-a <= hm2_7i43.0.gpio.027.in
When I try to re-edit the file in pncconf it shows (both-home-x) and (both-home-z). I know I can fix it by hand editing but I don’t know what else may be going wrong that is not so obvious.
I also tried setting up X, Y and Z and got Y, Z, and A. So it seems that there is some sort of indexing problem.
I am running linuxCNC version 2.7.3.
I am trying to set up a config to use a 7i43 board with pncconf. I tried to set up two home and limit switches (both-home-x) and (both-home-z). However, when I look at the hal file
I get (both-home-y) and (both-home-a).
From Hal file:
# external input signals
# --- BOTH-HOME-Y ---
net both-home-y <= hm2_7i43.0.gpio.026.in
# --- BOTH-HOME-A ---
net both-home-a <= hm2_7i43.0.gpio.027.in
When I try to re-edit the file in pncconf it shows (both-home-x) and (both-home-z). I know I can fix it by hand editing but I don’t know what else may be going wrong that is not so obvious.
I also tried setting up X, Y and Z and got Y, Z, and A. So it seems that there is some sort of indexing problem.
Please Log in or Create an account to join the conversation.
08 Feb 2016 23:18 #69796
by acondit
Replied by acondit on topic both-home-* error
I thought that I found the problem. I thought that in linuxcnc/src/emc/usr_intf/pncconf/private_data.py the following:
home_limits_shared = [ _("All Limits + Home"),_("X Minimum Limit + Home"), _("Y Minimum Limit + Home"), _("Z Minimum Limit + Home"),
_("A Minimum Limit + Home"),_("X Maximum Limit + Home"), _("Y Maximum Limit + Home"), _("Z Maximum Limit + Home"),
_("A Maximum Limit + Home"),_("X Both Limit + Home"), _("Y Both Limit + Home"), _("Z Both Limit + Home"),
_("A Both Limit + Home") ]
should be changed to
home_limits_shared = [ _("X Minimum Limit + Home"), _("Y Minimum Limit + Home"), _("Z Minimum Limit + Home"),
_("A Minimum Limit + Home"),_("X Maximum Limit + Home"), _("Y Maximum Limit + Home"), _("Z Maximum Limit + Home"),
_("A Maximum Limit + Home"),_("X Both Limit + Home"), _("Y Both Limit + Home"), _("Z Both Limit + Home"),
_("A Both Limit + Home”), _("All Limits + Home") ]
I tried setting X minimum + home, and Z minimum + home and got y minimum + home and a minimum + home. The other data structures all have “All Limits” at the end of their respective arrays while “home_limits_shared” has it at the front of the array.
On more thought I think my proposed fix would just make matters worse. If something is indexing into the array one too far, then moving the first item to the end of the array should make it index in two too far. So, back to the drawing board.
Thanks in advance,
Alan
home_limits_shared = [ _("All Limits + Home"),_("X Minimum Limit + Home"), _("Y Minimum Limit + Home"), _("Z Minimum Limit + Home"),
_("A Minimum Limit + Home"),_("X Maximum Limit + Home"), _("Y Maximum Limit + Home"), _("Z Maximum Limit + Home"),
_("A Maximum Limit + Home"),_("X Both Limit + Home"), _("Y Both Limit + Home"), _("Z Both Limit + Home"),
_("A Both Limit + Home") ]
should be changed to
home_limits_shared = [ _("X Minimum Limit + Home"), _("Y Minimum Limit + Home"), _("Z Minimum Limit + Home"),
_("A Minimum Limit + Home"),_("X Maximum Limit + Home"), _("Y Maximum Limit + Home"), _("Z Maximum Limit + Home"),
_("A Maximum Limit + Home"),_("X Both Limit + Home"), _("Y Both Limit + Home"), _("Z Both Limit + Home"),
_("A Both Limit + Home”), _("All Limits + Home") ]
I tried setting X minimum + home, and Z minimum + home and got y minimum + home and a minimum + home. The other data structures all have “All Limits” at the end of their respective arrays while “home_limits_shared” has it at the front of the array.
On more thought I think my proposed fix would just make matters worse. If something is indexing into the array one too far, then moving the first item to the end of the array should make it index in two too far. So, back to the drawing board.
Thanks in advance,
Alan
Please Log in or Create an account to join the conversation.
08 Feb 2016 23:47 #69799
by cmorley
Replied by cmorley on topic both-home-* error
You found the exact problem.
I will push the fix - it will go with the next release.
Thanks!
Chris M
I will push the fix - it will go with the next release.
Thanks!
Chris M
Please Log in or Create an account to join the conversation.
09 Feb 2016 02:10 - 09 Feb 2016 04:25 #69810
by acondit
Replied by acondit on topic both-home-* error
Chris,
I found the source on my machine made the change a was able to generate a corrected hal file.
Thank you,
Alan
I found the source on my machine made the change a was able to generate a corrected hal file.
Thank you,
Alan
Last edit: 09 Feb 2016 04:25 by acondit. Reason: To thank Chris for verifying the fix.
Please Log in or Create an account to join the conversation.
18 Feb 2016 00:18 #70324
by LS
Replied by LS on topic both-home-* error
Hi Chris,
Is this bug related to the bug reported in this post ==> --LINK--
I'll try Alan's fix ..
Cheers,
Luke
Is this bug related to the bug reported in this post ==> --LINK--
I'll try Alan's fix ..
Cheers,
Luke
Please Log in or Create an account to join the conversation.
Moderators: cmorley
Time to create page: 0.186 seconds