CPAP Hose Dryer: MVP Overview

For all the usual reasons, we’re now confronted with the need to dry a freshly washed CPAP hose:

CPAP Dryer - water droplets in hose
CPAP Dryer – water droplets in hose

Those droplets might not seem like much, but I am reliably informed they produce over-humid air and sprinkle when they migrate into the mask during the night.

Commercial drying machines are available, but seem grossly overqualified and require proprietary foam filters. I wondered if simply pulling air through the hose for a few hours would work:

CPAP Dryer - dried hose
CPAP Dryer – dried hose

Why, yes, it does.

That test took two hours and another with a different hose required about five, but simply “hanging the hose up to dry” consistently produced poor results after three days, so we count a few hours as a win.

I cut the first minimally viable prototype CPAP Hose Dryer from MDF:

CPAP Dryer - overview
CPAP Dryer – overview

Stipulated: MDF is absolutely the wrong material for an air-handling project, because laser-cut MDF stinketh unto high heaven. This was the first pass using cheap material to see how well, if at all, the idea worked.

The CPAP hose goes between the fittings on the bottle and box, with air entering the bottle through a hole drilled in what was its bottom:

CPAP Dryer - filter bottle cutout
CPAP Dryer – filter bottle cutout

An air filter seemed like a Good Idea™, if only to keep ordinary room fuzz out of the bottle and hose. In this Third Pandemic Year, I could simply pull a least-favorite N95 mask from the stockpile and fit a clamp ring around it:

CPAP Dryer - filter clamp installed
CPAP Dryer – filter clamp installed

The motivation for pulling air through the tube, rather than pushing it, came when I realized I could build a much cleaner intake structure by starting with an ordinary HDPE bottle than I could possibly assemble from random parts.

So the fan in the box pulls air through the fitting on the side of the box and blows it out the swirl on top:

CPAP Dryer - fan box
CPAP Dryer – fan box

The box contains a coaxial power jack, the switch, and an 80 mm fan extricated from the Box o’ MostlyFans. I briefly considered an LED, but it’s obvious when the fan runs. The box and swirl cutting patterns come from the invaluable festi.info.

The two slots give the bottle somewhere to stand while idle. In use, the hose is sufficiently unwieldy to require standing the bottle wherever it wants to be, rather than insisting on putting it anywhere in particular.

More details to follow …

Tree Frog Marquetry: FAIL

I thought this critter would look great in marquetry:

Tree frog - on trash can lid
Tree frog – on trash can lid

Posterizing the colors to represent a few shades in my Little Box o’ Veneers simplified the problem:

Tree frog - posterized
Tree frog – posterized

Applying LightBurn’s Trace tool to the various shades produced vector outlines, which I then collected together based on the veneer they should come from:

Tree Frog vector patterns
Tree Frog vector patterns

Which seemed similar to my hand-drawn doodles on a larger image:

Tree frog - sketch vs chipboard
Tree frog – sketch vs chipboard

Before committing to actual veneers, though, I cut the shapes from spraypainted chipboard on a small scale, which showed why this wasn’t going to work:

Tree Frog - auto-trace chipboard
Tree Frog – auto-trace chipboard

It’s facing the other way because I cut the chipboard from the back side, so as to keep the colors reasonably clean and bright.

Contrary to what I initially thought, the automagic tracing routine generates different nodes along a boundary between two colors depending on which side is selected by the color range. Because the nodes (and control points) don’t match exactly, adjacent pieces will have different border shapes and won’t quite match up. The missing pieces at the frog’s rump simply did not fit after the other parts soaked up all the tolerances in between.

So (I think) a better way to do this requires carefully hand-tracing the borders, then using the same path (all the nodes) for adjoining pieces. This mean duplicating the borders for each of the pieces: tedious bookkeeping and layer manipulation.

More study is needed …

Laser Cutter: Scanning Offset Adjustment

Start with the constant-power test pattern:

Pulse Timing Pattern - 1 mm blocks
Pulse Timing Pattern – 1 mm blocks

Set it up on six LightBurn layers:

LightBurn test pattern layers - layout
LightBurn test pattern layers – layout

With useful scanning speeds and powers:

LightBurn test pattern layers
LightBurn test pattern layers

Unleash the laser on a scrap of fluorescent green acrylic:

Scan Offset uncorrected - 100 to 500 mm-s
Scan Offset uncorrected – 100 to 500 mm-s

Measure the distance between successive line ends at each speed, divide by two, then fill in the offset adjustment table:

LightBurn Scanning Offset table
LightBurn Scanning Offset table

Burn another scrap:

