Today we got our dishwasher fixed under warranty. To diagnose it, the tech stuck a photosensor+magnet onto the front panel over the green status LED and started reading diagnostics. It turns out the status LED is actually a serial port*, and it's continually transmitting status.

I can think of so many gadgets that could and should use this trick...

*It's probably something other than regular serial -- a UART's TX would flicker. I don't know any details.

#HidingInPlainSight

Effectively, this is an opto-isolator. Except it's not all in one device. Wikipedia has a good article on them, and notes that they can manage 10s of KHz. (See MIDI.)

The nice thing is that there's zero extra hardware -- every gadget already has an LED or seven, and if your MCU has a spare DMA channel, you can stream a bitstream to it (however it's encoded) with low overhead. If it's a short status message, you can just let the DMA loop over it and there's no MCU overhead.

@kbob wonder if you could just stick a led on a pin and use a one wire protocol library… basically just one wire with an opto coupler in the middle (and one way) 🤔 although that is maybe not constant enough “on” to be used as an indicator led.

@kbob sounds close to the smart gas meters that are apparently the sole reason you can buy a USB IrDA interface in 2025:

https://en.m.wikipedia.org/wiki/IrDA#Power_meters

Lacking specialized electronics, many power meter implementations utilize a bit-banged SIR phy, running at 9600 BAUD using a minimum-width pulse (i.e. 3/16 of a 115.2KBAUD pulse) to save energy. To drive the LED, a computer-controlled pin is turned on and off at the right time. Cross-talk from the LED to the receiving PIN diode is extreme, so the protocol is half-duplex.

i've got two of them on my desk. they attach to the meters with magnets and run on a Silicon Labs CP210x chip.

i may not be able to get them talking to my PalmOS devices, because the full IrDA stack is a Whole Thing, but maybe…

IrDA - Wikipedia

@kbob DMA channel?

If it's broken you can bitbang a serial stream without issue. Add a IR receiver and you can have bidirectional serial with not much issue. Most LEDs are easily able to do serial at 9k6 and probably at 115k2, which is trivially fast enough (even 9k6) with a decent protocol to transfer diagnostics data (other than full log files).

Note that a LED flickering with at least 1 start bit per 10 bits, at 9k6, would be flickering on and off at least 1000 times per second, so you wouldn't necessarily even notice that it flickers.

@dascandy The reason I suggested a DMA channel is that bit banging keeps the MCU busy. The MCU presumably has other things to do, otherwise why is it there?

Very low end MCUs don't have DMA, but it's a common feature these days.

And yes, if you add hardware you can add capabilities. I was talking about a zero hardware feature, which is what this appears to be.

@kbob It's there to run the dishwasher. But if it's in non-operational state, why would it be busy doing something else? When you get a command on serial, run it, then go back to bitbanging out the result. Gets you a cheaper mcu as an option.
@dascandy That's a good point. I had assumed it was always transmitting, but maybe it only transmits when it's broken. And manufacturers do have more opportunitis to cost-optimize than those of us who rely on hobby boards.
@kbob @dascandy Maybe it only transmits when it detects the magnet? Hall effect sensors are cheap nowadays.
@nicolas17 @kbob or a reed relay attached to the rx pin, or power line for the optotransistor
@dascandy @kbob Reed relay makes more sense, yes!

@kbob Cool! Similar to IEC 62056, I guess...

Out of interest, what make is the dishwasher?

@kbob Sorry, what!

@LovesTha What?

The dishwasher has a green LED on the steel front panel. The tech put a magnetic device onto it that covered the LED and had a cable running to his computer. He said it was a photo sensor and was reading diagnostic data from the LED. He didn't do anything to start data transmission. I extrapolated that the dishwasher must always be transmitting diagnostic info by modulating the LED output. At least that's what I think was happening.

@kbob oh, I communicated badly.

How and technical things were immediately obvious.

That it was 2025 and I'm 42 before I learned that such a thing was real is my in credulousness.

This has amazed me with child like wonder

@LovesTha Same here. When I saw it, I had a moment of disbelief, then a moment of "where has this been all my life?"
@kbob I do have questions, like can a phone camera go fast enough to plausibly decode it....

@LovesTha @kbob if you diffuse the image and use rolling shutter artifacts, it should be possible to cature a few bytes per image - probably enough to extract some data

