Why RuiDa

Jack I’m really more interested in “why RuiDa” and only peripherally “how RuiDa” since the how is just wiring/assembly. I get that there are 2 PWM output from the Ruida along with an analog output and most people use the 2 PWM outputs. I get that one of the PWM outputs is used to control the laser ON/OFF input which on the LPS is LPS-L ( LPS-H could be used if you invert the default Ruida output ). I also get that the 2nd Ruida PWM output is used to control the LPS power level via the LPS-IN input.

All good there and I get this. Where I was looking for clarification was what’s going on with the Ruida PWM out controlling the laser power level( LPS-IN ) because with other controllers, LPS-IN is a fixed signal and as such it does not change no matter if the task is cutting 3mm plywood or 10mm plywood, no matter if engraving a solid box or engraving an image of the Mona Lisa. LPS-IN is unchanging on all but Ruida controller and the M2Nano(user does manual control only).

So here we have 2 LPS inputs( L and IN ) where the Ruida connects to both and sends PWM signals to both AND we have controllers(not M2Nano) which do computer/software control of the LPS to create designs and do cutting at different power levels but Ruida seems to vary the PWM at LPS-IN dynamically and under computer control, for the power settings requested by the user at design time BUT the other controllers(not M2Nano) product the same results by only varying the PWM signal associated with the LPS-L input.

If this is the case, and Ruida dynamically varies LPS-IN power setting PWM during the operations then it is doing something very different at LPS-L compared to the other controllers(not M2Nano).

My goal is to try and understand these differences and consider if one is better or worst than the other. I do this because people( a few of them ) have told me that LightBurn and Ruida is great, better, and the cats meow and I should install one as fast as I can and NEVER have they been able to tell me why it is better compared to the other controllers many people use(not M2Nano) running firmware like GRBL, Smoothie, RepRap Firmware, etc.

There is only one pwm output from the controller LPWM.

The other is ‘laser enable’, L-ON, it is not a pwm signal.

The pwm output is set to the layers power percentage value when that layer executes. There is no way to control the ‘laser on’ in any similar manner.

‘Laser on’ (L-ON) is determined by the softwares interpretation of whatever artwork you are trying to lase.

Sort of, except the user is handling one of the power controls, not the computer.


If you accept the fact that an analog or digital input to the IN terminal internally produces a pwm ‘power control’ of the lps, then I don’t think it matters if you swap them.


L-ON and LPWM are the two signals that are normally wired as

L-ON → L of the lps
LPWM → IN of the lps.

If I do this:

L-ON → IN of the lps
LPWM → L of the lps

The pwm is going all the time, turning the lps on/off at whatever rate. The laser will not lase until L-ON goes active, enabling the laser to fire at 100%.

The pwm at L is giving you ‘power control’ by enabling and disabling the lps itself.


You would need to configure it so the signals are inverted as L is active low (could use the H input) and the pwm is active high…

I think you can change the L-ON to an inverted state, but I don’t think the pwm has this option…

Does this make any better sense of it?

Doing this brings up questions about the response time of the lps…

:smiley_cat:

I just looked at the Ruida outputs L-ON1 and LPWM1 along with L-AN1 and as expected, L-AN1 is a varying voltage based on what’s needed for laser output power and this voltage will vary even on a cutting/vector design if you set the min/max power level differently. The reason it varies is because there are acceleration changes unless you are doing the most basic of straight lines.

So I see the analog voltage on L-AN1 varying on the default Doiley design of a stock RuiDa controller and what we see on the purely digital laser power output control( LPWM1 ) is a TTL waveform with a varying pulse duration. Call it what you will but this TTL waveform will vary as the analog voltage varies based on the laser power changes based on speed.

The other TTL pulse varying modulated signal out of the RuiDa controller, L-ON1 and is generally connected to the LPS-L input, only turns the laser on and off based on the design requirements. ie if it’s doing a large circle vector then it will be 0V for the duration of the movement of the head around the circle circumference. If it’s doing an engraving of a 200mmx200mm box the it will be low(0V) for every scanning line across the box in then go high(5V) while the head overshoots the line, moves to the next line in Y axis, starts moving and then gets to the pixel before the next line. Or close enough, and then it turns the laser back on by setting LPS-L( RuiDA output L-ON1 ) to 0V again.