Scan Offset - 100 to 500 mm-s
Scan Offset – 100 to 500 mm-s

That looks better …

Not incidentally, it also provides illustrations for an upcoming Digital Machinist column about small-scale engraving-as-machining and why good scanning compensation matters.

CO₂ Laser Tube Current: Analog vs. PWM Bandwidth

With bandwidth measurements in hand, a semilog plot with eyeballometric line fitting makes the conclusion obvious:

OMTech CO2 laser power supply - bandwidth tests - semilog graph
OMTech CO2 laser power supply – bandwidth tests – semilog graph

The top line shows the controller’s L-AN analog output voltage dropping at 10 dB/decade.

The middle line is the laser tube current with the power supply driven by the controller’s PWM output, also dropping at 10 dB/decade.

The bottom line is the laser tube current with the power supply driven by the L-AN analog voltage. It drops at 20 dB/decade.

The usual measurements of voltages and currents assume a constant load impedance, where the power varies with the square of the measured value. In this case, the laser tube is most definitely not a constant resistance, because it operates at an essentially constant voltage around 12 kV after lighting up at maybe twice that voltage. As a result, the power varies linearly with the measured voltages and currents, so the usual Bode plot “20 dB per decade” single-pole filter slope does not apply.

Because the laser tube power varies roughly with the current, I’ve been using the current as a proxy for the power, so the half-power points are where the current is half its value at low frequencies.

The controller’s analog voltage output is linearly related to the tube current and power, so the same reasoning applies.

That reasoning is obviously debatable …

Anyhow, it seems the PWM digital output is the primary signal source, with the L-AN analog output filtered from it. If you had a use for the analog voltage that didn’t involve sending it through a second low-pass filter, it might come in handy, but that’s not the case with the laser’s HV power supply.

Looking across the graph at the tube current’s half-power level of 12-ish mA shows 150 Hz for the L-AN output and 250 Hz for the PWM output. That’s roughly what I had guesstimated from the raw measurements, but it’s nice to see those lines in those spots.

In practical terms, grayscale engraving will operate inside an upper frequency limit around 200 Hz. Engraving a square wave pattern similar to the risetime target requires a bandwidth perhaps three times the base frequency for reasonably crisp edges, which means no faster than 100 Hz = 100 mm/s for a 1 mm bar.

It may be easier to think in terms of the equivalent risetime, with 200 Hz implying a 1.5 ms risetime. The rise and fall times of the laser tube current are not equal and only vaguely related to the usual rules of thumb, but 1.5 ms will get you in the ballpark.

The usual tradeoff between scanning speed and laser power for a given material now also includes a maximum speed limit set by the feature size and edge sharpness. Scanning at 500 mm/s with a 1.5 ms risetime means the minimum sharp-edged feature should be maybe three times that wide: 5 ms / 500 mm/s = 2.5 mm.

The sine bars at 400 mm/s come out very shallow, both rectangular bars have sloped edges, and the 1 mm bar on the left resembles a V:

Sine bars - acrylic - 400 mm-s 100pct
Sine bars – acrylic – 400 mm-s 100pct

At 100 mm/s, all the features are nicely shaped, although the sidewalls still have some slope:

Sine bars - acrylic - 100 mm-s 25pct
Sine bars – acrylic – 100 mm-s 25pct

In all fairness, grayscale engraving with a CO₂ laser may not be particularly useful, unless you’re making very shallow and rather grainy 3D relief maps.

Intensity-modulating a “photographic” engraving on, say, white tile depends on the dye / metal / whatever having a linear-ish intensity variation with exposure, which is an unreasonable assumption.

The L-ON digital enable also has a millisecond or two of ramp time, so each discrete dot within a halftoned / dithered image has a minimum width.

Tradeoffs! Tradeoffs everywhere!

CO₂ Laser Tube Current: PWM Bandwidth

As with the analog bandwidth measurements, start with the same sine-bar bandwidth target:

Sine bars - 10 cycles
Sine bars – 10 cycles

Return the laser power supply’s IN terminal (and the purple wire to the oscilloscope) to the Ruida KT332N controller’s PWM output:

Ruida KT332 - PWM laser control wiring
Ruida KT332 – PWM laser control wiring

Engraving the pattern in grayscale mode at 254 dpi produces 0.1 mm pixels and makes each bar 1 mm wide:

LightBurn - bandwidth test pattern setup
LightBurn – bandwidth test pattern setup

Engraving at 50 mm/s = 50 Hz lets the laser current once again hit full scale:

Tube Current - PWM bandwidth - 10 sine - 50mm-s - 10ma-div - 254dpi
Tube Current – PWM bandwidth – 10 sine – 50mm-s – 10ma-div – 254dpi