Edit:

https://hal.science/hal-03235346/document

@stereo4x4 @LovesTha @kbob I vaguely recall an older device at work - this was years ago - that used that principle but in reverse. I think it was a stamp machine. You'd pay for stamps on an app, then show the phone's screen (which flickered rapidly) to a glass window on the stamp machine, which would load it with the monetary value of the stamps.
It usually took a few tries, but it worked.
@kbob @LovesTha So that at night, with a telescope and an extremely good night-vision device you could read the state of your neighbour's dishwasher? 🙂
@mrdk @kbob @LovesTha “is your refrigerator running? It won’t be soon, your compressor is nearing end of life”
@kbob it's probably data encoded into variations in the pwm timing, but yeah

@kbob that’s a clever trick, and way less disruptive than most self diagnostics systems.

At a guess it’s encoding data in the difference between, eg, 80% on / 20% off duty cycle and 90% on / 10% off duty cycle. Providing the PWM is fast enough and the “high” and “low” duty cycles are reasonably balanced I’d expect it just looks like a LED around 85% on by (fast) PWM. And just needs good oversampling on the reader to decode.

@ewenmcneill @kbob if you just do that, it’s still going to flicker in a perceivable way. You have to whiten the modulation signal first to avoid slow frequency components in the signal, easy ways to do that are Manchester or 8b/10b encoding.

@jaseg if the bits were sent slowly then I’d agree there could be visible flicker. But if they’re sent rapidly enough with a good (fast) PWM controller so it wasn’t just one on/off per cycle, then the flickering would only be visible to a (fast) camera. (Eg send the duty cycle 10 times per bit, rather than once per bit.)

Whitening (for ~equal 1s and 0s) is a good idea anyway, and could probably be combined with some forward error correction.

CC @kbob

@ewenmcneill @kbob The flicker I’d worry about would be the slight average duty cycle differences betweeen e.g. a long run of “o” (0x6f, six one-bits) and a long run of “A” (0x41, two one-bits). I built a large LED art installation a while ago where I transmitted power and data through the LED’s modulation signal and I was surprised how little residual low-frequency content was enough to make tired eyes perceive a slight flicker.
@jaseg @ewenmcneill Yeah, I did not know about 8b/10b encoding before I started this thread, but it looks like the bee's knees. I'm very much looking forward to trying it out - it looks like one of those algorithms that starts with a lot of theory and collapses down into not very much code.

@jaseg @ewenmcneill @kbob

Which makes me wonder if it only transmits when the magnetic device is attached.

The LED would be a steady green (or whatever) under normal use, but when a magnet is sensed, data is transmitted. Since the LED is covered, you wouldn't see any flickering.

@kbob Our washing machine has a diagnostic feature like that, which works with phone support: at the operator's instruction, you hold your phone against the control panel and push some button sequence, and the speaker that it normally uses to tell you the cycle's finished screams PSK-modulated debug information at the telephone, presumably for a program on the far end to decode.

@danderson @kbob our smoke detectors can output their serial number, number of alarms, battery state etc. by modulating their piezzo. A smartphone can be used to do the "mandatory" self test once a year and see the history per smoke detector. Its a neat system. They somehow measure if its day or night and sound the low battery alarm only at day - well worth the premium price. I already lost a few nights of sleep hunting the stupid beeping thing that woke me up at 2 AM.

Edit: brand is Hekatron ; so far they had no false alarms (vs. the cheap ones) but detected accidental kitchen oopsies reliably.

