Digital inputs read contacts and sensors at 24 V DC, with PNP or NPN logic; outputs can be relay, transistor, or triac depending on the load. Analog signals handle 4-20 mA or 0-10 V. Wiring takes care of the common, the supply, isolation, protection of inductive outputs, and separation from power.
Short answer
Inputs convert field contacts and sensors into bits or numbers; outputs convert program commands into signals able to drive coils, lamps, valves, or drives. They are divided into digital (two states) and analog (a continuous quantity). Choosing the right type and wiring it with the right common and isolation avoids most commissioning faults. The PLC as a whole is described in what a PLC is and its scan cycle.
Digital inputs
Most work at 24 V DC. There are also 120 or 230 V AC versions, used where the field already carries that voltage. Pneumatic cylinders, 5/2 valves and solenoid valves are explained in industrial pneumatics basics.
| Concept | What it means |
|---|---|
| Sourcing or sinking | Defines whether the module supplies or receives current at the input point |
| PNP sensor | When activated, it delivers the positive to the input |
| NPN sensor | When activated, it connects the input to the negative |
| Common | Terminal shared by a group of inputs; its connection determines the polarity |
| Input filter | Delay that discards bounce and noise; limits short pulses |
| Isolation | Galvanic separation between the field and the PLC logic |
For dry contacts (pushbuttons, limit switches, the auxiliary contact of a contactor), the circuit is fed with 24 V and the contact closes the circuit to the input. Three-wire sensors (brown positive, blue negative, black signal, in the usual color code) require their type to match that of the module. Inductive, capacitive and photoelectric proximity sensors, with PNP or NPN output, are explained in inductive, capacitive and photoelectric sensors.
A design criterion already mentioned in ladder: stop devices and protections are wired normally closed, so that a broken wire is interpreted as a stop.
Digital outputs
| Type | Handles | Advantages | Limits |
|---|---|---|---|
| Relay | DC and AC, higher voltages | Full isolation per point, accepts varied loads | Switches slowly, limited operating life |
| Transistor | DC, normally 24 V | Fast, no wear, suited to pulses | Small current, sensitive to short circuits |
| Triac | AC | No mechanical wear, useful with resistive loads and small valves | Leakage current at rest, AC only |
Each point has a maximum current and each group of points has a maximum total current. A contactor coil or a valve is an inductive load: when the circuit opens it generates a voltage spike. With DC transistor outputs, a flyback diode is installed across the load; on AC, an RC snubber or varistor. With a relay output, the spike wears the contacts and can inject noise into the rest of the panel.
Illustrative example: output for the 15 kW motor contactor
Assumed data: 15 kW, 400 V motor, with contactor KM1 having a 24 V DC coil that draws 5 W (assumed value; each contactor has its own). The output module is transistor type, with an assumed maximum of 0.5 A per point.
Coil current = 5 W / 24 V ≈ 0.21 A, within the assumed 0.5 A limit. The output can drive it directly, with a diode across the coil. If the contactor were 230 V AC, one of two resources would be used: an interface relay with a 24 V coil and a contact rated for the contactor voltage, or a relay output module.
The contactor’s power contacts carry the motor’s approximately 28 A; the PLC never sees that current. The power and control schematic is developed in the guide on direct-on-line motor starting.
Analog inputs and outputs
| Signal | Use | Note |
|---|---|---|
| 4-20 mA | Pressure, level, temperature, and flow transmitters | Immune to cable voltage drop; 4 mA is the live zero |
| 0-10 V | Setpoints, potentiometers, some sensors | Sensitive to noise and to drop on long cables |
| Temperature probes (Pt100 RTD, thermocouple) | Direct measurement | Dedicated modules or transmitters |
The module converts the signal to an integer (counts) that the program scales to engineering units, as shown in the Structured Text example. For current inputs, check whether the transmitter is two-wire (powered by the loop) or four-wire, and whether the module supplies that power. Analog outputs, such as the speed reference to a drive, have a minimum and maximum load the module accepts.
Wiring practices
- Separate power and signal. 400 V and drive cables run away from signal cables, and cross them at right angles.
- Shield analog signals, with the shield grounded at one end only, per the manufacturer’s criterion.
- Power the field from a properly sized 24 V supply, with circuit protection and spare capacity.
- Protect by groups. One fuse or miniature circuit breaker per group of outputs.
- Label every cable and terminal with the same reference as the schematic and the program.
- Leave spares: free points for expansion.
- Separate supplies: the PLC’s, the inputs’, and the outputs’, when the design calls for it, so that a field fault does not shut down the controller.
Special inputs
Some signals do not fit an ordinary digital input:
| Signal | Module or function | Note |
|---|---|---|
| High-frequency pulses (encoders, flowmeters) | Fast counter input | The normal input filter would lose them |
| Position and speed | Encoder module | Counts edges in hardware |
| Temperature with Pt100 or thermocouple | Temperature module | Compensates cold junction and linearizes |
| Line current and voltage | Measurement module or external meter over a network | Not measured directly on an ordinary input |
| Safety signals | Certified safety inputs | Dual channels and diagnostics |
Electrical measurement of power, voltage, and energy is better handled with a dedicated meter connected over a network than with analog inputs, as discussed in Modbus RTU and TCP.
Point-to-point test
Before operation, each input and output is verified against the schematic: the field device is actuated and the bit is observed in the PLC. For outputs, the output is forced with the equipment decoupled from the load and the actuator is observed. The test records the terminal, the symbol, the result, and who performed it. It is a record that clients with audits ask for, and it is the fastest way to find reversed polarities, crossed wires, and badly powered sensors before energizing the process. Outputs that control power are tested first with the power load blocked.
Input and output diagnostics
Modern modules report their own faults: a short circuit on an output, a broken wire on an analog input, loss of field power. That diagnostic is brought to an HMI alarm so maintenance can act before the process is affected. When an output does not respond, the order of checks is simple: the bit in the program, the module’s indicator light, the voltage at the terminal, the interface relay, and finally the load. This order separates a program cause from a field cause in a few minutes.
Common mistakes
- Sensor and module of different polarity (PNP with a sinking module).
- Exceeding the current per point or per group.
- Inductive loads without suppression.
- Sharing the common between different voltages.
- Signal cables next to drives without shielding.
- Stop input wired normally open.
- Analog scaling with a wrongly declared range.
- Shared 24 V supply without protection, so that a short circuit in the field shuts down the PLC.
- Not documenting which point goes to which equipment.
Checklist
- Input type compatible with each sensor.
- Currents per point and per group within limits.
- Suppression on every inductive load.
- Stops and protections wired normally closed.
- Analog signals shielded and separated from power.
- Supplies protected by group and with spare capacity.
- Terminals and wires labeled as in the schematic.
- Spare points provided.
- Point-to-point test of every input and output before energizing the process.
Frequently asked technical questions
- What is galvanic isolation? There is no direct electrical connection between the field and the logic; it is achieved with optocouplers or relays.
- Can three-wire sensors be connected in series? It is not advisable; each one gets its own input.
- How much cable does a 4-20 mA signal allow? It depends on the total loop resistance and the available voltage; the module and transmitter datasheets give the limit.
- How are the I/O checked? With a point-to-point test against the schematic. It is part of commissioning.
How we help
The point-to-point test of inputs and outputs, insulation verification, and review of the schematics before energizing are part of an orderly commissioning. At Tiza Group we do the engineering design and the field tests, and leave the system ready to operate. See engineering design and studies and testing and commissioning, or write to us through contact.
Related guides
- Interlocking: mechanical and electrical
- Direct-on-line motor starting: power and control schematic
- GRAFCET and SFC: programming sequences in PLCs
- Addressing and data types in PLCs
- Intelligent MCC: CENTERLINE 2100, SIVACON S8, MNS, Okken
- LV Motor Protection: TeSys T, SIMOCODE pro and E300
- Induction motor protection: 49, 46, 50/51, 37, 66, 87M
- PLCs in Substations: Uses, IEC 61131-3 and Testing
References
- Hugh Jack, Automating Manufacturing Systems with PLCs (CC BY-NC-SA 3.0 US), chapters on inputs and outputs.
- Siemens SCE, training documents on controllers (account required).
- IEC 61131-2, requirements for programmable controller equipment (paid standard).
Frequently asked questions
What is the difference between a PNP and an NPN sensor?
A PNP delivers the positive to the input when it activates; an NPN connects the input to the negative. The PLC input must be compatible with the sensor type, or the PLC will not see it. It is a datasheet item for the module.
When should I use a relay output and when a transistor output?
A relay handles DC and AC, higher voltages, and isolates each point, but it switches slowly and wears out. A transistor switches fast and does not wear out, but it handles only DC and small loads.
Why a 4-20 mA signal and not 0-20 mA?
Because the live zero at 4 mA lets you tell a minimum measurement from a broken wire: if the current drops to zero, it is a fault and not a valid value.
Can a contactor coil be connected directly to the PLC output?
Only if the output and the coil current allow it according to the datasheet. An interface relay is often used to isolate and protect the output, and suppression is added against the voltage the coil generates when it is switched off.