Laser GCode P parameter

I’m just looking through the GCode generated by Luban for the laser module, and there’s a strange parameter in the M3 command.

; G-code START <<<
M106 P0 S255
G0 F1500
G1 F500
G0 X-42.35 Y-29.56
M3 P100 S255
G1 X-42.06 Y-29.56
G0 X-41.78 Y-29.56

It’s all good until the first M3 command. M3 starts the spindle (turns the laser on). I can’t find any reference to the P parameter. S (S255 in this case) is used to set the spindle speed in standard GCode, and it’s used here to set the PWM period for the laser. in this case, it’s set to 255, which means the laser is at full power. The P parameter appears to be a reference to power level (0%-100%), but I can’t find any reference to it anywhere.

There was another topic on this more recently, but from that I picked up that it was a secondary way to do the same thing as S, just as a percentage (and yes you interpreted the S parameter usage correctly). P values were seen being set by other users g-code to match the S values (M3 P50 S127 for example), but no one was as of yet sure if they were required or what.

Maybe this will clarify?

Ah, no, not really. That documentation on Github doesn’t mention a P parameter either. S is standard G-Code (stands for spindle speed).

That’s weird, I thought I encountered it…
Maybe it’s just to send power information to the Display?