Hello Guest it is March 28, 2024, 05:22:14 AM

Author Topic: Mach 4 Bug Reports  (Read 498055 times)

0 Members and 1 Guest are viewing this topic.

Offline dude1

*
  •  1,253 1,253
    • View Profile
Re: Mach 4 Bug Reports
« Reply #360 on: May 26, 2015, 02:35:30 AM »

Offline Dan13

*
  •  1,208 1,208
    • View Profile
    • DY Engineering
Re: Mach 4 Bug Reports
« Reply #361 on: May 26, 2015, 03:18:02 AM »
Not really explains the issue I mentioned...

Dan

Offline dude1

*
  •  1,253 1,253
    • View Profile
Re: Mach 4 Bug Reports
« Reply #362 on: May 26, 2015, 03:34:01 AM »
what are you running it as button, G code or macro

Offline Dan13

*
  •  1,208 1,208
    • View Profile
    • DY Engineering
Re: Mach 4 Bug Reports
« Reply #363 on: May 26, 2015, 03:40:19 AM »
I have this code in a button.

Dan

Offline dude1

*
  •  1,253 1,253
    • View Profile
Re: Mach 4 Bug Reports
« Reply #364 on: May 26, 2015, 03:58:39 AM »
try this

local inst = mc.mcGetInstance()
mc.mcCntlGcodeExecuteWait(inst, "G0 X10 Y10\n")
mc.mcCntlGcodeExecute(inst, "G0 X5 Y5\n")

Offline Dan13

*
  •  1,208 1,208
    • View Profile
    • DY Engineering
Re: Mach 4 Bug Reports
« Reply #365 on: May 26, 2015, 04:10:49 AM »
Already have. Makes no difference.

Dan

Offline dude1

*
  •  1,253 1,253
    • View Profile
Re: Mach 4 Bug Reports
« Reply #366 on: May 26, 2015, 05:28:12 AM »
this works
 local inst = mc.mcGetInstance()
        mc.mcCntlGcodeExecute(inst, "G0 X10 Y10\nG0 X5 Y5\n")

Offline simpson36

*
  •  1,369 1,369
    • View Profile
Re: Mach 4 Bug Reports
« Reply #367 on: May 26, 2015, 06:07:10 AM »

When trying to execute two line of Gcode, like below, the DROs again don't update continously, but only when the final point is reached.

local inst = mc.mcGetInstance()
mc.mcCntlGcodeExecute(inst, "G0 X10 Y10\n")
mc.mcCntlGcodeExecute(inst, "G0 X5 Y5\n")


Confirmed behavior in DRO. Not running motors yet so don't know if physical movement is also effected, but judging by how fast the line of code goes by, it is hard to imagine the motors are moving correctly.

Here is a Work Around:

mc.mcCntlGcodeExecute(inst, "G0 X10 Y10 F5\nG0 X-10 Y-10 F5")

Above line counts correctly in DRO

Offline Dan13

*
  •  1,208 1,208
    • View Profile
    • DY Engineering
Re: Mach 4 Bug Reports
« Reply #368 on: May 26, 2015, 08:20:53 AM »
OK. The workaround works.

Dan

Offline simpson36

*
  •  1,369 1,369
    • View Profile
Re: Mach 4 Bug Reports
« Reply #369 on: May 26, 2015, 04:44:16 PM »

Slightly better work around:


mc.mcCntlGcodeExecuteWait(inst, "G1 X10 Y10 F450")
mc.mcCntlGcodeExecute(inst, "G1 X-10 Y-10 F450")

This will perform the rapids as expected.


Caveat: Running above code from the LUA editor,  if the motion is stopped with the on-screen stop button, no amount of coaxing would make it run again short of closing and reopening MACH4. Might work better saved as a proper macro. I stopped messing with it at the above work around.