There is a lot of talk of Industry 4.0 and the rising ubiquity of intelligent sensors on the factory floor. While sensor proliferation is something we clearly see in factories, in process plants and even in newer building automation systems, one important change this ubiquity of sensors necessitates is the requirement to process a large number of I/Os within typically the same old controller form factor. The I/Os can be digital or analog. This requires architecting a high-density I/O module with size and heat constraints.
Digital I/O
Typically, the digital I/Os in PLCs were conditioned using discretes such as resistors/capacitors or driven using individual field-effect transistors (FETs). The need to minimize the footprint of the controllers along with the real requirement of being able to process two times to four times the number of channels are pushing a move away from discrete implementation to an integrated approach.
We could discuss the disadvantages of a discrete approach, especially when the number of channels being processed per module is eight or higher, but suffice it to say that high heat/power dissipation, the unwieldy number of discrete parts required—both from a size and a mean-time-between-failure (MTBF) perspective—and the need to have a rugged system specification have almost completely rendered the discrete approach unworkable.
Figure 1 shows the technical challenges of architecting high-density digital input (DI) and digital output (DO) modules. Size and heat are considerations in both DI and DO systems.
For digital inputs, it is also important that different types of inputs are supported—both types (type 1,2,3) of inputs and, in some cases, 24 V and 48 V inputs. In all cases, robust operating specifications are very important and sometimes wire break detection is crucial.
For digital outputs, systems use different FET configurations to drive the load. The accuracy of the drive current is generally an important consideration. And in many cases, diagnostics are important.
High-channel density digital input module
A traditional discrete design uses a resistor divider network to convert a 24 V/48 V signal to something a microcontroller can use. There can be a discrete resistor-capacitor (RC) filter at the front, as well. If isolation is a requirement, an external optocoupler is sometimes used.
Figure 2 illustrates a typical discrete approach to implement a digital input circuit.
Figure 2: This type of design is good for up to a certain number of digital inputs.
This type of design is good for up to a certain number of digital inputs, say four to eight per board. Any number beyond that and it rapidly becomes impractical. The different issues with such a discrete implementation include:
- high power consumption and associated board hot spots
- one optocoupler needed for each individual channel
- too many components resulting in low failures-in-time (FIT) rate and even requiring a larger form factor.
Most importantly, a discrete design approach means the input current increases linearly with input voltage. Assume a 2.2 KΩ input resistor and 24 V VIN. When the input is 1, that is, at 24 V, the input current is 11 mA, which equates to power consumption of 264 mW. For an eight-channel module, the power consumption is more than 2 W; and for a 32-channel module, the power consumption is more than 8 W (Figure 3).
Figure 3: Purely from a heat perspective, this discrete design cannot support multiple channels on a single board.
Purely from a heat perspective, this discrete design cannot support multiple channels on a single board.
One of the biggest advantages of an integrated digital input design is significantly lower power consumption and thus heat dissipation. Most integrated digital input devices allow for configurable input-current limiting, dramatically reducing power consumption.
With current limit set to 2.6 mA, the power dissipation is reduced significantly to approximately 60 mW per channel. An eight-channel digital input module can now be rated at less than half a Watt (Figure 4).
Figure 4: An eight-channel digital input module can now be rated at less than half a Watt.
Another reason going against a discrete logic implementation is that sometimes DI modules must support different types of inputs. The standard 24 V digital input specification published by the IEC is divided into types 1, 2, and 3. Types 1 and 3 are generally lumped together as the current, and the threshold limits are very similar. Type 2 has a 6 mA current limit, which is much higher. With a discrete approach, this would require a redesign since most discrete values would need to be updated.
However, integrated digital input products can typically support all these three types. Natively, types 1 and 3 are always supported by integrated digital input devices. However, to meet the minimum 6 mA current requirement for type 2 inputs, we need to use two channels in parallel for one field input. And just adjust the current limit resistors.
There would be a board change, but it is minimal.
For example, DI devices can have a current limit of 3.5 mA/channel. So, as shown, we would use two channels in parallel and adjust the REFDI resistor and the RIN resistors if the system must interface with Type 2 inputs. For some of the newer parts, we can also select the current value using a pin or through software (Figure 5).
Figure 5: Use two channels in parallel and adjust the REFDI resistor and the RIN resistors if the system must interface with Type 2 inputs.
To support a 48 V digital input signal, which is not a very common requirement, would require a similar process where one would have to add an external resistor to adjust the field side voltage threshold. The value of this external resistor is set so that Current limit * R + threshold at pin meets the field side voltage threshold specification, which is defined in the data sheet of the device.
Finally, since digital input modules are interfacing with sensors, they must be designed to robust operating specifications. When implemented using discretes, these protections must be carefully designed. When choosing integrated digital input devices, ensure these come with these industrial-ready specifications:
- wide input voltage range, up to 40 V, for example
- ability to operate from field supply (7 V to 65 V)
- high ESD (±15kV ESD air gap) and surge tolerant (typically, 1 KV).
It is also very useful to have over-voltage and over-temperature diagnostics so that the MCU can take appropriate action.
High-channel density digital output module
A typical discrete digital output design features a FET with drives circuitry driven by the microcontroller. There are different ways of configuring the FET to drive the microcontroller.
The definition of a high-side load switch is that it is controlled by an external enable signal and connects or disconnects a power source to a given load. Compared to a low-side load switch, a high-side switch sources current to the load, while the low-side type connects or disconnects the load to ground and therefore sinks current from the load.
While they both use a single FET, the problem with the low-side switch is that the load could get shorted to the ground. High-side switches protect the load from shorts to ground. But the low-side switch implementation is marginally lower cost. Sometimes output drivers are also configured as push-pull that requires two metal-oxide-semiconductor field-effect transistors (MOSFETs) (Figure 6).
Figure 6: Integrated DO devices can incorporate multiple DO channels in a single device.
Integrated DO devices can incorporate multiple DO channels in a single device. Since the FET configuration is different for high-side, low-side, and push-pull, different devices are available to implement each type of an output driver.
Built-in demagnetization for inductive loads
One of the key advantages of an integrated digital output device is that demagnetization for inductive loads is built into these devices.
An inductive load is any device that has coils of wire, which, when energized, generally perform some mechanical work, for example, solenoids, motors and actuators. The magnetic field caused by the current flow can move the switching contacts in a relay or contactor, operate solenoid valves or rotate a shaft in a motor.
Mostly, engineers use a high-side switch to control the inductive load, and the challenge is how to discharge the energy in the inductor when the switch opens, and the current is no longer sourced to the load.
The negative impacts of not discharging this energy correctly include potential arcing of relay contacts, large negative voltage spikes damaging sensitive industrial controllers and the generation of high-frequency noise or EMI that can affect system performance.
In a discrete implementation, the most common solution to discharge the inductive load uses a free-wheeling diode. In this circuit, while the switch is closed, the diode is reverse-biased and does not conduct any current.
When the switch opens, the negative voltage across the inductor forward biases the diode, allowing the stored energy to decay by conducting the current through the diode until steady state is reached and the current is zero.
For many applications, especially those found in industrial applications that have many output channels per I/O card, this diode is often physically quite large and adds significant extra cost and size to the design.
Modern digital output devices implement this function within the device using a kind of active clamping circuitry—for example, a safe-demagnetization feature that allows digital-output devices to safely turn off loads with unlimited inductance.
There are many important factors when selecting a digital output device. Some of the following data sheet specifications should be considered carefully:
- Look at the maximum continuous current rating and ensure that, if needed, you can parallel multiple outputs to get a higher current drive.
- Ensure the output device can drive multiple channels with high currents (over the temperature range). Refer the data sheet specifications to ensure the on-resistance, supply current and thermal resistance values are as low as possible.
- The output current drive accuracy specification is also important.
Diagnostic information is also essential to recover from some out-of-range operating conditions. First, you want diagnostic information reported per output channel. This will be temperature, overcurrent, open and shorts. On a global (chip) basis, some important diagnostics are thermal shutdown, VDD undervoltage and SPI diagnostics. Look for some or all of this in the integrated digital output device.
Programmable digital input/output device
Once we start integrating DI and DO on an industrial controller, configurable products can be built. Figure 7 shows an example of a four-channel product that can be configured as an input or an output.
Figure 7: This has a DIO core, which means a single channel can be configured as a DI (Type 1/3 or Type 2) or a digital output in either a high-side or in a push-pull mode.
This has a DIO core, which means a single channel can be configured as a DI (Type 1/3 or Type 2) or a digital output in either a high-side or in a push-pull mode. The current limit on the DO can be set from 130 mA to 1.2 A. Demagnetization is built in. To switch between Type 1/3 and Type 2 digital inputs, we only need to set a pin, and no external resistors are needed.
These devices are not only very configurable but also ruggedized to work in an industrial setting. This means high ESD, supply voltage protected up to 60 V and line-to-ground surge protection.
This is an example of something completely different (a configurable DI/DO module) possible with an integrated approach.
Conclusion
Once you are designing a high-density digital input or output module, it becomes clear that beyond a certain channel density a discrete implementation does not make a lot of sense. From heat, reliability and size considerations, an integrated device option must be carefully considered.
When choosing integrated DI or DO devices, the robust operating specifications, diagnostics and the support of multiple input-output configurations are some of the important data points to keep in mind.