Current detection between 2 boards with separate grounds - Page 1
Forum section: electronics / projects

author: fedimakni
author_rank: Regular Contributor
timestamp: March 12, 2025, 02:44:47 am
content: Hello,I have an emergency button wires flowing through board 1 to board as shown in the illustration image attached. Both boards have different grounds, but i would like to measure the current flowing through the wires between boards to check if any cut happened in one of the wires.I was wondering if using a current sense amplifier is going to work as the ground is separate and the reference of the IC will be different from the shunt resistor reference.Could you suggest how i can make it or if there is another idea to detect a cut in the wires between both boards.Note that i don't have access to the ground of board 2 so i can't tie it to board 1 and make the work easier due to various reasons.- The expected current to measure is between 1-10mA- The accuracy is not very criticalThank you very much.

author: ledtester
author_rank: Super Contributor
timestamp: March 12, 2025, 04:27:00 am
content: I am no expert, but I'd like to get opinions on the following idea:Use an isolated DC/DC converter to create a floating measurement system around the sense resistor and then transmit the result of that measurement through an opto-coupler.

author: fedimakni
author_rank: Regular Contributor
timestamp: March 12, 2025, 04:35:22 am
content: ledtester:Actually i was thinking about that idea, the only issue is that the analog signal that will be created, can it be transferred accurately through opto? Usually i use opto for digital signals but do you think a reasonable analog one is available?thanks

author: ledtester
author_rank: Super Contributor
timestamp: March 12, 2025, 05:17:37 am
content: What kind of monitoring of the sense resistor do you have to perform?It would simplify things to only have to transmit digital data so that leads to to two ideas:1. Put all the decision making logic in the floating measurement system and output a "event detected" signal.2. Transmit the reading of the sense resistor as digital data (so you would have a microcontroller in the floating system) - and you do this either on demand or periodically.Update: Another idea which is almost the same as 2 but maybe doesn't need a microcontroller -- convert the analog reading into a PWM signal.

author: fedimakni
author_rank: Regular Contributor
timestamp: March 12, 2025, 10:18:42 am
content: ledtester:I think that is a good approach, thank you but do you have an idea how to turn PWM to analog.

author: PGPG
author_rank: Frequent Contributor
timestamp: March 12, 2025, 11:07:39 am
content: Quote from: fedimakni on March 12, 2025, 02:44:47 amIf you have two PCBs/devices grounded to different ground points then.If they are located in separate buildings then during storm you should assume a several kV GND differences with possibility to drive hundred Amps.If they are located in the same building (the common grounding system) you should assume then during lightning strike nearby you can have up to 50V difference between your two grounds with possibility to drive tens Amps.

author: ledtester
author_rank: Super Contributor
timestamp: March 12, 2025, 01:53:57 pm
content: Quote from: fedimakni on March 12, 2025, 10:18:42 amPWM to analog - probably just use a low-pass filter:https://ww1.microchip.com/downloads/en/Appnotes/90003250A.pdfAnother idea to encode the measurement would be to use a voltage to frequency converter - like a LM331:https://www.ti.com/product/LM331And there are frequency to voltage converters, e.g. the LM2907/2917:https://www.ti.com/lit/ds/symlink/lm2907-n.pdf

author: mtwieg
author_rank: Frequent Contributor
timestamp: March 12, 2025, 01:56:35 pm
content: Quote from: fedimakni on March 12, 2025, 02:44:47 amBased on your schematic, current will only flow when the switch is closed. If the switch is open, a current sensor will not be able to tell you if the wires are "cut". Is that acceptable? If not, then your board 1 will need to sense voltage on the wires as well.If your objective is simply for board 1 to detect when the button is closed, then simply feeding the switch current through the LED of an optocoupler might be a far easier method. That is, assuming the switch current is sufficient to drive the optocoupler and the voltage drop of the LED isn't a problem. See attached simple schematic:

