Low-Cost, 24V Industrial Controller Is ESD-Protected

Low-Cost, 24V Industrial Controller Is ESD-Protected

Author's Contact Information


Phill Leyva

To validate a new process before its full-scale deployment, developers first test it in a small-scale pilot plant. Although controlling this plant with programmable logic controllers (PLCs) would allow maximum flexibility, PLCs are too large and expensive for such temporary use. In most cases, the alternative is hard-wired relay logic. But such an approach makes modifications difficult and time consuming. (For safety reasons, modern pilot and process plants employ 24V and 12V DC control logic rather than 120V AC logic.)

The circuit in Figure 1 incorporates PLC programmability with the low cost of relay control. These features are combined with a software program to form a robust 24V industrial controller that offers low cost, full surface-mount construction, low power, and ESD protection.

Figure 1. This low-cost, programmable industrial controller is an attractive alternative to larger, more expensive PLC controls.
Figure 1. This low-cost, programmable industrial controller is an attractive alternative to larger, more expensive PLC controls.

With an 8-bit microcontroller used to provide the program control, the circuit's eight debounced and ESD-protected inputs can accept voltages up to 24V DC. The eight open-drain outputs can handle up to 45V DC and sink up to 250mA (or 1.5A of pulsed current). A 24V, low-power linear regulator drives the circuit, while a voltage monitor with a manual reset guards against power brownouts.

CMOS switch debouncer U2 ensures robust industrial-rated inputs and a wide input-voltage range. It offers eight fully debounced and ESD-protected inputs, eight tristate outputs, and a change-of-state output (CH-bar) for simplifying connections to the microcontroller. Pull-up resistor R3 provides a logic high that disables U1 and U2 during power-up until the microcontroller I/O has been configured.

An octal D-type latch (U3) supplies eight open-drain outputs, rated to 45V DC. These outputs can easily drive process indicator lamps, isolation relays, and other logic controls in a 24V control system. A built-in voltage clamp on each output enables direct connection of relays, solenoids, buzzers, and other inductive loads. Resistor R1 ensures that all outputs are off during power-up until the microcontroller I/O has been configured.

Microcontroller U1 includes 32 bytes of RAM for variables and 1232 bytes of EPROM for storing the process control program. (A low-cost, one-time- programmable version is also available.) The bidirectional pins of port A (PA0 to PA7) furnish an 8-bit data bus for I/O data to U2 and U3. Using software, the first three pins of bidirectional port B (PB0 through PB2) are configured as outputs. As a result, they can provide the control signals EN-bar, CLR-bar, and CLK for U2 and U3.

By issuing a logic-low reset during power-up, the U5 voltage monitor ensures automatic recovery during power brownouts. U5 also offers a debounced manual reset to U1 when the reset pushbutton is pressed. R2 prevents contention with the microcontroller's bidirectional RESET-bar pin.

Power to the controllers is provided by U4, a high-voltage, low-power linear regulator configured to deliver up to 30mA from a 5V output. U4 accepts input voltages to 28V DC. Therefore, it lets the controller function with 12/24V control systems and mixed-voltage control systems (i.e., 24V field devices and 12V control logic).

Since every U2 input pin (IN1 to IN8) has an internal, 63k pull-up resistor, each one requires an applied logic low to indicate a change of state. Input "8" shows a pushbutton-switch interface where R5 limits the 24V-to-ground current to 10mA. This enables the use of low-cost switch contacts and a logic-high level (24V) as the change-of-state signal. Input "1" demonstrates a limit-switch interface inlogic low (0V) is the change-of-state signal. U3's output "1" illustrates a lamp, solenoid, or other load connected to a 24V source.

The timer function internal to the microcontroller can replace expensive relay timers in the control system. Additional inputs are easily gained by adding another switch-debouncer IC, installing a pull-down resistor on the microcontroller's IRQ-bar pin, and adding steering diodes between each CH-bar pin and U1's IRQ-bar pin. One of U1's unused port-B pins can be configured as the EN-bar signal to the new IC. For analog functions, a serial digital-to-analog converter (DAC) or analog-to-digital converter (ADC) and the microcontroller's unused port-B pins (PB3 to PB5) can be used to implement 0 to 10V or 4-20mA process controls.

A similar version of this article appeared in the July 09, 2001 issue of Electronic Design magazine.