Electronic – Interfacing a button to a microcontroller (and PC) with a 50 m long cable

analogcablescircuit-protectionisolationopto-isolator

I am designing a board that will be plugged into a computer and will read the status of a button ~50 m away in an office environment (it's actually a lot closer, but the cable is long).

I think it's a good idea to galvanically isolate the button wiring from the computer, since the PC will be grounded. I don't want any faults on the wiring to be able to damage the computer.

I'm assuming less than 100 ohm resistance for the cable, and while a simple series resistor would work, I think having a constant current sink for the opto LED is safer (i.e. if the cable has to be a lot longer, or shorter, etc.).

Is this a sensible approach to it? Cost/space is not much an issue, so I could add some protection/filtering circuitry, but I'm not entirely sure where/how to do it, so I'd be happy to hear some suggestions.

schematic

simulate this circuit – Schematic created using CircuitLab

Best Answer

Looks like too much circuitry, which leads to more cost, complexity, failures. There is nothing in the question that indicates anything more than series resistors are required. Adding components, like isolated switching power supplies, adds components with much higher failure rates than a few resistors and diodes. The circuit below is well protected, simple, reliable, and goes high/low when switch is closed/open. There would need to be a specific, compelling reason to add all that circuitry in the question.

schematic

simulate this circuit – Schematic created using CircuitLab