The traces:

  • 1 X axis DIR, low = left-to-right (yellow)
  • L-ON laser enable, low active (magenta)
  • PWM digital signal (cyan)
  • 4 tube current – 10 mA/div (green)

The PWM signal runs at 20 kHz and presents itself as a rather blurred trace, but you can see both the general tendency and the discrete steps between the vertical gray bars. As far as I can tell, the signal never reaches 0% or 100%, most likely to prevent the PWM filters from saturating in either condition.

The tube current drops from 23.8 mA to 13.8 mA, just over the half-power level of 12 mA, at 200 Hz:

Tube Current - PWM bandwidth - 10 sine - 200mm-s - 10ma-div - 254dpi
Tube Current – PWM bandwidth – 10 sine – 200mm-s – 10ma-div – 254dpi

So the PWM bandwidth is a little over 200 Hz, slightly higher than the analog bandwidth of a little under 200 Hz.

All of the measurements as a slide show:

  • Tube Current - PWM bandwidth - 10 sine - 25mm-s - 10ma-div - 254dpi
  • Tube Current - PWM bandwidth - 10 sine - 50mm-s - 10ma-div - 254dpi
  • Tube Current - PWM bandwidth - 10 sine - 100mm-s - 10ma-div - 254dpi
  • Tube Current - PWM bandwidth - 10 sine - 200mm-s - 10ma-div - 254dpi
  • Tube Current - PWM bandwidth - 10 sine - 300mm-s - 10ma-div - 254dpi
  • Tube Current - PWM bandwidth - 10 sine - 400mm-s - 10ma-div - 254dpi
  • Tube Current - PWM bandwidth - 10 sine - 500mm-s - 10ma-div - 254dpi

Now, with all the measurements in hand, maybe I can reach some sort of conclusion.

CO₂ Laser Tube Current: Analog Bandwidth

As before, with the Ruida KT332N controller’s L-AN analog output connected to the HV power supply IN terminal:

Ruida KT332 - analog laser control wiring
Ruida KT332 – analog laser control wiring

This time the scope traces include both the controller’s output voltage and the laser tube current:

The traces:

  • 1 X axis DIR, low = left-to-right (yellow)
  • L-ON laser enable, low active (magenta)
  • L-AN analog voltage (cyan)
  • 4 tube current – 10 mA/div (green)

At 50 mm/s = 50 Hz both the L-AN analog voltage and the laser current hit full scale:

Tube Current - analog bandwidth - 10 sine - 50mm-s - 10mA-div - 254dpi
Tube Current – analog bandwidth – 10 sine – 50mm-s – 10mA-div – 254dpi

The laser current resembles a damped RLC oscillation when started at nearly full scale and is entirely chaotic when started from zero, but behaves reasonably well for the rest of the cycle.

The power supply’s current bandwidth is definitely smaller than the controller’s voltage bandwidth, as shown by all those sampling steps simply vanishing.

As expected, at 200 mm/s = 200 Hz the L-AN analog voltage is down 3 dB:

Tube Current - analog bandwidth - 10 sine - 200mm-s - 10mA-div - 254dpi
Tube Current – analog bandwidth – 10 sine – 200mm-s – 10mA-div – 254dpi

At that frequency the tube current is down 8 dB, from 23.4 mApp to 9.4 mApp, showing how much the power supply’s PWM filter contributes to the rolloff. Since we’re interested in the overall bandwidth, the tube current is down 2.4 dB to 17.8 mA at 100 Hz, suggesting the -3 dB (16.6 mA) frequency is just slightly higher:

Tube Current - analog bandwidth - 10 sine - 100mm-s - 10mA-div - 254dpi
Tube Current – analog bandwidth – 10 sine – 100mm-s – 10mA-div – 254dpi

However, I think that’s the wrong way to calculate the -3 dB point of the laser power, because the tube operates at essentially constant voltage, which means both the analog voltage and the tube current are linearly related to the laser tube power, rather than being proportional to its square root.

If that’s the case, then the analog output voltage is down by ½ at 300 Hz and the tube’s half-power point occurs at 23.4 mA/2 = 11+ mA, closer to 200 Hz than 100 Hz. Given the resolution of the measurements, this doesn’t make much difference, but it’s worth keeping in mind.

Applying a 100 Hz PWM pulse (thus, a sharp step) to the power supply shows the laser tube current has a risetime (and falltime) around 2 ms, about what you’d expect from a single 200 Hz lowpass filter inside the power supply:

Tube Current - 50pct 0.1kHz PWM - glitches - 10 ma-div
Tube Current – 50pct 0.1kHz PWM – glitches – 10 ma-div

