XHC-WHB04B-6 LinuxCNC not working

More
6 years 9 months ago #155290 by satiowadahc
Good to hear! As I don't have a 6 axis one, and haven't received feedback do the last two axis's work?

Please Log in to join the conversation.

More
6 years 9 months ago #155338 by jonch919

satiowadahc wrote: Good to hear! As I don't have a 6 axis one, and haven't received feedback do the last two axis's work?

I tried the 6-axis driver you posted. I could not get it working. From what I remember it didn't seem that the two versions worked in the same way. It was some command that didn't exist on mine. Can't remember details I'm afraid, haven't had time to work on my mill for months.
There were a couple of typos I corrected in that version. Not sure if you have posted a new one.
I did however get the other driver from the "German guy" working. It works really well with that driver.
It it would be interesting to hear if anyone else got your driver for the 6-axis working. I'd like to try that as well.

Please Log in to join the conversation.

More
6 years 7 months ago #161179 by MovT
Jogwheel function [SOLVED]

Hi.

I solved the not proper working jogwheel with the driver from machinekit, that Talla83 supplied on his homepage and Youtube channel.

If you already use halui.machine.is-on for switching some solenoids etc. you run in the trap. When you start and get the error that halui.machine.is-on is already connected, and comment out the line, you kill the logic:
Code:
net pdnt.machine.is-on halui.machine.is-on whb.halui.machine.is-on

The driver NEED the signal on whb.halui.machine.is-on to run properly its safe to do nothing untile the machine is on. If you see the RESET in the display the machine need to be power on. If you do that, the signal will be set, the "RESET" disappear and you can use all other functions you have set and after homing, jogging works like a charm.

Maybe it's a good idea to komment it in the HAL that this line is mandatory.

Hope it will spread around and we all will have fun in these days.

Take care and keep well!!!

Best,
Udo

Please Log in to join the conversation.

More
6 years 7 months ago #161888 by alkabal
Hi

I have used the last driver from machinekit and try to update for linuxcnc master

All work fine excepted the velocity jog mode, turning the feedrate button from pendant update the feedrate override in GUI (2% to 100%) but the move seems to be allways at same velocity.

I have some trouble understanding the process for velocity jog feed.

Is there a reason for not merging something like this driver ?

Br


Ps : this driver include toggle mode for mist/flood from Fn+ step/continuous (and lube from macro 2), also include a toggle for Absolut/Relative Dro from macro 10, + removed some useless code

Please Log in to join the conversation.

More
6 years 6 months ago #162300 by alkabal
If this can be usefull for someone, for smoothieboard + smoopi with kivy i have write a driver full featured.
This one add two more feature :
-Spindle override using lead position
-Speedrate override using CON mode

The result is 4 different function using STEP/MPG/CON/LEAD

This driver was written with much difficulty but i hope is not crappy and is easy to read.
github.com/wolfmanjm/kivy-smoothie-host/pull/16