The just of all this is that the RuiDa controller manages 2 control lines to the LPS and varies the signals on each in concert as it’s creating the design either stored on FLASH or sent via LightBurn.
Yes, there are cases where the laser power control does not need to change during the design making process or part of it but the fact is RuiDa L-ON1 and Ruida LPWM1/L-AN1 work together to control the LPS via LPS-L and LPS-IN. UNLIKE other controllers like GRBL based controllers and Smoothie based controllers which do not change or even connect with the LPS-IN signal.

I think you’re on to it.

I think of the pwm output and analog outputs as the same ‘animal’ one is just older technology. Some of the newer controllers do not have an analog out, only a pwm. This is a Trocen AWC708. Note the laser controller has no analog output, only pwm. I think you will see analog controls fade away as they are old technology for controls. It has ttl (laser enable) and pwm only.

The servos I used had analog control signals. Ttl was still expensive and it took a number of parts to make something useful from them. Some of the motors we had that were variable speed were analog driven with a 0 to 10v range. All of these had a motor controllers, but all the signals were analog.

My suspicions are that the analog input to the lps is from the ‘early days’ and will ‘go away’…

As I mentioned earlier, I think the ‘pot’ approach lowers the overall cost along with their controller. Along with removing computer control lowers cost even more. My reading indicates the K40 controller is the first thing most users have replaced.

I would think that the pwm/analog output originate at the same place, so I’d guess they are just different ways of interconnecting to other available devices. Similar to the H input to the lps, just an inverted L input. Makes connecting a little easier.

The pot is, of course illusionary as it’s not really limiting power in a strict sense of the word. You still get full lps current when it does lase.

:smiley_cat:

I forgot about that… Since you had a resistor on the laser output and put your scope on it, did you see laser output power drop based on control signal on LPS-IN drop?
ie did the laser put out lower laser pulse power when a 50% duty cycle was on LPS-IN?

@dougl I am not sure you have gone onto Don’s website and looked at his in depth explanation of how the K40 power supply works. Unfortunately it is not laid out to easily navigate but once you start, you can get a good idea on the PS workings.

1 Like

Thanks for bringing that up. I had looked at it some time ago but without purpose so stuff like the following did not sink in. Now I see how this works but I would like to hear from Jack on what he saw with laser output power control since he instrumented it.

1 Like

What is frustrating is that there are two ways to control the PS with one being better than the other due to the way the PS works. Don does a great job explaining why due to the design of the PS.

1 Like

and I get people telling my RuiDa is great but ask why and get stuff like it’s faster, it has DSP and it works with LightBurn… I just saw Russ Sadler put a $300 RuiDa controller and drivers into a K40 which is cool but I don’t recall him saying why. Maybe he did say why they are great in one of his other videos but I’ve not run across it or recall.

Here is an oscope capture @jkwilborn made with the high frequency stuff(blue) being measured from a resistor on the low side of the tube(IIRC), the purple is LPS-L and the yellow is a stable power setting on LPS-IN all driven via a RuiDa controller hence the 2 control traces(purple,yellow).

You can see the high frequency pulsing of the laser and you can see the laser pulsing is on during LPS-L(low) but I don’t get all the variations in the laser power output and the 2nd laser ON signal shows an odd laser output signal for half of the ON time.

What I don’t get in @donkjr documentation of his LPS analysis is why he only considered a LPS-IN control with both a PWM signal and a POT. Why not the setup the RuiDA designers recommend(and users) where the RuiDa LPWM1 output is driving LPS-IN to dynamically set the laser output power?
Or did I miss that section?

There are some conversations in which @donkjr discusses the difference between driving the two inputs. Unfortunately I’m unable to find them right now. Hopefully he will jump back in when he sees this discussion.

1 Like

I have no way to measure a pulse, what I can see is the current across the mA meter. That is where the blue trace comes from. If I just measure voltage it goes pretty high and seems to sit there. I think it’s at a potential near the lase point, but I’m just guessing. There is also current flow prior to the lase but it’s in the few mA range.

I know it’s turning on and off, because I can see it at a high scan speed.

You can see the increase of voltage across the mA meter when the pwm pulse goes high. The purple one is the L-ON line and is asserted.

If you check out the screenshot of the scope, you can see the voltage change with the pwm, but what’s really going on to me is still questionable… at least at this low level.

DS1Z_QuickPrint3

It came from here:

:smiley_cat:

