mkrabset / krabzcam

Online CAM tool for generating G-code from vector graphics and bitmaps
77 stars 8 forks source link

M3 vs M4 for laser #18

Closed risacher closed 2 years ago

risacher commented 3 years ago

Modern versions of GRBL have a "laser" mode, which makes a distinction between M3 and M4 for laser operations. (See https://github.com/gnea/grbl/wiki/Grbl-v1.1-Laser-Mode)

M3 turns the laser on in constant-power mode. M4 is "dynamic power mode" and "will automatically adjust laser power based on the current speed relative to the programmed rate. It essentially ensures the amount of laser energy along a cut is consistent even though the machine may be stopped or actively accelerating."

This could be handled in a post-processing step, but it might also be convenient if there was a way to do it right in KrabzCAM.

risacher commented 3 years ago

Not sure the best UI for this. Maybe separate operations for laser(cut) vs laser(engrave)?

mkrabset commented 3 years ago

Hi, thanks for your input! How about adding a new parameter 'Laser ON command' for operation 'FOLLOW_PATH_LASER'...with a dropdown for choosing between M3 and M4. Would that solve this issue? -Marius

risacher commented 3 years ago

From my perspective, absolutely.

mkrabset commented 3 years ago

I've added the 'Laser ON command' (M3/M4) parameter.

image

Please test it and let me know of any issues. -Marius

risacher commented 3 years ago

Sorry - I've got the machine set up for a drag knife project (Also using Krabzkam!). I'll test as soon as I reconfigure back to laser.