Hello Guest it is March 04, 2024, 09:16:31 AM

Author Topic: Can't turn off pin after M62  (Read 833 times)

0 Members and 1 Guest are viewing this topic.

Can't turn off pin after M62
« on: January 26, 2023, 01:39:45 AM »
I have output 3 configured as laser output. M62/M63 work fine if there's a G1/G0 after it. But I cannot get it to turn off if I hit stop, or at the end of a program if I don't remember to add M63 and a G1 manually. (Fusion360 output skips the last turn off and expects M30 to turn it off)

I added

Code: [Select]
local hLaser = mc.mcSignalGetHandle(inst, mc.OSIG_OUTPUT3);
mc.mcSignalSetState(hLaser, 0)

to CycleStop() in the screen script, and to the M30 script, but it does nothing. I've also tried putting it in a separate M-code, which also does nothing. The only way I can turn off the laser after hitting cycle stop is to issue a MDI which takes a long time to type if I don't have it ready to go, especially since the control is on a touch screen with no physical keyboard. (M63 P3 G91 G1 X0.0001 G90)

M64/M65 P3 also does nothing.

Is this a bug in the plugin? I can't control the output in any way other than issuing another M62/M63 with a G1. I want to be able to turn off the pin without any motion.