@stereo4x4
That is genius. I will definitely be looking for that feature next time I buy a smoke detector.
@danderson @kbob
@stereo4x4
See! We CAN have 'connected devices' that don't suck.
@danderson @kbob
@danderson @kbob not unlike how Luke Skywalker speaks droid
@kbob my LG fridge has a little speaker (a piezo?) that can supposedly click out diagnostics data over the phone!
@kbob Our microwave has a mode where it will chirp like a modem and you can call the company so they can tell what is broken..
@kbob If you fluctuated the brightness, rather than fully turning it off, the flicker effect would be much less noticeable.
@StarkRG @kbob
If it's FSK, there wouldn't be any noticeable flickering at all
@kbob lots do. It's also been shown for stuff like leaking data between computers over air gaps long time back.
There's even schemes doing this with stuff like street lamps and traffic lights to talk to cars etc
@kbob I tried to patent this hack at Google :-). Data center robot rolls up in front of a rack, focuses its camera on the machine of interest, and opens up a serial port link (console) to the operator. Optical if fast enough you could actually do KVM if the hardware behind the servers led and photo transistor could handle it. Seemed like a secure lights out kind of way to protect servers.
@kbob That’s damn clever. I bet it’s something like IrDA encoding, but inverted. Very short off times encoding a mark in the underlying UART stream.
@kbob I did once have a dev board which flashed S.O.S on an LED when it hit the equivalent of a kernel panic
@Workshopshed @kbob I did something similar with sound, back in the days. Rising triad for "system is ready", falling triad for shutdown, meep-meep for "it's safe to unplug the USB media", and the morse code for TOO HOT if it was about to shutdown due to a temperature sensor (either on the board or inside the CPU) hitting its safety threshold.
@kbob our oven has a diagnostic port (although it's IR). it's a miele; who's the manufacturer of your dishwasher?
@phooky Also Miele.

@kbob @phooky the best PDF i found about this from miele was: https://www.tie.ro/wp-content/uploads/2013/05/Smart_electronics_in_home_appliances_-_MIELE_-_TIE2013.pdf#page=24

The topology seems that behind the "optical interface" we could also do TX

(Also cool to see they use Super-H for Touch, Page 13)

@tal @kbob "Miele-bus". I am absolutely losing it. Thank you for this.

@tal @kbob Also, 'Miele@home: “Con@ctivity”'. Wow wow wow

(I should take a moment to point out that the firmware on my oven is absolutely horrible, and that the touch sensing only really works when your hands are clean, dry, and grease-free, which is definitely not me when I am cooking)

@phooky still better than a Electrolux/IKEA oven which has knobs -but they tend to not work or cancel a timer when there is a bit of steam buildup and the resistance goes haywire :-)

(instead of using dedicated pins/traces)

@tal @kbob ok, someone's already reversing the IR
https://medusalix.github.io/posts/miele-interface/
Reverse Engineering the Miele Diagnostic Interface

Severin's Blog

Severin's Blog

@kbob
Very clever and very hostile to user repairs and probably third party repairs - at least a visible error code can be looked up

I absolutely hate that implementation

@OliverNoble @kbob I wonder if it could be standardized, and read by any camera phone - that would be cool.

@kbob while we don't ship it in the production firmware, the Oxide server's service processor firmware has a build option that transmits kernel profiling data encoded NRZI over the status LED. It's a handy trick.

A lot of MCUs even have hardware left over from IrDA that you can use to frequency modulate a UART output!

I've been trying to figure out how to read this sort of a channel from a phone, without additional hardware... that part's hard so far, at reasonable bitrates. LG appliances can emit encoded audio chirps that a phone can pick up, maybe that's the way. (I was unable to convince my colleagues to include an audio output device on the server.)

@cliffle Is that the Hubris kernel?

I'd think it would be hard for a phone to isolate an audio chirp in a datacenter. So much fan noise...

@kbob the more of our racks you use, the less of a problem that fan noise will become. 😉

(But seriously we're dramatically quieter)

(...omg I should try to modulate the data _onto the fans_)

@cliffle @kbob

(...omg I should try to modulate the data _onto the fans_)

I came very close to implementing that at my last job: https://honk.bewilderbeest.net/u/zev/h/HW2GcrgzthGts7DXR8

@cliffle @kbob hmm, I wonder if phone video typically uses a open shutter or not, but if so with a magnifier it can probably sample the led at super high speed.

@shironeko @kbob it depends on the phone, but, most don't have a physical shutter and use CCD-level "shutters," usually rolling rather than global.

A lot of the CCD controllers can do absurdly high frame rates if you window the sensor narrowly to e.g. the center four pixels. But I don't think mobile OSes tend to expose that.

@cliffle @kbob yeah a trick with rolling shutter is to use each row as a sample, but it would be a problem if the shutter angle is 180 for example cus the sampling is stopped half the time every frame.

@shironeko @kbob So, delightfully, I did an optical illusion with this many years ago, which would draw ghostly matrix images in photos taken with rolling shutter digital cameras.

I actually hadn't considered using this for data reception though. That's great. You'd need time sync patterns of some sort.