PathPilot and XHC-HB04 - work?

More
9 years 10 months ago - 9 years 10 months ago #84087 by racedirector
Ok, progress of sorts.

Pathpilot loads without dying after I commented out the MDI commands. The pendant is (sort of) active but with that said nothing performed on the pendant triggers anything in PathPilot. However, jogging in PP changes the pendant display and zero-ing the axis in PP zeros the work display on the pendant. However, the distances are different from each other and it doesn't matter which mode I am in, G20 or G21.

It is late here now so sleep is calling but I need to figure out what connects to what now to get any further. Tomorrow is another day....
Last edit: 9 years 10 months ago by racedirector.

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

More
9 years 10 months ago #84149 by racedirector
Just had a thought (dangerous I know) about the difference between PP and the pendant positional displays..... PP runs in G20 mode and converts the display to G21 as required. That may be affecting how the pendant responds to the axis positions. Will take a deeper look at this as I suss out the rest of the connection.....

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

More
9 years 10 months ago #84840 by racedirector
Well after persevering with this thing I now have some of the commands working. Firstly, I was a fool and finally figured out why the MDI COMMANDS weren't working..... I forgot to put the header [HALUI] in the ini file before them. Once I did that I could do a number of things with the pendant.

However there are some gotchas. PP leaves Linuxcnc in MDI more often than not meaning some part of the UI must be executed to get in into MODE_MANUAL at which time the pendant commands will work. I will attempt to investigate how to overcome this but I suspect it need a recompile of the xhc-hb04 executable, something I not comfortable with.

More investigation ans testing will be needed before I can connect this to my actual machine as I have been testing with PP in sim mode.

Any thoughts on how to keep PP in MANUAL mode would be appreciated, cncbasher maybe? :)

Cheers

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

More
9 years 10 months ago #84865 by cncbasher
i'll put it on my todo list

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

More
9 years 10 months ago #84891 by racedirector
Found this in the mill py file and one of the hal files.....will look into how to connect these to the XHC

From the .py file:
Code:
# Shuttle # force mode switch - needs MODE_MANUAL for jogging to function if self.hal['jog-axis-x-enabled'] or self.hal['jog-axis-y-enabled'] or self.hal['jog-axis-z-enabled'] or self.hal['jog-axis-a-enabled']: if (self.hal['jog-counts'] != self.prev_hal_jog_counts) or (self.hal['jog-ring-speed-signed'] != 0.0): self.ensure_mode(linuxcnc.MODE_MANUAL)

From the hal file:
Code:
# this connects the GUI to the signals from the milljogtranslator/shuttlexpress net sxp.xen-button => tormach.jog-axis-x-enabled net sxp.yen-button => tormach.jog-axis-y-enabled net sxp.zen-button => tormach.jog-axis-z-enabled net sxp.aen-button => tormach.jog-axis-a-enabled net sxp.step-button => tormach.jog-step-button net sxp.jog-ring-speed-signed => tormach.jog-ring-speed-signed net sxp.selected-axis => tormach.jog-ring-selected-axis net sxp.counts-smoothed => tormach.jog-counts net sxp.gui_step_index <= tormach.jog-gui-step-index net sxp.is_metric <= tormach.jog-is-metric

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

More
9 years 9 months ago #85130 by RandyJ
Here is a start. There are a few major problems that make the HB04 somewhat limited.

# Relative position LCD
net pos-rel-x halui.axis.0.pos-relative => xhc-hb04.x.pos-relative
net pos-rel-y halui.axis.1.pos-relative => xhc-hb04.y.pos-relative
net pos-rel-z halui.axis.2.pos-relative => xhc-hb04.z.pos-relative
net pos-rel-a halui.axis.3.pos-relative => xhc-hb04.a.pos-relative

# Jog wheel and axis selection button in XHB-04.hal
net jog-x axis.0.jog-enable <= xhc-hb04.jog.enable-x
net jog-y axis.1.jog-enable <= xhc-hb04.jog.enable-y
net jog-z axis.2.jog-enable <= xhc-hb04.jog.enable-z
# in the postgui hal
net jog-x => tormach.jog-axis-x-enabled
net jog-y => tormach.jog-axis-y-enabled
net jog-z => tormach.jog-axis-z-enabled

# in XHC-HB04,hal jog wheel works.
net jog-scale xhc-hb04.jog.scale => axis.0.jog-scale axis.1.jog-scale axis.2.jog-scale
net jog-counts xhc-hb04.jog.counts => axis.0.jog-counts axis.1.jog-counts
net jog-counts-neg xhc-hb04.jog.counts-neg => axis.2.jog-counts
net size-up xhc-hb04.button-step => xhc-hb04.stepsize-up


Problems at first glance:
1. Tormach hal has no output to show that you are in G21 (mm). So you cant change the display
2. That is OK, because the V06 driver that I have of XHC-HB04 also doesn't bring out the is-metric pin. Some work needs to be done to that driver.
3. There is no simple way to do the math for DTG. The tormach and halui hals do not give you this value. Meth is not allowed (something like this).
net pos-dtg-x (halui.axis.0.pos-command - halui.axis.0.pos-feedback) => xhc-hb04.x.pos-relative
So for these reasons we are stuck with inches.
4. Tormach also stripped the halui.mdi-commandXX, so other functions are also limited.

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

Time to create page: 0.313 seconds
Powered by Kunena Forum