Ed Nisley's Blog: Shop notes, electronics, firmware, machinery, 3D printing, laser cuttery, and curiosities. Contents: 100% human thinking, 0% AI slop.
For example, this would generate five square waves:
Gray bars 10-90
The bars are 10 pixels wide, so scaling the image at 254 dpi makes them 1 mm wide:
LightBurn – bandwidth test pattern setup
As before, the first and last bars are 100% (white), with 0% (black) bars just inboard. The other bars are 10% and 90% to stay a little bit away from the 0 V and 5 V limits. I set Lightburn to invert the colors so that 100% = full power and 0% = beam off.
Engraving the pattern at 100 mm/s makes each bar 10 ms wide and the risetimes and falltimes are easy to see:
Tube Current – analog – gray bars 10-90 – 100mm-s – 10 ma-div
[Edit: Clicked the wrong picture.]
Although it’s a bit handwavy, a 1.5-ish ms risetime suggests a single pole (ordinary RC) time constant τ = 700 µs = 1.5 ms/2.2, so the controller’s output filter cutoff would be around 200 Hz = 1/(2π τ).
The laser tube current looks a little slower than that, so there’s a definite tradeoff among engraving speed, edge crispness, and power level.
The L-AN terminal produces an equivalent analog signal:
Ruida KT332 – analog laser control wiring
The power supply accepts both analog and PWM signals on its IN terminal, so no rewiring was needed on that end:
OMTech 60W HV power supply – terminals
This test pattern came in handy again:
Gray bars
The pattern has white bars on the left and right edges as markers. I invert the pattern in LightBurn so that white produced 100% PWM and black produced 0% PWM.
The L-AN output produces 5 V for 100% power and 0 V for 0% power, with other power fractions spread out in between:
Tube Current – analog – gray bars – 10 ma-div
The traces:
1 X axis DIR, low = left-to-right (yellow)
2 L-ON laser enable, low active (magenta)
3 L-AN analog voltage (cyan)
4 tube current – 10 mA/div (green)
Engraving that pattern in scrap acrylic looks like you’d expect:
Analog mode acrylic engraving
There’s little trace of the discrete intensity levels in the acrylic trench and the scan interval is a rather coarse 0.2 mm.
The PWM signal does not appear in that scope shot, because it runs at 20 kHz and is a blur at 20 ms/div.
It’s worth noting that the tube current has large startup spikes at low power levels in both PWM and analog control, so the spikes are generated internal to the power supply and have nothing to do with the PWM input signal.
Another test pattern using constant power:
Pulse Timing Pattern – 1 mm blocks
At 10% power the analog output is about 0.5 V:
Tube Current – analog – 10pct 250mm-s – 10 ma-div
At 50% power the analog output is a constant 2.5 V and the tube current settles at a constant 12-ish mA, about half of the power supply’s maximum 25 mA:
Tube Current – analog – 50pct 250mm-s – 10 ma-div
Obviously, controlling the laser power to intermediate values using an analog signal does not involve switching the current between the supply’s minimum and maximum values: there are no PWM pulses involved to do the switching.
I suspect the analog output comes from the PWM signal run through an internal low-pass filter similar to the one in the power supply. Based on the PWM frequency measurements and squinting at the rise / fall times, the analog filter cutoff is probably around 1 kHz.
Other than bragging rights, I don’t see much advantage to using the analog signal in place of PWM.
Laser cutter controllers generally set the tube current (and, thus, beam power) through a digital PWM signal to the HV power supply. Confusingly, the same power supply input terminal can receive an analog signal controlling the output current. Both signals have the same 0 to 5 V range.
I have yet to see a PWM frequency spec for any HV laser power supply, although surely there must be one. The specs for the Cloudray power supply on my shelf seem typical:
Cloudray Laser Power Supply Features
I have no spec sheet for the replacement power supply OMTech sent, which is now installed in the laser and is measured below. I believe all similar HV laser power supplies, regardless of the nominal brand, are essentially the same inside and will have similar, if not identical, behavior.
I set the KT332N controller for a 200 ms pulse when poking the front-panel button, which is long enough to show any interesting behavior, and changed the PWM using its awkward controller interface. LightBurn provides access to the “vendor settings” which include the PWM frequency, which I set as needed:
LightBurn Vendor Settings
So, we begin by varying the PWM frequency with a constant 50% PWM …
The default 20 kHz:
Tube Current – 50pct 20kHz PWM – 10 ma-div
The upper half of the scope screen shows the entire 200 ms pulse, with the small slice near the middle appearing zoomed across the bottom half. The readout just above the buttons along the bottom gives the measured PWM percentage and frequency. The green trace shows the tube current is about 12 mA, half of the power supply’s maximum 25-ish mA.
The Tek current amplifier has plenty of thermal drift that I have not attempted to compensate, so always eyeball the average current with respect to the baseline around the pulse in the upper half of the screen.
No trace of the 20 kHz PWM signal appears in the tube current, which runs at a constant 12-ish mA for the duration of the 200 ms pulse.
Increasing the PWM frequency to 100 kHz (!) produces no change, although I cranked up the zoom timebase to better show the PWM pulses:
Tube Current – 50pct 100kHz PWM – 10 ma-div
Reducing the PWM frequency to 10 kHz produces very small ripples in the output current corresponding to the PWM cycle:
Tube Current – 50pct 10kHz PWM – 10 ma-div
At 5 kHz the tube current becomes sinusoidal, with an average around the same 12 mA produced at higher frequencies:
Tube Current – 50pct 5kHz PWM – 10 ma-div
The sine wave current is about 90° out of phase with the square wave PWM, although much of that must come from delay through the entire power supply, rather than just an RC low-pass filter.
At 2 kHz the tube current takes on a decidedly lumpy look:
Tube Current – 50pct 2kHz PWM – 10 ma-div
At 1 kHz there’s definitely something odd, perhaps a resonance, going on inside the supply, although the average current remains 12 mA:
Tube Current – 50pct 1kHz PWM – 10 ma-div
At 500 Hz the PWM is slow enough that the tube current resembles the output of an integrator, rather than a filter:
Tube Current – 50pct 0.5kHz PWM – 10 ma-div
At 100 Hz, the digital PWM signal is so far below the filter cutoff that it’s behaving as an analog input, with the tube current ramping between minimum and maximum:
The current has regular full-on glitches halfway through the “off” part of the PWM signal, so running at absurdly low PWM frequencies does not prevent them. Also note that the PWM signal does not control the current at the same speed as the L-ON enable signal, due to the low-pass filter rolling off the transitions.
Now, holding the PWM frequency constant at (the absurdly low) 100 Hz and varying the % PWM duty cycle …
At 30% PWM, the output current becomes triangular due to the low-pass filter:
At 99% PWM, the output stays at the power supply’s 24 mA maximum output, with small downward ramps marking the 1% off times:
Tube Current – 99pct 0.1kHz PWM – 10 ma-div
Some observations for this HV power supply, which seems typical of similar supplies sporting other “brand names”:
A PWM frequency below 10 kHz introduces output current variations due to the power supply interpreting the PWM waveform as a somewhat analog input, rather than a purely digital signal. This effect increases as the frequency decreases.
An Arduino-speed digital PWM near 1 kHz will be interpreted as an analog signal, with the tube current varying significantly around the PWM signal’s average analog value. It does not control the current in an on-off digital manner.
Due to the effect of the low-pass filter, the PWM signal cannot switch the tube current between “full off” and “full on” at any frequency. The current will always follow a ramp with a slope controlled by the filter rolloff, so low PWM inputs will have low peak currents.
We have accumulated enough measuring spoons (typically from garage sales) to dedicate them for specific purposes, which means keeping them from wandering away:
Jar lid measuring spoon holders
The design is simple enough:
Jar lid measuring spoon holder – LB layout
The slot is a rounded rectangle about 2 mm larger than the spoon handle in both directions, inside a rounded rectangle large enough to put the handle just clear of the jar. The curved side comes from outsetting the jar lid OD by a millimeter (for the double-sided foam tape), then subtracting that circle from the holder.
So, yeah, they’re custom-made for the spoon and jar in hand.
It has a drain hole in the bottom that made this whole thing practical, because a PVC pipe hot-melt-glued atop the drain maintains the water level in the reservoir without any further attention:
Silonn icemaker – drain pipe
The water line from the laser, formerly run directly into the bucket, now goes into the reservoir and through the drain into the bucket. The bucket holds about five gallons of water, with the pump submerged in the bottom.
The icemaker pumps water from the reservoir into the little icemaker tray, freezes nine little ice bullets, and scrapes them into the reservoir:
Silonn icemaker – new ice dump
It does that about every eight minutes.
A plot of water temperature vs. time shows what happens:
Silonn icemaker – cooling water plot
It’s as exponential as you could want.
The ice bullets drop into the reservoir and melt there, the cooled water continuously flows into the bucket, and mixes with the rest of the water before being pumped back through the laser. As a result, there are no sudden water temperature changes and the laser remains perfectly happy.
Some numbers for an idea of the cooling capacity:
Freezing 28 pounds = 12.7 kg of ice a day (which, in normal use, would require me to babysit the thing overnight to empty the ice and refill the reservoir) works out to:
12.7 kg × 334 kJ/kg = 4.2 MJ
Spread across 24 hours, that’s 49 W of cooling power. There will be a bit more going into the chilled water surrounding the bullets, but most of the energy goes into the water-to-ice phase change.
Run another way, 5 gallons of water is 42 pounds. The initial cooling slope looks like 2 °C = 3.6 °F in 2 hr, which is 75 BTU/hr = 23 W. However, the water is cooling the laser (which was inert except for one brief cut) as well as the basement, plus (most importantly) there’s a water pump dissipating 20 W submerged in the bucket, so the icemaker is delivering at least 43 W, which is pretty much its rated performance.
It’s obviously incapable of keeping up with a laser doing full-time production work, but for my simple needs it seems better than dunking ice packs in the bucket.
More study (and maybe getting an air-cooled water pump) is in order …
Anything would be better than just taping some gel filters to the front of the bare photodiode package:
Laser output – photodiode kludge
Right?
I heaved the slab of ½ inch black acrylic left over from the Totally Featureless (WWVB) Clock into the laser cutter and, two passes at 90% power later, had a somewhat lumpy 32 mm donut with an 11 mm hole in the middle. Because acrylic is opaque to the IR light from a CO₂ laser (which is why it cuts so well) and black acrylic is opaque to visible light (which is what the photodiode is designed for), this is at least as good as an aluminum housing and much easier to make.
Chuck the donut into Tiny Lathe and bore out the hole:
PIN-10D photodiode filter holder – boring ID
When it’s a snug fit to ½ inch brass tube (about the same size as the photodiode’s active area), flip it around, and bore the other size out to fit the photodiode case.
Ram the tube in place, grab the large recess, and center the tube:
[Edit: Got that backwards: I bored the big recess first.]
Skim most of the OD down, then, because I am a dolt forgot to put a spacer in there, flip it around again, get it running true (the chuck aligns the flat side):
Even though they’re pretty much transparent to thermal IR, a focused IR laser beam cuts them just fine. The little tab at 6 o’clock (remember round clocks with hands?) keeps the cut circle from falling out.
Drill & tap for an M3 setscrew to hold the photodiode in place:
PIN-10D photodiode filter holder – parts
Put them all together:
PIN-10D photodiode filter holder – assembled
I must conjure a better mount for the thing, because this is way too precarious:
PIN-10D photodiode filter holder – test install
Early results suggest it works better than the previous hack job, without ambient light sneaking around the edges of the filter pack.
The test patterns were engraved at various power levels, which was the whole point of the exercise: I was looking at the current waveforms, rather than the acrylic. Despite that, the result should be solid blocks with no speckles in between, which is not quite what happened.
See that isolated spike left of center, where the L-ON signal (magenta trace) is high? That shouldn’t be possible.
Setting the scope to trigger when the L-ON signal is high (= laser power supply disabled) and the tube current is more than a few milliamps (= laser beam active) captures those errant dots.
Sometimes a spurious pulse happens just after L-ON goes high to disable the HV output:
The X axis stepper DIR signal (yellow trace) shows the laser was scanning right-to-left, so the glitch will be just to the left of the 2 mm block in the pattern. In point of fact, it’s about ¾ of the way down the right-hand column:
Engraving Target – stray laser pulses
A closer look shows a distinct circular pit at the end of the line:
Engraving Target – stray laser pulse – detail
The two left-to-right lines bracketing that line also show how the high-intensity pulses affect the laser beam startup intensity during a scan line.
Sometimes the glitches happen quite some time after the laser turns off:
The glitches are not always full-scale events. The two nearly invisible pulses just to the right of the block (bottom green trace) make the smaller dots you can see on the targets:
Tube Current – 20pct – glitch pulses – 10 ma-div
As far as I can tell, spurious dots happen most often with current levels around 20% PWM, less at 10% PWM, and rarely above 30% PWM. I think it has something to do with the chaotic spikes that the power supply produces at lower currents, instead of the relatively stable outputs for higher currents.
The only way to reduce the number of speckles is to use higher power, which will require higher scanning speeds to achieve similar results. Unfortunately, higher speeds give the power supply less settling time, so there may be no good answer.
I haven’t been able to find any “official” schematics for the HV laser power supplies shipped in typical lasers (there are many terminal wiring diagrams), so I have no idea how the L-ON signal controls the output current. Apparently the oscillating chaos inside the power supply occasionally punches through the output switch, which isn’t too surprising given the voltage and power levels in there.