So I have been working on a tool for a laser engraver on the tool changer. I have designed a mount for the laser on the tool changer but I think it still needs some tests, which brings me to my question as I am testing the laser I am trying to make sure the mount has enough air flow going through it to cool the laser diode as well as push the smoke away to prevent charring and so on,My problem is as follows;
I created a new tool ( as the mount i designed is a bit deeper than what is allowed on the tool changer I am mounting it manually for now), Disabled heater 5 and in the tpree4.g file I set the machine into laser mode using the M452 command (M452 P5 R255 F200 S1). when I try to do cut moves the laser only fires for the first move then dose not fire again until the next M3 Command where it fires for the first move again, I have searched and under stood that this is a safety measure implemented in the duet firmware and my understanding is that using the S1 parameter should enable sticky mode but that is not the case, I am trying to find a solution other than a post processing script. I am using LightBurn for the laser gcode generation. a sample of the gcode is below for reference.
If you can spot what am I doing wrong I would be grateful.
; LightBurn 0.9.07
; Marlin device profile, absolute coords
; Cut @ 300 mm/min, 50% power
G0 X91.62 Y51.19 F3000
G1 X91.76 Y50.98 F300 ;only move that fires the laser
G1 X91.93 Y50.8
G1 X92.13 Y50.65
G1 X91.62 Y51.19
G0 X86.17 Y50.43 F3000
G1 X86.51 Y50.38 F300 ;only move that fires the laser
G1 X86.85 Y50.4
G1 X87.18 Y50.5
@Smiely I have not got a laser cutter but my understanding is that M3 is use to enable/disable the laser but you then still need to command the laser is fired using G1 S1 or G1 Exxx, from the documentation:
This mode enables handling of a laser pin and makes sure that the laser is only activated during G1 moves if laser was enabled or E is increasing. G0 moves should never enable the laser. M3/M5 can be used to enable/disable the laser for moves. Logical pin numbers for the P parameter are as defined for the M42 and M208 commands. If a heater or fan output is used to control the laser, you must disable the corresponding heater (see M307) or fan (see M106) first.
From G1 documentation:
Snnn In firmware 2.02 and later, when switched into Laser mode (see M452), this parameter sets the laser power. When not switched into Laser mode, and always in firmware 2.01 and earlier, it defines the move type (see the description of the H parameter).
So you probably need:
G1 Xxxx Yyyy Sn
"Very important*! If you use M452 to put your machine into Laser mode and are running Firmware 2.02 or above, you must replace all S parameters in G0/G1 commands in homing files etc. by H parameters. This is because S is now used to control laser power.
I am refering to @dc42 statment in this post
Advance warning: in 2.03beta3 the G1/G2/G3 S parameter will only be sticky if you add parameter S1 to your M452 command.
which I did but it dose not seem to work!
Maybe you need an S parameter to a G1 move to make it sticky, and just the M3 isn't making it sticky?
Correct me if I am wrong, but my understanding is that the M452 S1 should enable laser mode with sticky pwm value meaning once I issue a M3 S150 for example then all G1 commands that follow until a M4 or M3 Sx is issued laser should be on with power 59% (100*150/254). That is not happening so I am asking am I setting it up incorrectly or is this a bug or has this feature been disabled for some reason
The weird thing is that I can not find any mention of the S1 parameter fo the M452 command in the Duet Documentation
Suppose its open to interpretation, I'd say if you make something sticky, you first have to set it. I don't see any point in having a parameter set for M3 affect G1 in that respect; it would make about as much sense as changing the feedrate in a G1 move when you change the PWM frequency of a fan with M106
but that is not the same is it, M452 sets the machine to "laser mode" S1 enables sticky mode exactlly the same way the firmware interprets the feed rate it takes the first instance of the feed rate and only changes when you issue a move or G0/1 command with F parameter other wise the feed rate is the same although you don't have to put it in every move command! Fan pwm in this example is a totally different setting that has its own commands.
You almost got the point, however you cannot set the sticky feed rate for G1 without having F in a G1 move, so its reasonable to think S would behave the same way; but if you insist on not trying adding a S parameter to the first G1 move then I guess you'll have to try something else.
I understood what you want to say just now, english is not my first language, I will try it and report back.
@Smiely, you are right, the M3 command should certainly be sticky if you use the M452 S1 parameter. However, the preferred way of driving laser cutters is to specify the laser power in the G1 S parameter instead of using M3. LightBurn has a configuration setting for this.