author: Terry Bites
author_rank: Super Contributor
timestamp: March 12, 2025, 02:45:04 pm
content: Yeah, get yourself a low cost isolated DC-DC converter egWurth Elektronik 1779205311Use an isolated current sense amplifier eg AMC1200SDUBR with a 4x100 ohm resistors in parallel make the shunt for a ~10mA full scale.That'll come to about $10 in parts

author: fedimakni
author_rank: Regular Contributor
timestamp: March 12, 2025, 03:45:43 pm
content: mtwieg:The button is in an NC mode so if the wire is cut or the button is pressed the current will stop flowing.

author: fedimakni
author_rank: Regular Contributor
timestamp: March 12, 2025, 03:48:48 pm
content: Terry Bites:Thanks i was really thinking about it but i was wondering if in that case the shunt will stay floating compared to the isolated DCDC and the op amp i am not sure if that is ok or not

author: mtwieg
author_rank: Frequent Contributor
timestamp: March 12, 2025, 05:51:42 pm
content: Quote from: fedimakni on March 12, 2025, 03:45:43 pmRight, NC is typical for an Estop button.If you want to detect if current is flowing, a simple optoisolator is by far the simplest and most robust option I can see. No additional power supplies or amplifiers necessary.If you want to detect if a wire is severed (independent of the state of the switch), then current measurement isn't sufficient.

author: ajb
author_rank: Super Contributor
timestamp: March 12, 2025, 05:55:43 pm
content: There's no way to distinguish between the NC button being pressed and either of the wires being cut by measuring the current in the circuit. Is that a problem for you?I can't see why you'd want to specifically measure the current unless there is more going on than you've shown. Is your actual goal just to allow board 1 to detect when the button is pressed? If so, there are other ways you might solve this problem.

author: fedimakni
author_rank: Regular Contributor
timestamp: March 12, 2025, 08:06:45 pm
content: mtwieg: just to make sure, you mean an optoisolator in series with the E-stop correct?Also do you think it will change the voltage at board 2 if it is in series by a much?

author: fedimakni
author_rank: Regular Contributor
timestamp: March 12, 2025, 08:12:23 pm
content: Ajb: yes i don't need to distinguish between a cut or a button press, both should be treated as a button pressed situation for safety.There are of course 4 different wires that can be cut in this caseWire 1 between board 1 and emergency buttonWire 2 between board 1 and emergency buttonWire 3 between board 1 and board 2Wire 4 between board 1 and board 2There are 3 easy solution to be detected but the last one which is the return wire between board 1 and board 2 connected to the pulldown is difficult to detect if it was cut or not. And that's why i come up with the solution to measure the current which can be a potential solution.

author: tooki
author_rank: Super Contributor
timestamp: March 12, 2025, 08:52:03 pm
content: If this is actually a safety-relevant, the e-stop button (and any interlocks) should actually be managed by a certified safety relay. You generally use two redundant circuits, and the safety relay monitors both using out-of-phase digital pulses, so it can detect open circuits as well as crossed wires. As an example, on one project I used a Phoenix Contact PSR-MC72.

author: mtwieg
author_rank: Frequent Contributor
timestamp: March 13, 2025, 11:35:34 am
content: Quote from: fedimakni on March 12, 2025, 08:06:45 pmYes, that's exactly what I showed in my example schematic.QuoteThe optoisolator LED will have a voltage drop of about 1.2V. If the Estop circuit is powered by 24V then that's a negligible drop, I think. In your first circuit you show the Estop signal being attenuated with a resistor divider to a logic signal, so in that case the voltage drop isn't an issue.Also have to make sure the LED current is high enough to be detectable (1mA should be plenty) but also not so high it damages the optocoupler (most are rated for up to 20mA). If your Estop circuit needs to handle larger currents (like to drive a relay coil for example) there are circuits which can protect the LED from being harmed by this.

author: Picuino
author_rank: Super Contributor
timestamp: March 13, 2025, 02:18:31 pm
content: Safe Machinery Handbookhttps://download.schneider-electric.com/files?p_File_Name=Machine-Safety-Guide.pdfDesigning safety automation is more complicated than simply making a detection circuit. You have to take into account a lot of regulations and do a risk analysis to know what level of safety you are going to need.