Intentional Firing Delay

Hello there.
I have a problem that requires introducing a 12ms delay at every firing sequence (either hardware or software wise).
So let me explain the problem. I have changed my X axis of a Chines laser with a DC servo motor that is able to go up to 3000mm/sec, mechanically everything is fine and max speed is achieved without any problem. The problem though is the way the drivers is designed, due to the complex algorithms for PID and advanced tracking options there is a delay of approximately 12ms on the moves, so the move is constantly 12ms behind.
So is there a way to introduce a constant delay to the laser firing?

I know that Offset is kind of for this reason, but since the limit there is 30mm, I reach the limit at around 1500mm/sec. What more, it is painful to try to offset every single usable speed just to compensate this 12ms delay.

I have put a lot of time and money for this upgrade and I don’t want to discard it because of this issue.

The controller is a Ruida and the laser PS is a DY-13 with a RECI W2 Tube.

Thank you all in advance.

If I understand correctly, the X axis position will lag behind the Y axis position by 12 ms at any speed. In that case, a constant 12 ms delay in the laser firing cannot compensate for X and Y axes with different response times.

For example, a 45° diagonal line will start with a short vertical section because the Y axis will begin moving first. As the X axis starts moving (presumably accelerating harder to reach the same speed), the line will bend to 45° as the laser begins firing. The other end of the vector will have a horizontal line extending beyond the endpoint where the Y axis slows to a stop as the X axis continues for another 12 ms.

The laser will begin firing after the first vertical part of the path and stop at the end of the horizontal section, so the “straight line” will start in the wrong location with a missing section and end with a kink.

In addition, I think the motion planning algorithm responsible for joining vectors must have both axes responding simultaneously. If one axis has a delay, adjacent vectors won’t meet at the intended point.

Replacing the Y axis driver & motor with a similar servo drive would let the motion control work better, although I think a constant time delay will still distort the geometry.

1 Like

Are you using this exclusively for scanning operations? Otherwise @ednisley brings up a fatal concern.

As for the particular issue at hand I guess the most obvious question is can you reduce the latency down from 12ms? Sounds like 6ms would get you to the point where scanning offset adjustment would do what it needs to do at full 3000 mm/s. Also, you shouldn’t need to define every speed. I believe it’s meant to extrapolate between speeds although I may be incorrect about how it works.

Are you able to disable some of the algorithms to get latency down?

At least as of now I’m not aware of anything in LightBurn that will do what you’re looking for other than the offset adjustment. And that can’t solve the issue that @ednisley brought up.

If he puts in a Y servo, isn’t the delay still there? Meaning won’t the laser still be off some amount of time? Now in both axes?

Don’t know what you’d use 3000mm/s for, except getting somewhere quickly … but

:smile_cat:

Thank you for your response and your explanation. Your concern is something that I did not think of and you are write to worry about, but my plan is to install a servo on Y axis too. I have all the electronics in place and I also have the DC motor, but not the time to do it, as it is a little more complex than the X axis. Initially I want to do some work on engraving that will me pure scanning. So I don’t think that I have to worry about Y axis for the moment. But as you noted, when it comes to cutting it will be a problem.

Unfortunately it is not up to me to do that, and the information of the 12ms comes from the creator of the drive. When I install The servo on the Y axis too, everything will be in sync, except the firing time. So if I find a way to introduce a delay, should be fine. The perfect solution would be to do it hardware wise with some kind of circuit, but I don’t know if it is doable. I know that there is an on/off line and a PWM line, but I have no idea how they interact.

Is the tradeoff in latency worth the gain in speed? What problem are you solving for?

Even if you can solve for the scanning scenario using offset scanning adjustment that’s not a generalized fix for overall latency. Cutting will introduce an entirely different problem set.

I suspect this will lead to a whole series of compounding problems. Latency and lasering don’t pair well. In CNC operations you can generally get away with something like this because you basically enable a spindle, give it time to run up and at that point you just plow away without regard to rapid on/off of the spindle.

The main problem was that I was at the minimum limit of speed and power for engraving laser leatherette . And the solution was to increase speed. The solution of servo was the best I thought because it offers not only speed, but also smoother and quieter operation.

Interesting. It may have been easier to go with a smaller tube for your particular need.

Alternatively, did you look at lightening up your laser head assembly as much as possible? That may have given you enough headroom to increase speed without upgrading your driver/motor.

Do you have a sense what speeds you need to achieve to get the engraving that you want with the current tube?

Maybe around 700-800mm/sec would have been ok I suppose. But then again doing things much faster is a bonus.

700mm/s, depending on the dpi, is probably going faster than your lps/tube can respond

:smile_cat:

For anyone that may be in the same situation in the future, there is an easy way to bring everything in sync, even the Y axis being on stepper, with a microcontroller. I used an Arduino Mega since I had it in hand and for 2 other important reasons.

  1. The pins are 5v rated so it was what was required for both the Ruida controller and the Laser Power supply.
  2. It has a lot of pins, but more importantly it has 2 full pin separate ports (it has more that 2, but I needed 2. One for input and one for output).

Ports are critical because you can read and write the whole port without any delay, so practically I have 8 pins that can be read at once, buffered for as long as I want and when the buffer is full I can start reading the buffer and output it to the output pins at once.
For my need I ended up with a buffer around 3000 entries long to compensate for the 12ms delay I have.
At the moment I have overridden the laser power supply PWM and On/Off Line and the Y axis Step and Dir pins.

It works like a charm.

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.