Inductive sensor failure diagnosis

I went to print tonight on my printer with an inductive Z sensor, and the sensor always reads as triggered.

I tried moving it to a different port on the board, and changed the configuration to follow that port. It’s a different port on the processor, not just a different bit (moved from PE0 to PH6), so if it were a damaged GPIO on the processor, I would expect that to resolve the problem; ports PC13 and PF2 are working for X and Y.

The LED built into the sensor triggers. What failure modes can you think of here?

And, on the theory that I might be buying new ones and can configure them any way I want, is there any specific reason to prefer NO or NC inductive probes?

Can you post the specs on the sensor?

No, because “Inductive ABL sensor” is what’s in the kit component list, and it came as a bare part… And I don’t think there’s any writing I can see on the sensor to better identify it. Neither whether it is PNP or NPN, nor whether it is NO or NC. I’m used to inductive sensors having identifying markings at the back, but not this one.

I know I want an 8mm diameter by about 40mm long sensor to fit the existing hole.

The sense LED works (moving steel near the sense LED causes the built-in LED to turn on and off), so it must be getting power and ground and still have a working sensor inside, so all I can think of is that I have a broken wire somewhere, or the LED is switched separately from the sense transistor. I’ll have to bring a multimeter to it to test it next.

The port has a pull-up and is not inverted, so I’d think it’s NPN NC; pulling down the pin when it does not sense, and opening and letting the pull-up resistor pull it up to sense high when it is triggered. Does that make sense?

Is it like a BL/CR touch sensor? Let have pics of the corpse…

With power at the sensor and onboard LED indicating functionality then my bet is on the wiring from the sensor to the trigger pin. Should the sensors output driver have failed and if your lucky, maybe there’s even a 2nd pin on the sensor for opposite output driving action.

3.3V supply. Sense reads 2V whether or not it is triggered, and the built-in red LED turns off when it is triggered. I thought “obviously, it’s a broken probe” but then realized that I hadn’t isolated the probe; I was testing the voltage supplied through the built-in pull-up resistor, which is going to be some sort of drop from the 3.3V supply for the chip. I needed to build a simple test rig from a power supply and a pull-up resistor and isolate the probe. Duh.

I grabbed a breadboard, portable power supply, 1K resistor, and hooked up +3.3V to +3.3V, GND to GND, and the 1K resistor between +3.3V and signal to pull up signal. I confirmed that if I manually connected signal to GND, the voltage drops from about 3.3V to about 0V, as I would expect, so no open circuits. However, triggering the sensor gives me about a 0.01V change in voltage, so the sensor isn’t pulling down the sense line. It’s either a broken wire somewhere or the sensor has failed internally.

Either way, a new sensor is supposed to arrive tomorrow. I’ll test it the same way to make sure that I’m not confused about my test rig setup.


The NO sensor I bought works but senses opposite of the original. It also doesn’t have an LED to show its state.

I now discovered that I don’t have JST-XH (2.5mm) crimp ends. I have JST-PH 2mm, JST-SM in-line, 2.54mm dupont, and more. But not the ones I need now. So I have an addition to my collection coming. Right now I have it connected to pins in three different blocks on the control board because I just pushed bare connectors onto the pins and don’t want, say, V and G to touch… I didn’t test the printer working, juts used klipper’s QUERY_ENDSTOPS command.

I also decided that the NC original failed in the safe direction, so I think I’m going to write off this NO sensor (or… use it somewhere failure matters less?) and I’ve ordered an NC sensor along with the JST-XH connectors.