Hi All
I got my XHC-WH04B-4 working recently. I can control all axis and homing, got the MDI macros to set zero and spindle start.
I have a few things that I really need to improve and functions to get working. Hopefully this topic will provide useful development for others going forward.
I see 2 approaches to resolve the issues -
1. modifying HAL configurations
2. modifying the source code behind xhc-whb04b-6
Issues so far:
FEED OVERRIDE - MPG
On start up the pendant is not in Continuous or Step Mode - I note that feed override is changed when using the handwheel
Once homing is complete or Continuous or Step is selected then feed override cannot be affected by the hand wheel
I presume because unlike the 6 axis pendant this 4 axis version does not have a button to select MPG mode, so we cannot return to MPG mode - which i have read is combined with MPG mode for the the feed and spindle override.
Regardless of the above, the operation I really want is simple - Once homed - Select LEAD position and have the hand wheel control feed override - Then I can safely work thorough machine runs using this as a way to quickly halt the machine, or slow feed through areas of programs.
LEAD Position
The rotary position LEAD puts out a different code to the 6 AXIS VERSION - so I cannot select LEAD mode as far as the driver is concerned. This i think requires a change to the source code. I found the offending line in pendant .cc
Line 383 : Needs changing to 0x09 for the 4 axis version (is 0x1C for 6 axis version)
Continuous vs step mode jog.speed :
Continuous operation gives a jog speed far too slow. Step mode gives a step far to large at the higher settings 60% and 100%.
I used halmeter to verify the jog speed scale in the 2 modes and found :
selector Position Jog.scale cont Mode Jog.scale - Step Mode
0.001 0.0008 0.001
0.01 0.002 0.01
0.1 0.004 0.1
1.0 0.012 1.0
60% 0.024 5.0
100% 0.04 10.0
Noting also that: continuous mode - axis.n.jog-vel-mode = 0 In Step Mode - axis.n.jog-vel-mode = 1
In Step its Ok from position 0.001 to 1.0, but step of 5.0 and 10.0 is crazy and will result in smashing tool into something at somepoint - Note removing the option for big step - B from loadusr -W xhc-whb04b-6 -HsfB Does not help the large steps remain active.
As the option B is ineffective , I'd be quite happy if the 60% and 100% settings just gave no output or capped it at 1.0 - so need a way to invoke this.
I see a few possibilities here between a hal solution or a source code change.
Regards my HAL file I have implemented a lowpass filter and also to scale the jog.counts - this improves the continuous mode speeds but then, of course, undesirably scales the step mode distance. I figure I then need develop the HAL code to change the scale applied depending on the mode (cont or step) - first though is to use axis.n.jog-vel-mode with a mux to apply a different scale - but I haven't experimented yet.
But I also wonder why the driver reduces the jog speed scale so much in continuous mode? Perhaps a change to source code giving higher jog.scale in continuous mode is more elegant than complicating the HAL file.
PENDANT LOCKS UP
Not sure how but a couple of times i have the pendant in a state where nothing responds - the usb is fine and the pendant shows activity but no response to hand wheel or buttons. possibly after applying MDI commands in axis then returning to manual mode. - needs further investigation.
Machine: MESA 7i76 + 5i95 - stepper motor axis mill and lathe in mm mode
My gut feel is some source code modification with an extra option for the 4 axis pendant would be great - then the lead mode issue could be fixed. Possibly a change to the cont mode jog.scale values - i'm sure they could be much greater as the machine simply stops when the pulse stop so its much safer scenario than large steps in step mode.
I have some degree of confidence in investigating and modifying the source code - but I have no idea how to go about compiling and implementing changes to xhc-whb04b-6. However I have a spare machine running a sim and i'm wilting to try - any pointers on where to get started are greatly appreciated. (I have some experience with developing software in windows, but I'm a linux newbie)
Otherwise if you think HAL offers a solution please feel free to suggest things. I may have missed a simple method to resolve some of this and happy to consider other ideas.
If your still reading at this point - well done, thanks for taking the time.
Bally