- Posts: 275
- Thank you received: 49
XHC-HB04 wireless MPG pendant HAL module
My initial installation was created by running an image that (I think) contained both Ubuntu 10.04(?) and LinuxCNC 2.4 (possibly 2.3). There is note on the front page of linuxcnc.org that says "Note: Do Not upgrade Ubuntu from the installed version as it will prevent LinuxCNC from working.", so I was wary of upgrading to v12. Similarly, I didn't upgrade to the latest version of LinuxCNC..
However, I upgraded to 12.04 and 2.6.0 and the pendant worked immediately. This wasn't a step-by-step methodical approach, so I could only speculate what the differences are that allow the pendant to work. Presumably a variety of updates have been incorporated along the way and it may also be cleaner ie without any unauthorised changes from me.
Thanks again!
Murray
Please Log in or Create an account to join the conversation.
I was able to successfully run the layout2 simulation...pendant worked correctly.
When I start my configuration from a terminal, I get these messages:
xhc-hb04.tcl: !!! <hal.mdi-command-00> target pin does not exist, continuing
xhc-hb04.tcl: using std_start_pause_button
I also noticed that the XYZ positions in AXIS did not update when actually jogging the machine with the keyboard. But the pendant did not work either.
I've attached my ini and hal files. Any help you could provide would be appreciated.
Van
Please Log in or Create an account to join the conversation.
typo: hal.mdi-command-00 should be halui.mdi-command-00xhc-hb04.tcl: !!! <hal.mdi-command-00> target pin does not exist, continuing
I've attached my ini and hal files. Any help you could provide would be appreciated.
Your configuration uses non-trivkins kinematics (gantrykins).
It is not clear to me which jogging features actually work for non-trivkin configurations in linuxcnc2.6 and earlier releases (and current git master). Maybe it will get better with a joints-axis branch that folks are working on -- I have not investigated.
You should probably use the halui plus-minus jogmode -- I think you will be able to use the pendant to jog at variable rates but without exact step increments.
README
jogmodes:
normal: postion mode, the axis will move exactly regardless of how long it takes. Beware: the machine may keep moving after you stop rotating the jog wheel.
vnormal: velocity mode, the axis will stop when the wheel stops. Beware: the amount moved per wheel detent may be less than specified if the machine velocity and acceleration cannot accomplish the move in time.
plus-minus: halui plus-minus jogging (may be useful for world-mode jogging in non-trivkins machines).
To set up plus-minus jogmode in the ini file:
Please Log in or Create an account to join the conversation.
I notice the coordinate positions don't continuously update in the pendant while a program is running. If I change the axis switch during the program, the pendant display resets, and the values update for about 5 seconds, then they freeze. Is this the expected behavior since a pendant isn't usually needed while running a part program?
Now that the basic jog functionality is working, I'm curious as to how to change the behavior of the pendant. For instance, the GOTO-ZERO button run is configured to run an MDI command to move to 0,0,0. I'd like that to be axis-specific, depending on the position of the axis switch (i.e., only move one axis at a time to its zero). I'd also like the ZERO button to set the selected axis' current position to 0.
Would this have to be done in the tcl files, or are there things I would do in the ini/hal files?
Thanks.
Please Log in or Create an account to join the conversation.
be changed with linuxcnc updates.
First study the existing hal connections using (for example):
You will see that the xhc-hb04 driver provides pins corresponding to the rotary switch position:
xhc-hb04.jog.enable-off
xhc-hb04.jog.enable-x
xhc-hb04.jog.enable-y
xhc-hb04.jog.enable-z
xhc-hb04.jog.enable-feed-override
xhc-hb04.jog.enable-spindle-override
You can add hal components and connections to acitvate specific mdi commands for the selsected axis:
New file: zerobutton.hal:
To use this halfile, modify the ini file to:
1) remove any existing connection for the =0 button (zero)
2) add new mdi-commands
3) load new halfile (zerobutton.hal)
Modifications to ini file:
The above example adds mdi commands 16,17,18 and uses G10 L20 to set coordinates but
you can make them do what ever you want -- modify as required.
Please Log in or Create an account to join the conversation.
I would highly recommend that the instructions you provided for this be included in the README file. But even better would be to actually implement this axis-specific functionality in the configuration files provided in 2.6. I think this is generic functionality that would make the pendants more useful "out-of-the-box" and would provide a better foundation for those who may wish to modify their pendant's behavior.
Thanks again!
Please Log in or Create an account to join the conversation.