As far as I can tell, the controller’s “analog” output is just its digital PWM output passed through a 200 Hz low-pass filter. It would be useful as an analog input to a power supply without an additional PWM filter, but combining those two filters definitely cuts the overall bandwidth down.

All of the measurements as a slide show:

  • Tube Current - analog bandwidth - 10 sine - 25mm-s - 10mA-div - 254dpi
  • Tube Current - analog bandwidth - 10 sine - 50mm-s - 10mA-div - 254dpi
  • Tube Current - analog bandwidth - 10 sine - 100mm-s - 10mA-div - 254dpi
  • Tube Current - analog bandwidth - 10 sine - 200mm-s - 10mA-div - 254dpi
  • Tube Current - analog bandwidth - 10 sine - 300mm-s - 10mA-div - 254dpi
  • Tube Current - analog bandwidth - 10 sine - 400mm-s - 10mA-div - 254dpi
  • Tube Current - analog bandwidth - 10 sine - 500mm-s - 10mA-div - 254dpi

To round this out, I must measure the laser tube current bandwidth using the controller’s PWM signal. Because PWM passes through only the power supply’s lowpass filter, the bandwidth should be slightly higher.

Overall, though, the bandwidth seems surprisingly low.

CO₂ Laser Tube Current: Controller Bandwidth Measurement

Use the sine-bar bandwidth pattern:

Sine bars - 10 cycles
Sine bars – 10 cycles

Engrave it in grayscale mode as a negative image with 0.1 mm line spacing:

LightBurn - bandwidth test pattern setup
LightBurn – bandwidth test pattern setup

Monitor the Ruida KT332N controller’s analog laser power control output:

Tube Current - analog bandwidth - 10 sine - 25mm-s - beam off - 254dpi
Tube Current – analog bandwidth – 10 sine – 25mm-s – beam off – 254dpi

The traces:

  • 1 X axis DIR, low = left-to-right (yellow)
  • 2 L-ON laser enable, low active (magenta)
  • L-AN analog voltage (cyan)

The scope triggers when the top two traces go low during a left-to-right scan with the laser beam active. The trigger point lies far off-screen to the left, with the delay set to pull the interesting part of the scan into view.

Although both the controller’s L-AN output and the laser’s IN input specify a signal range of 0 V to 5 V, the analog output voltage never goes below 0.4 V, but (as will seen later) that produces 0 mA from the laser power supply.

Set the X cursors to the top and bottom of the sine wave and read off the 4.36 V peak-to-peak value.

Set the Y cursors to matching points on successive cycles and read off ΔT=33.44 ms. Because each cycle is 1 mm wide, the scan speed is set to 25 mm/s and traveling 1 mm should require 40 ms, puzzle over that number and the related fact that 1/ΔT=29.91 Hz. This seems to happen only for speeds under 50-ish mm/s, for which I have no explanation.

Repeat the exercise at various speeds up through 500 mm/s:

Tube Current - analog bandwidth - 10 sine - 500mm-s - beam off - 254dpi
Tube Current – analog bandwidth – 10 sine – 500mm-s – beam off – 254dpi

The analog output voltage has dropped to 1.56 Vpp.

The average voltage increases from 2.66 V at 25 (or is it 33?) Hz to 2.78 at 500 Hz, which is reasonably close to the same value.

The signal’s -3dB point would be at √½ × 4.36 Vpp = 3.1 Vpp, which happens at 200 mm/s = 200 Hz:

Tube Current - analog bandwidth - 10 sine - 200mm-s - beam off - 254dpi
Tube Current – analog bandwidth – 10 sine – 200mm-s – beam off – 254dpi

Which is eerily close to the “around 200 Hz” bandwidth figured from the risetime measurements.

All of the analog output measurements as a slide show:

  • Tube Current - analog bandwidth - 10 sine - 25mm-s - beam off - 254dpi
  • Tube Current - analog bandwidth - 10 sine - 50mm-s - beam off - 254dpi
  • Tube Current - analog bandwidth - 10 sine - 100mm-s - beam off - 254dpi
  • Tube Current - analog bandwidth - 10 sine - 200mm-s - beam off - 254dpi
  • Tube Current - analog bandwidth - 10 sine - 300mm-s - beam off - 254dpi
  • Tube Current - analog bandwidth - 10 sine - 400mm-s - beam off - 254dpi
  • Tube Current - analog bandwidth - 10 sine - 500mm-s - beam off - 254dpi

One might now wonder whether there’s any bandwidth difference between the analog and PWM signals as measured in the laser tube current.

Data! We need more data!