MKS DLC32 ver2.1, grbl 1.1h; G4 Dwell ignored

Any idea why my controller, MKS DLC32 ver2.1 running grbl 1.1h, ignores G4 command? i have tried G4 P2 and such but no matter what parameters are used the controller ignores it. I have managed to relate the fact that lightburn uses M4 command by default and not M3 which might be the culprit but this is just me guessing.

Lightburn ver 2.x RC7.

Try P2000 - some boards use milliseconds, some use seconds. Everyone seems to make up their own units arbitrarily, and if that board uses milliseconds, “P2” wouldn’t be ignored, but would happen so fast you’d think it was.

Thx.
Just checked,- didn’t work.

It seems that G4 P5 does work in the START GCODE script (5 sec dwell) but not from within END GCODE scripts.

Please check.

Can you show the entire end gcode script you’re trying to use? If the M5 command comes before the dwell, that would make it fail. There is nothing in our code that would be filtering out the command, so it’s going to come down to how the controller interprets it, and when.

it’s a brand new install, switched from Smoothie to grbl so not much in these scripts as of now. My current end gcode script for tests:

G4 P3
G90
G1 X0 Y0 F1000
$1=0
M9

or

G90
G1 X0 Y0 F1000
G4 P3
$1=0
M9

My wish is to keep the fume extractor on for few extra seconds before job ends.

It could be the $1 command - those generally aren’t meant to be streamed, so it might terminate buffering.

I believe i found the culprit.
i have switched “Return to Finish Position” OFF and now G4 works in both start and end scripts. i still need to add M7 as the first command at the end gcode list of commands because lightburn adds M9 at the end of the job by default and so the fume extractor relay flickers fast OFF and back ON. this is not perfect by all means but it’s a workaround. I might add a small capacitor to the optocoupler relay input for eliminating the short jump in voltage. please check on your side if this can be done in a more appropriate manner. thank you.