Hello Guest it is April 18, 2024, 04:00:10 PM

Author Topic: MACH4 Pendant not moving Axis  (Read 701 times)

0 Members and 1 Guest are viewing this topic.

MACH4 Pendant not moving Axis
« on: November 14, 2020, 05:36:01 AM »
Hi, I am using MACH4 using the Ethernet Smooth Stepper. I have build a pendant with two rotary encoders and mapped them to the ESS Encoder Aux 0 and 1. I can see, in the Diagnostic Screen of the ESS, that Aux 0 and Aux 1 MPG are following the movement of the rotary encoders. I have assigned MPG0 and MPG1 of MACH4 to those and followed many of the instructions for LUA scripts adding the following lines:
   mc.mcMpgSetAxis(inst, 0, 0) --Map the MPG 0 to control the X Axis
   mc.mcMpgSetAxis(inst, 1, 2) --Map the MPG 1 to control the Z Axis

I also have a speed switch to select the speed of the movement and use the following lines to set the speed:

        mc.mcMpgSetInc(inst, 0, PendantDistanceX1 )
        mc.mcMpgSetInc(inst, 1, PendantDistanceX1 ) 

When I change the speed button, I can see the output message, that those commands got executed.

However I never see movement of my motors. I can move them with the jog buttons or the key on my computer keyboard, but not with the pendant. What am I missing ? Is there any way to observe MPG0 and MPG1 values simalar to the diagnostics of the ESS ?

Thanks in advance for any help
Re: MACH4 Pendant not moving Axis
« Reply #1 on: November 17, 2020, 06:54:22 AM »
Problem solved. When assigning the MPGs in MACH4 the window was so small, that I could not see, that I had assigned ESS_Encoder_0 / 1 instead of ESS_Encoder_Aux_0 / 1.