Interface High-Voltage On/Off Signals to Low-Voltage MCUsInterface High-Voltage On/Off Signals to Low-Voltage MCUs

DN Staff

December 10, 2010

2 Min Read
Interface High-Voltage On/Off Signals to Low-Voltage MCUs

If one of your designs requires an microcontroller (MCU) to detect on/off signals from high-voltage devices, you might first think about an optical coupler or optical isolator with its LED connected to the high-voltage signal and its phototransistor connected to an MCU input. That approach will work, but your software must debounce signals from mechanical switch contacts and you’ll need several passive components to properly drive the LED and bias the phototransistor. You’ll also need one MCU input pin per switch or other sensed device.

An article, “Interfacing High-Voltage Applications to low-power controllers,” by Thomas Kugelstadt at Texas Instruments in the 4Q 2010 issue of TI’s Analog Applications Journal describes a better way to handle high-voltage inputs.  The company’s SN65HVS882 integrated circuit can handle voltages from 6 to 300 V DC and convert them into serial bit streams that require only a few I/O pins on an MCU.  The IC will work with limit switches, proximity sensors, relay contacts, push buttons, and other types of on/off devices, or devices that provide an on/off signal.  You will find the article at: focus.ti.com/lit/an/slyt393/slyt393.pdf.

According to Kugelstadt, “Internally, each input signal is checked for signal strength and stability. A current comparator detects whether the input current is higher than a predefined leakage threshold, and a voltage comparator checks whether the input voltage is higher than an internally fixed reference voltage. If both comparator outputs are logic high, a programmable debounce filter checks whether the new input status is caused by a short but strong noise transient, or whether the signal presence outlasts the debounce time and thus presents a true input signal.”

The chip also provides an output pin for each input so you can attach an LED to monitor  the status of a switch input.  That’s a helpful feature for control equipment.

You can power the interface IC in several ways and its shift-register controls operate with 3.3V logic-IC signals.  Serial transmissions can occur via shift-register or serial-peripheral-interface (SPI) timing, and a circuit can daisy-chain several SN65HVS882 integrated circuits to monitor the state of, say 24 or 64 signals, in groups of eight per IC. The serial transfer requires only three MCU pins.

For information about the SN65HVS882 IC, visit: focus.ti.com/docs/prod/folders/print/sn65hvs882.html.  TI also offers an evaluation board, SN65HVS882EVM ($US 49).  For board information, visit: focus.ti.com/docs/toolsw/folders/print/sn65hvs882evm.html.  –Jon Titus

Sign up for Design News newsletters

You May Also Like