# Wiring 3 proximity sensors in series

I have a stepper motor controller which controls 4 fairly powerful steppers and has input pins for 3 proximity sensors. The controller requires 48v so I have the power supply for that. The 3 NPN proximity sensors I have operate at 10-30v and draw 150mA. I initially connected the out pins of the sensors to the controller and powered the sensors from a 12v psu I had lying around. I then connected ground from both power supplies. I was told this was incorrect because if one power supply failed it might wreck other parts of the circuit.

My problem then was how to get it all working correctly. I thought about a relay for each sensor but my preference was for powering all sensors from the 48v supply. I thought about stepping voltage down from 48v to 30v but it requires knowledge I don't have. I could use resistors to do it but I get the feeling that isn't a good idea. It would only draw a maximum of 450mA-500mA but steeping down from 48v to 30v would generate a lot of heat correct?

My other idea was to wire them in series but that's not working as planned. The voltage across sensor 1 is 22v, across sensor 2 is 15v and sensor 3 is 11v. Sensor 1 is operating correctly, when metal passes it the sensor triggers. Sensors 2 and 3 are always on which is confusing because they're clearly getting power but for some reason think they've been tripped when they haven't. When I read the voltage between the + of each sensor and its out pin I get whacky results. Sensor 1 is reading 0v which is correct. Sensor 2 and 3 read 8.33v and 25v respectively.

Since sensors 2 and 3 are trigger, I would've thought those readings would've been the voltage applied across them (15v and 11v) with slightly lower values due to resistance. But, seeing as they're triggered without anything near the sensor then it's strange they have a voltage across them at all.

Is there a way to get the 3 sensors working in series or should I tackle it another way? I'm wondering if there's something I can do to split the voltage into 3, thus delivering 16v into each sensor without any fancy electronics.

• provide a link to the sensors please. Commented Jan 3, 2014 at 10:58
• Also, a schematic or block diagram would be clearer than a word picture. Commented Jan 3, 2014 at 11:01
• Sorry about that, added it now. Commented Jan 3, 2014 at 11:17
• I'm confused about what was wrong with the 12V second power supply arrangement, provided the common ground was OK. If you have to power it via the 48V you can get various sorts of buck regulator to do that. Commented Jan 3, 2014 at 11:30
• I'm not sure, that's just what I was told. I'm not an electronics guy. Commented Jan 3, 2014 at 11:53

You might be able to make this work but there are some sticky issues. First, if the ground connections of the sensors are not connected to the same ground as the controller then the sensors will not be able to pull their outputs down to the controller ground. As a result the controller will never see a logic low level from the sensor. One way to correct for this is to add an optoisolator at the output of every sensor. The output of the sensor would then activate an LED in the optoisolator and the phototransistor in the optoisolator could activate the controller input. This is pretty easy and inexpensive.

The harder problem is providing a stable supply voltage to the three sensors. When circuit elements are connected in series we know that the current through them must be the same but the voltage across them can be different. You need a way to make sure that the voltage across each sensor remains relatively constant even though the current they draw varies over time. I'm thinking that it may be enough to put a 16V, 1W, zener diode and a sizable capacitor in parallel with each sensor's power connections.

If you're not comfortable doing this then I would suggest just creating a 12V or 15V power supply using a linear regulator (say a 7812) from the 48V supply. You only need about 30mA to operate the three sensors, and I can't think of any problem that would occur by doing this.

• Joe, I looked at the specs for the 7812 and it looks like you can only feed it up to 19v. Commented Jan 3, 2014 at 22:32
• I checked the Fairchild part and the maximum input voltage was 35V but that still doesn't meet your needs. It looks like you will have to get a small DC-DC converter for a 48V input. Commented Jan 3, 2014 at 22:52

Yea you can't do this. The proximity sensor you have is using an NPN transistor topology. The transistor inside looks like this:

This is NOT a linear device. You cannot wire these up as you would LEDs in series. As this device reaches its saturation, you get a defined gain which intrinsic to the specific device. Basically this thing is a little amplifier. So if you hook them up in "series" you are going to be amplifying the previous output in the current proximity sensor and so on for however many you have.

You have to hook them up separately.

• But the NPN outputs are not connected in series, are they? The collector of each NPN output transistor goes to the controller input, not to another sensor's NPN output. The real problem is that the emitter of each NPN needs to be connected to the contrller's ground. Commented Jan 3, 2014 at 15:12
• no they aren't (hence why I put series in "") although his diagram clearly shows he's trying to hook them up like LEDs as if its a linear component. Commented Jan 3, 2014 at 16:18
• Sorry, I didn't have any idea what you meant by putting series inside quotes and I feared that the next reader would also be confused. I think your reference to LEDs as linear components is also confusing, they are not at all linear. Finally, to be clear, it is the power supply connections that are in series, not the NPN output connection. Commented Jan 3, 2014 at 17:46
• Okay the common 5mm LED then. Admittedly the datasheet is confusing, to say the least. It shows its output connection using 3 terminals but does not describe the PL-05 connection method, and it shows, near the bottom, plus and minus connections. Is there a reason that he wouldn't be using a simpler proximity sensor, consider he's not an electronics guy? Commented Jan 3, 2014 at 18:05
• They're for a cnc machine and each sensor goes on a moving axis. These sensors fit perfectly because of their size. They were really cheap and at the time I had enough knowledge to wire them with the 12v supply. I'm still not sure why 2 power supplies are bad to be honest Commented Jan 3, 2014 at 22:30