Sorry for the delay it’s that time of year and I was out fishing:

Frankly, I am unclear as to the purpose behind this “why RuiDa” thread.

I will do my best to answer the questions.


Scoping a CO2 laser system:

Depending on what you are trying to measure the scope traces won’t be very meaningful unless a means of syncing it with the programmed movement is employed. In addition, imaging a resolution pattern why scoping would help us understand the electronic response of the system.

I started down this “scoping” road some time ago with the intent of measuring the CO2 gas laser response time. Gass lasers were not typically used in a switched mode. Rather the optical output was switched using various optical interrupting devices.
Then someone helped Russ scope out the anode side of the LPS, which satiated me. That test is on Rus’s YouTube channel. It showed that my suspicion that the laser was not fast enough was wrong.
I did come out of the work with a better PWM DF than many use today.
To date, there are still unanswered questions as to the exact laser firing characteristics. Turns out it matters less than measuring the response at the surface and that’s safer :slight_smile: ! So I moved on

If we want to know the response of the system:
I have suggested many times that testing the response of this system is best done by looking at the “built-in scope”, i.e the image. This can be done by imaging an increasing pattern with increasingly wider lines and spaces. If you want to try this out program a pattern and send it to the inkjet or laser printer.


Not sure I understand this question but let’s try an explanation that follows my logic in the context of this thread.

How the LPS is controlled:
L: this ground true signal enables/disables the supply by controlling the internal PWM control. This pin is connected to the cathode of an Opto coupler so it is not a TTL signal rather it needs solid ground to turn on the supply. In fact, even a small shift from the supply ground potential will disable or cause erratic operation of the supply.

In some supply configurations, the L is also connected to another L pin which is connected to the Laser Test switch on the control panel.

IN: this signal is an analog input that is connected through a 1Khz filter which is connected to the PWM control of the supply. The PWM of the supply is controlled with a 0-5VDC signal whereas 5VDC is 100% DF. This signal has no optical isolation. The supply’s internal PWM controller directly drives the H switch which goes on to create the HV.

I will not elaborate on the other controls because they essentially disable the supply when interlocks and/or the cooling circuit is open.

The original K40 design:
If the machine only “dithered” then the LPS only needed to turn full on/off. The L signal was all that was needed.
Evidentially it was understood that a manual intensity control of laser power was needed.
I did not understand the need for this until I started using my machine.
The IN function provided an intensity control. A pot is a pretty cheap means of analog control and it was placed on the control panel. Its only downside was that it was not very accurate. This is why I added a DVM to the pot’s wiper.

Were not in Kansas anymore [L+IN};
We needed to control the LPS from a G-Code capable controller that could provide greyscale engraving, vector, and yes dithered imaging. Power control had to be provided by a parameter in the controller’s g-code.
The controller I worked with was the smoothie which could provide a PWM output and enable function in one signal. The signal was OFF when no imaging was to take place and ON (some PWM value) when imaging was active.

The initial method of interfacing to the supply was by connecting a TTL signal through a level shifter to the IN port. In fact, I originally used this method but is IMO is a poor design that had many problems.

Then out of frustration caused by not knowing the internals of the LPS I (and others @Paul_de_Groot) started to dissect the LPS.

That is when it became apparent how the L could be used as the programmable port [with a simple open drain] and the IN used as the “intensity” control using the existing pot. In fact, this was much easier to implement as level shifting was unnecessary.

Separation of programed power and empircal adjustments:
After working with the L+ IN configuration and programming in LaserWeb the need for manual control became apparent to me. " I did not like constantly having to go into the program and change the power setting every time I changed materials. I wanted the programmed level of power to be in addition to the empirical (intensity) level of power.

Two empirical settings were needed that were best kept separate from the programmed job:

  • The effect of the imaging substrate. A specific power level will image differently on different materials with varying moisture and other embedded content (glue).
  • The effect of the tube’s changing power vs IN voltage characteristic curve (as the tube is used and/or ages).

A More direct answer:

What I don’t get in @donkjr documentation of his LPS analysis is why he only considered a LPS-IN control with both a PWM signal and a POT.

I did consider other approaches. Based on my actual use of the machine I wanted to retain a manual power control. I still think that is the best approach. But if the user is ok with constant tweaking on the program side, any configuration of PWM"ing IN and L will work. Just be prepared to change all your stored programs when you change the tube, or image on substrates with varying characteristics.

