XHC-HB04 wireless MPG pendant HAL module

More
13 years 4 weeks ago #39488 by rmagnus
Hello all

The pendant is working but the section for touchoff for x y and z gives me an error at line 47 of zhc-hb04.hal
saying that pin halui.mdi-command-06 does not exist, so I have no tochoff capability from the pendant.

here are the rows that I have to comment out in order to use the pendant:
# X=0, Y=0, Z=0
net x0 halui.mdi-command-06 xhc-hb04.button-x0
net y0 halui.mdi-command-07 xhc-hb04.button-y0
net z0 halui.mdi-command-08 xhc-hb04.button-z0
net origin halui.mdi-command-09 xhc-hb04.button-goto-zero

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

More
13 years 4 weeks ago #39489 by cncbasher
in your INI file you should have the following entrys

[HALUI]
MDI_COMMAND=...
MDI_COMMAND=...
MDI_COMMAND=...
MDI_COMMAND=...
MDI_COMMAND=...
MDI_COMMAND=...
MDI_COMMAND=G10 L20 P1 X0
MDI_COMMAND=G10 L20 P1 Y0
MDI_COMMAND=G10 L20 P1 Z0
MDI_COMMAND=G0 X0 Y0 Z0

the last 4 being the important ones , which are in order of buttons x ,y ,z goto zero
i.e command 6 through to 9 ( these in order are 0,1,2,3,4,5,6,7,8,9 )
which can be confusing starting at 0

then uncomment the rows in your xhc hal file
The following user(s) said Thank You: rmagnus

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

More
13 years 4 weeks ago #39492 by rmagnus
Hello .\
I pasted the exact MDI_COMMAND you kindly suggested, without knowing what to do with commands 0 to 5 so I left the ... after the = . Is that OK?

The goto zero button now works connected to the MDI 9

now the problem is that my pendant has no touch x , y and z buttons, instead it has a =0 button that is supposed to touch to zero the selected axis with the dial.

so the MDI 6, 7 and 8 commands dont work, if I try to uncomment the next lines it crashes....

#net x0 halui.mdi-command-06 xhc-hb04.button-x0
#net y0 halui.mdi-command-07 xhc-hb04.button-y0
#net z0 halui.mdi-command-08 xhc-hb04.button-z0

I have no idea how to make it work.

Thank you for your help!

Rodolfo

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

More
13 years 4 weeks ago #39493 by rmagnus
I was reading on this same thread that Tommy managed to use his =0 button but then ran into problems when he said
"But there is still a BIG issue with unwanted switching to joint mode when calling subroutine trough MDI_COMMAND"
And he with Andypough tried to fix it but I don´t know how it ended.

So I don´t know what to do next to make my =0 button work.

Thanks again

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

More
13 years 4 weeks ago #39503 by andypugh

rmagnus wrote: "But there is still a BIG issue with unwanted switching to joint mode when calling subroutine trough MDI_COMMAND"


What sort of machine are you using? Unless you have a non-trivial kinematics loaded (like for a robot, or possibly a dual motor gantry) then you won't see that issue.
The following user(s) said Thank You: rmagnus

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

More
13 years 4 weeks ago #39513 by f1oat

rmagnus wrote: I was reading on this same thread that Tommy managed to use his =0 button but then ran into problems when he said
"But there is still a BIG issue with unwanted switching to joint mode when calling subroutine trough MDI_COMMAND"
And he with Andypough tried to fix it but I don´t know how it ended.

So I don´t know what to do next to make my =0 button work.

Thanks again

You will need to build a HAL config file with AND component to handle the axis selection switch.
For this pendant, use xhc-hb04-layout2.ini layout definition file
If you modify your xhc-hb04.hal file as below, it should work:
Code:
loadusr -W xhc-hb04 -I xhc-hb04-layout2.ini -H loadrt and2 count=3 .... # X=0, Y=0, Z=0 net zero xhc-hb04.button-zero => and2.0.in0 and2.1.in0 and2.2.in0 net jog-x and2.0.in1 net jog-y and2.1.in1 net jog-z and2.2.in1 net x0 halui.mdi-command-06 <= and2.0.out net y0 halui.mdi-command-07 <= and2.1.out net z0 halui.mdi-command-08 <= and2.2.out net origin halui.mdi-command-09 xhc-hb04.button-goto-zero

Sorry, I have no access to my machine to verify the syntax. Hope there are not too much mistakes !
Frederic.
The following user(s) said Thank You: rmagnus

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

Time to create page: 0.413 seconds
Powered by Kunena Forum