0

I am wiring up my new 3D printer motherboard. I am using a lj12a3-4-z\bx inductive proximity sensor for my bed sensing probe. In order for the probe to function at its best, I am running it on 24V from a spare fan header. Since it is NPN, it "sends" GND to the probe trigger pin so normally I would have nothing to be worried about. If the probe fails, could it send 24V into the microcontroller and zap the motherboard? My electronics knowledge is still growing.

Since I would really hate for a $2 probe to break my $75 motherboard, is there a simple way to protect the microcontroller from a high voltage spike? My first thought was a simple voltage divider. I have used one on a PNP probe to step 24V down to 5V. Is this the same case just as protection rather than supply voltage?

With the above case in mind since I am protecting a logic pin would I want to step down to 5V or 3.3V?

Any insight?

JRE
  • 67,678
  • 8
  • 104
  • 179
  • 1
    An open collector transistor failing won't send a high voltage to an input because the transistor isn't blocking high voltages in that setup. What it will do is permanently pull the output to ground. However, if you're worried about failing semiconductors introducing high voltages, that's true virtually everywhere including all the regulators all over your motherboard and electronics. – DKNguyen Apr 09 '23 at 09:03
  • @DKNguyen Yeah I do realize that the motherboard has numerous other regulators that could also fail. But I see that my understanding of what the failure mode of the sensor would be is backwards. So to confirm, you are saying if an NPN sensor fails then the trigger pin will just get pulled to ground and will not release as it would if the sensor was functioning properly? – AtomicPorkchop Apr 09 '23 at 09:08
  • Yes.................... – DKNguyen Apr 09 '23 at 19:19

2 Answers2

3

It’s far more likely your ground wire for the sensor will come disconnected and send 24V into the mombo (albeit at limited current). Or a short between 24V and the sensor output wire (at rather less limited current).

One possible approach is to use a TVS diode on the input, suitably rated for the voltages involved, but the details depend on a lot of variables and protection is not absolute, especially without some kind of series resistance that will limit the current into the TVS. What is possible there depends on knowledge of the pull-up resistor used in the mombo as well as the voltage and the logic thresholds.

Spehro Pefhany
  • 376,485
  • 21
  • 320
  • 842
1

I am not sure what motherboard are you using, but as it is an NPN and open-collector, I would suggest this:

enter image description here

The sensor is powered with 24V using the BROWN and BLUE cables. And the output signal (BLACK cable) is connected to a pull-up (R2) and a Resistor (R1) with a Clamping-Diode (D1). The R1 will limit the current through the D1 if there is shortcut to 24V in the BLACK cable. Use a schottky-diode, as 1N5819.

Be aware, that many motherboards have a similar set up for the inputs, so the resistors and diode are already there.

MF3
  • 194
  • 1
  • 5
  • 1
    I am using a BigTreeTech SKR 3. If there is a possibility the board already has it included I will review the schematic and check. The pin I was going to use for the probe trigger was the `probe` designated pin. – AtomicPorkchop Apr 09 '23 at 18:10
  • In that case, I would connect the diode and pull-up to 3.3V instead. If you check the schematic, the thermistors inputs have a similar – MF3 Apr 09 '23 at 18:36
  • I am still quite a novice to EE subject manner. Why does does the circuit require a +5 or +3.3 on the black wire? – AtomicPorkchop Apr 09 '23 at 18:42
  • 1
    If you check the terminator input, they have a similar approach. The R2 is a pull up for the open-collector output. So if the output is open, you are setting the input value to +3.3V. If the output is active, you will have almost 0V. The R1 and Diode work together to limit the voltage in the microcontroller pin to almost +3.3V, in case the voltage in the BLACK cable is higher. You can read more about it here: https://electronics.stackexchange.com/questions/418499/how-does-diode-clamp-protection-work – MF3 Apr 09 '23 at 18:48