Editorial: I doubt the manufacturers of these machines and controllers care how much the user has to tweak to get good image quality. If they did these machines’ optics and motion control would be better designed.

To some degree, my choice was influenced by the available software and controller. The smoothie and its firmware were a perfect fit as the L signal being the only form of control, it was a composite of enabling and PWM. I also still think this is the best and simplest approach.

Alternate configurations:
Controlling the power (IN) separately from the enable (L) is technically sound. Its what controls the IN

WHOOPS HAVE TO STEP OUT …
… and he’s back!

Continuing on …

Configurations that do not provide an overriding intensity function:

  • A. IN[G-code PWM power control], L[enable only]: whereas IN is derived directly from the G-code

Configurations that provide an overriding intensity function

  • B. IN[Analog power control], L[PWM Gcode power control]: whereas IN is derived from an analog POT voltage, and power control is Gcode driven from L.
  • C. IN [PWM power control], L[PWM Gcode power control ]: whereas IN is derived from an external PWM signal and power control is Gcode driven from L. . The digital panel works this way.

If any of the soft/firmware provided a user interface that could modify the programmed power by an intensity offset that added to the stored job that approach might be sufficient and make the entire practical control of the LPS “computer” controlled. If I was to implement such it would probably be configuration A.

The bottom line is that I chose B because:

  • I wanted a way to override the total power outside the Gcode.
  • IN and L are not TTL inputs. The digital engineer in me wanted IN to be analog and L to be an open drain. I expected this configuration to be less prone to ground shifts and noise.
  • It was simple to implement with a smoothie. Many K40 users did not have the skill for anything more complex.

Why did Ruida use A:
Who really knows but my suspicions are:

  • They do not know or understand the internals of the LPS and its control. I did not for a long time.
  • They do not care (as many designs I have seen don’t) if their TTL outputs work in worse case interface conditions, including noise immunity … as long as they work … sort of.
  • They did not understand or value the need for an intensity control
  • They wanted to enable/disable the laser from the control panels’ firmware. You can do this by turning the power to zero [PWM DF =0] or pulling L high. [not a good safety protocol**]. The K40 digital panel works this way.
  • They copied the multiple Maker builds where the power control is on IN. These makers did so because:
    • They did not realize the smoothies’ power control is a composite and a separate enable was unnecessary. They did not care if there was an intensity control.
    • They wanted software control of the laser’s enable [which violates all safety protocols**].

** laser enable should be a mechanical switch.

3 Likes

Nice catch… was it yummy?

Thanks for the photo…

:smiley_cat:

Both vendors and users are starting to put RuiDa controllers into K40 machines and I’ve been told they are fantastic controllers so while looking into them I noticed they do things quite differently from all the other controllers. RuiDa uses 2 control signals instead of one. Therefore I’m trying to find out if there are any advantages or disadvantages to how RuiDa is doing LPS control or if there are any advantages or disadvantages to doing single LPS-L control.

nice looking fish.

Actually there are two controls to the lps which most of the commercial type controllers use, including the Ruida and Trocen.

The ‘pot’ technique just removes computer control and depends on the operator.

So which system would you think would be the most advantageous and flexible?

A manual ‘pot’ or computer controlled interface?

I know which option I’d pick.

:smiley_cat:

Jack, you seem to fixate on the manual POT control for laser power control as they ONLY way anything other than RuiDa(and Trocen) work and that is not the case. That just is not the case.
Only the M2Nano board requires manual power control via resistive POT or digital POT and all other controller boards get and do computer controlled power control.

Sorry but this is what drives me nuts and what’s driven me to create this post and try to understand the nuances of the TWO systems( seriously, I don’t give a crap about the M2Nano ) of control, RuiDa(LPS-L and LPS-IN) and GRBL/Smoothieware/RepRapFirmware/etc(LPS-L).

@donkjr Your excuse sounds a bit fishy to me!

@dougl Let me trying sort things out for you. Back in the days when we were all trying to figure out how the power supply works, all we had was the L was the enable and the IN was how we controlled the laser power/intensity with a pot.

Don comes along and shakes things up! He finds out that you can actually control the power supply and therefore the laser output, with the L enable input. So now there are two ways you can control the power supply.

From here you need to go through Don’s explanation of how the power supply works and why one input is better than the other or why you would use both to make a better output.