For Linuxcnc i have see other based source code than raoul Rubien, based on the original hb04b, or if i remember also a python version. (i can't found the topic another time)

At the end, what is the most finished version ?
Why nobody try to include one of this to master ?

Please Log in to join the conversation.

More
6 years 6 months ago #162312 by alkabal
Code:
// ---------------------------------------------------------------------- void Pendant::dispatchFeedValueToHal() { // on feed rotary button change FeedRotaryButton& feedButton = mCurrentButtonsState.feedButton(); if (feedButton.isPermitted()) { float axisJogStepSize = 0; if (feedButton.stepMode() == HandwheelStepmodes::Mode::STEP) { mHal.setFeedOverrideCountEnable(false); mHal.setStepMode(true); mHal.setFeedOverrideScale(0.1); mHal.setFeedOverrideDirectValue(false); axisJogStepSize = feedButton.stepSize(); } else if (feedButton.stepMode() == HandwheelStepmodes::Mode::CONTINUOUS) { mHal.setFeedOverrideCountEnable(false); mHal.setContinuousMode(true); // On velocity mode set feed-override value to absolute percentage value: counts*scale. axisJogStepSize = 2; //axisJogStepSize = feedButton.stepSize(); mHal.setFeedOverrideDirectValue(true); float feedButtonStepSize = feedButton.stepSize(); if (feedButtonStepSize >= 10) { // on velocity >= 10%: set a coarse grained scale, // this also affects the Feed+/- increment mHal.setFeedOverrideScale(0.1); mHal.setFeedOverrideCounts(feedButtonStepSize * 0.1); } else { // on velocity < 10%: set a fine grained scale, // this also affects the Feed+/- increment mHal.setFeedOverrideScale(0.01); mHal.setFeedOverrideCounts(feedButtonStepSize * 1); } } else { } mHal.setStepSize(axisJogStepSize); } else { mHal.setStepSize(0); } } // ----------------------------------------------------------------------


The Step/Mpg mode are managed here but this is not clear for me. (and more trouble with the use of ilowpass and scale from hal)


in my own driver i do
Code:
steplut = {0x0d: 0.001, 0x0e: 0.01, 0x0f: 0.1, 0x10: 1, 0x1a: 1, 0x1b: 1, 0x1c: 0} # combined button for set step mpglut = {0x0d: 2, 0x0e: 5, 0x0f: 10, 0x10: 30, 0x1a: 60, 0x1b: 100, 0x1c: 0} # combined button for set mpg dist = 0.001 * wheel-pulse * self.mpglut[speed_mode] # mode mpg dist = self.steplut[speed_mode] *wheel-pulse # mode step

Please Log in to join the conversation.

More
6 years 6 months ago #162323 by alkabal
Writing this allow to have something variable but i'm unsure about the real reaction needed for Mpg mode.
I have try to use without success :
halui.feed-override.count-enable (bit, in)
halui.feed-override.counts (s32, in) - counts * scale = FO
halui.feed-override.direct-value (bit, in)
halui.feed-override.scale (float, in)
Code:
void Pendant::dispatchFeedValueToHal() { // on feed rotary button change FeedRotaryButton& feedButton = mCurrentButtonsState.feedButton(); if (feedButton.isPermitted()) { float axisJogStepSize = 0; if (feedButton.stepMode() == HandwheelStepmodes::Mode::STEP) { mHal.setStepMode(true); mHal.setContinuousMode(false); mHal.setFeedOverrideCountEnable(false); mHal.setFeedOverrideDirectValue(false); mHal.setFeedOverrideScale(0); axisJogStepSize = feedButton.stepSize(); } else if (feedButton.stepMode() == HandwheelStepmodes::Mode::CONTINUOUS) { mHal.setStepMode(false); mHal.setContinuousMode(true); mHal.setFeedOverrideCountEnable(false); mHal.setFeedOverrideDirectValue(false); mHal.setFeedOverrideScale(0); axisJogStepSize = feedButton.stepSize() * 0.001; } else { } mHal.setStepSize(axisJogStepSize); } else { mHal.setStepSize(0); } }

Please Log in to join the conversation.

More
6 years 6 months ago #162381 by andypugh

alkabal wrote: Why nobody try to include one of this to master ?


I am not aware of anyone asking.

If you want to make a pull-request to LinuxCNC then it might get merged. The problem is that most developers probably don't have the hardware to test it with.

Please Log in to join the conversation.

More
6 years 6 months ago #162393 by alkabal
Thanks for reply, i like to PR if you agree but i need to finish some works.

Is this have more sense ? "In Mpg mode the step speed is in percent of max-velocity"
(if yes the good pin it is halui.max-velocity.value for calc ?)

I have corrected the Lead mode for use spindle override to GUI.
Fix scale Button Feed+/- for speed override to GUI
Fix Rotary knob to change only pendant feedrate

Please Log in to join the conversation.

More
6 years 6 months ago #162484 by andypugh

alkabal wrote: Writing this allow to have something variable but i'm unsure about the real reaction needed for Mpg mode.
I have try to use without success :
halui.feed-override.count-enable (bit, in)
halui.feed-override.counts (s32, in) - counts * scale = FO
halui.feed-override.direct-value (bit, in)
halui.feed-override.scale (float, in)


If you can it is rather better to use the motion jogging pins rather than halui.

Halui is a user-space program. Motion (which creates the joint.... and axis.... HAL pins) runs in realtime so will react to inputs more dependably.

Though that probably doesn't matter as much when you are connecting via USB, which has its own issues.

Please Log in to join the conversation.

Time to create page: 0.099 seconds
Powered by Kunena Forum