Re: Mach 3 Laser Control ...
Whether you need isolation for firing the laser will be specified in the documentation for the laser controller.
Also consider wither Mach3 is creating the delay. There are spin up and spin down delays in Mach3. These are usually to allow the spindle to come up to speed and to slow down to stop.
If you look in the Config->Ports&Pins->Spindle Setup tab you will see the;
CW Delay Spin UP
CCW Delay Spin UP
CW Delay Spin Down
CW Delay Spin Down
Set all these to 0
Cheers,
Peter
3 Attachment(s)
Re: Mach 3 Laser Control ...
Peter,
Thank you for the reply. I have attached some photos to illustrate the effect of the delay on the output.
This first image shows results using M03/M05 without setting delay to zero. Laser goes on and there is a delay before movement and at the end of movement.
Attachment 274820
This second shows results using M03/M05 with all delay set to zero. Laser goes on and there is less delay before movement and at end of movement.
Attachment 274822
This third photo is photoshopped to illustrate what happens when I switch from M03/M05 to M11P2/M10P2. These are supposed to be "immediate" commands that commence the moment there is movement. The corner is supposed to be closed.
Attachment 274824
This was the lower left hand corner of a rectangle.
G01 X1 Y1
M11P2
G01 X3 Y1
G01 X3 Y2
G01 X1 Y2
G01 X1 Y1
M10P2
G01 X0 Y0
It seems that the motion starts before the laser is firing.
I don't know if because there is a ?ms delay in the relay or if the laser PSU has a ?ms delay in the firing of the laser.
Re: Mach 3 Laser Control ...
Hi Steve,
I don't have experience with laser systems, but the relay is most likely causing the delay. Does the laser documentation provide a recommended interface circuit?
If you need to use the relay you could possibly use a custom macro that calls M3 then delays for the correct number of milliseconds to cater for the relay operating although I don't think this will be very successful.
Since you are using a laser, you should probably be using the "Z is 2.5D on output 6" setting in Mach3 general config.
With this setting output6 goes active when the Z axis goes negative. That way, you can use M3 and the S word to generate the PWM power signal all the time, then to turn on the laser in G code with a negative Z value.
Also this problem must have been resolved by others using similar setups with lasers. Have you searched through the forums to see if someone else has solved this issue.
Cheers,
Peter
Re: Mach 3 Laser Control ...
Peter,
Thanks for the assistance and tips. I've got the laser firing on and turning off. I used a transistor (and resistor) wired to pin 17, collector to 5v "L" and emitter to "Gnd". When Z goes neg then pin 17 is active at 3.34v, we have a connection from L to Gnd and the laser fires. My testing makes me think the on and off is "pretty fast", but I wouldn't know how to quantify it.
Just fyi - the digispeed controller works well even in analogue mode. I've got a pot to control input voltage. On the output side, I've got a free harbor freight digital multimeter wired in situ so I can really see the relationship between, my turning of the pot, the output voltage and laser power.
Thanks again
Steve