Jogwheels won´t jog
- Onkelmat
-
Topic Author
- Offline
- Premium Member
-
Less
More
- Posts: 92
- Thank you received: 4
19 Jul 2026 14:37 #347841
by Onkelmat
Jogwheels won´t jog was created by Onkelmat
It´s a me again.
So far I got the Gildemeister NEF 500 Plus Lathe running again, with the keyboard i was even able to make some chips. Homing now works since the updated version of Pncconfig wizard seems to have a few bugs left for the 7i97T. On bug for example is, inputs that are "inmux.00" are named "in.00" in the .ini or .hal, not sure right now but that occured every single time i changed something with the wizard.
But let´s get back to the problem I´m facing now. Trust me, searched two whole days to find a solution bymyselfe.
Here´s the physical setup where i´m coming from:
i have two Handwheels on my machine, they have A /A b /B signals, and are wired to encoder 03 and encoder 04. In Halshow i can see the hm2_7i797.0.encoder.03.count corresponding to each wheel. That worked right away.
The wheels should be always enabled, except when running a command or a programm. The wheels are fixed to their axis. 03 is for Z axis and 04 is for X Axis.
I copied and wrote tons of .hal lines but nothing seems to get the axis moving when i´m turning the wheels. I tried to set all enables that are somehow related to axis jogging to true in Halshow. nothing worked. In the documentation the link is broken to that one site for hooking a jogwheel. And every code i copied was obsolote, since the names of the pins and this has changed. I end up with "pin doesn´t exsist" all the time. You don´t have to tell me the whole solution, but i´d like to understand the mechanics behind Jogwheels and Axis jogging, how do i link the jogwheel count to the axis count so it moves ?
So far I got the Gildemeister NEF 500 Plus Lathe running again, with the keyboard i was even able to make some chips. Homing now works since the updated version of Pncconfig wizard seems to have a few bugs left for the 7i97T. On bug for example is, inputs that are "inmux.00" are named "in.00" in the .ini or .hal, not sure right now but that occured every single time i changed something with the wizard.
But let´s get back to the problem I´m facing now. Trust me, searched two whole days to find a solution bymyselfe.
Here´s the physical setup where i´m coming from:
i have two Handwheels on my machine, they have A /A b /B signals, and are wired to encoder 03 and encoder 04. In Halshow i can see the hm2_7i797.0.encoder.03.count corresponding to each wheel. That worked right away.
The wheels should be always enabled, except when running a command or a programm. The wheels are fixed to their axis. 03 is for Z axis and 04 is for X Axis.
I copied and wrote tons of .hal lines but nothing seems to get the axis moving when i´m turning the wheels. I tried to set all enables that are somehow related to axis jogging to true in Halshow. nothing worked. In the documentation the link is broken to that one site for hooking a jogwheel. And every code i copied was obsolote, since the names of the pins and this has changed. I end up with "pin doesn´t exsist" all the time. You don´t have to tell me the whole solution, but i´d like to understand the mechanics behind Jogwheels and Axis jogging, how do i link the jogwheel count to the axis count so it moves ?
Please Log in or Create an account to join the conversation.
- tuxcnc
- Offline
- Elite Member
-
Less
More
- Posts: 162
- Thank you received: 21
19 Jul 2026 18:36 #347845
by tuxcnc
Replied by tuxcnc on topic Jogwheels won´t jog
Thank you very much.
I have been planning to add encoder support as mpg for a long time, but it was not my priority because I do not have the appropriate equipment.
But today you gave me an opportunity, so I connected a regular encoder to 7i92 and performed tests.
In the condition as below, you can move the X axis by turning the encoder, but only after the axis has been referenced.
I haven't tested any more because I don't want to look for and solder switches right now, but judging by the code it must work.
(The setp axis.x.jog-enable 1 line is for testing only and should be removed afterwards.)
I have been planning to add encoder support as mpg for a long time, but it was not my priority because I do not have the appropriate equipment.
But today you gave me an opportunity, so I connected a regular encoder to 7i92 and performed tests.
In the condition as below, you can move the X axis by turning the encoder, but only after the axis has been referenced.
I haven't tested any more because I don't want to look for and solder switches right now, but judging by the code it must work.
(The setp axis.x.jog-enable 1 line is for testing only and should be removed afterwards.)
loadrt mux4
addf mux4.0 servo-thread
# For velocity mode, set to 1
# In velocity mode the axis stops when the dial is stopped
# even if that means the commanded motion is not completed,
# For position mode (the default), set to 0
# In position mode the axis will move exactly jog-scale
# units for each count, regardless of how long that might take,
setp axis.x.jog-vel-mode 1
setp axis.y.jog-vel-mode 1
setp axis.z.jog-vel-mode 0
# The Axis select inputs
# Line bellow is for testing only. For normal use remove it and uncomment next.
setp axis.x.jog-enable 1
#net mpg-x axis.x.jog-enable <= hm2_7i92.0.gpio.026.in_not
net mpg-y axis.y.jog-enable <= hm2_7i92.0.gpio.030.in_not
net mpg-z axis.z.jog-enable <= hm2_7i92.0.gpio.031.in_not
# The inputs to the mux4 component
net scale1 mux4.0.sel0 <= hm2_7i92.0.gpio.016.in_not
net scale2 mux4.0.sel1 <= hm2_7i92.0.gpio.015.in_not
# This sets the scale that will be used based on the input to the mux4
setp mux4.0.in0 0.025
setp mux4.0.in1 0.0025
setp mux4.0.in2 0.00025
# The output from the mux4 is sent to each axis jog scale
net mpg-scale mux4.0.out => axis.x.jog-scale axis.y.jog-scale axis.z.jog-scale
# The encoder output counts to the axis. Only the selected axis will move.
net encoder-counts hm2_7i92.0.encoder.00.count => axis.x.jog-counts axis.y.jog-counts axis.z.jog-counts
The following user(s) said Thank You: Onkelmat
Please Log in or Create an account to join the conversation.
- PCW
-
- Away
- Moderator
-
Less
More
- Posts: 17966
- Thank you received: 5269
19 Jul 2026 23:22 #347854
by PCW
Replied by PCW on topic Jogwheels won´t jog
To jog before homing you need to connect the joint jog pins the same as the axis jog pins
That is for example if X is joint 0, you would connect these pins
to the same sources as the X jog pins:
joint.0.jog-counts
joint.0.jog-scale
joint.0.jog-enable
joint.0.jog-vel-mode
That is for example if X is joint 0, you would connect these pins
to the same sources as the X jog pins:
joint.0.jog-counts
joint.0.jog-scale
joint.0.jog-enable
joint.0.jog-vel-mode
The following user(s) said Thank You: tuxcnc
Please Log in or Create an account to join the conversation.
Time to create page: 0.432 seconds