Section 01 · Practice Questions

PLC Fundamentals, Hardware & Theory

Six exam-style questions on what a PLC is and how its hardware works — the NEMA definition, opto-isolation, DC input and output modules, selection criteria, and the four-phase scan cycle. Each question opens to a full worked solution.

6Questions
6Worked Solutions
All practice sections

Attempt each question fully on paper first — sketch the diagrams and write the reasoning — then open the worked solution to compare your method.

Q1

Defining a PLC (NEMA) and its advantages over relay control

Define a Programmable Logic Controller (PLC) in accordance with the NEMA standard. Following that, identify and explain at least four key benefits that PLCs offer over conventional hard-wired or relay-based control systems, treating each advantage in turn.

ShowHide worked solution

NEMA standard definition

According to NEMA (the National Electrical Manufacturers Association), a PLC is:

A digitally operating electronic apparatus which uses a programmable memory for the internal storage of instructions for implementing specific functions such as logic, sequencing, timing, counting, and arithmetic to control, through digital or analogue input/output modules, various types of machines or processes.

Four key benefits over hard-wired relay systems

  1. Flexibility and easy reprogramming. A relay system performs one fixed logic function — changing it means physically rewiring. In a PLC the logic lives in memory: you edit the ladder program and download it. The same hardware can run a drill press today and a conveyor tomorrow.
  2. Smaller size and lower wiring cost. One PLC replaces hundreds of physical relays, timers and counters. Field devices are wired only to the I/O terminals — all interlocks and timing exist inside the program — so panel size, copper usage and labour fall sharply.
  3. Higher reliability and longer life. Mechanical relay contacts wear, bounce and arc; PLC outputs are solid-state or sealed and good for millions of operations. Built-in diagnostics — status LEDs, watchdog and scan-error flags — make faults easy to locate.
  4. Built-in advanced functions. PLCs ship with timers, counters, math, PID, communications and HMI support out of the box. Implementing PID or networking in a relay panel is effectively impossible without huge expense.

Further advantages include lower power consumption, on-line monitoring of variables, easy documentation, faster commissioning, and straightforward integration with SCADA networks.

Final Answer A PLC is a digitally operating electronic device that uses programmable memory to control machines through I/O modules. Its four main benefits over relay control are flexibility, reduced size and wiring, higher reliability, and built-in advanced functions.
Q2

The opto-isolator and galvanic isolation in the input stage

Describe the operating principle of an opto-isolator and justify its inclusion in a PLC input stage. Explain the importance of providing galvanic separation between field-side signals and the CPU, and provide a labelled circuit sketch.

ShowHide worked solution

What an opto-isolator is

An opto-isolator (or opto-coupler) is a small IC that transfers an electrical signal between two circuits using light only. Inside a single light-tight package it holds an LED on the field side and a photo-transistor on the CPU side. When current flows through the LED it emits infra-red light; that light strikes the base of the photo-transistor, which turns ON and conducts on the CPU side. There is no copper connection between the two sides — only light crosses the gap.

Field side · 24 V DC
LEDField current drives it; emits infra-red light
light → galvanic
barrier
CPU side · 5 V DC
Photo-transistorLight turns it ON; signals the CPU

The signal crosses optically — the two sides share no electrical connection.

Why galvanic isolation is essential

  • Protects the CPU from field-side voltage spikes, surges and lightning-induced transients — a 230 V short on an input cannot reach the 5 V logic.
  • Breaks ground loops between machinery and the controller, eliminating circulating-current noise.
  • Personnel safety — operator-accessible terminals are electrically separate from the internal electronics.
  • Noise immunity — fast-switching motor noise on the field side cannot couple into the CPU.
Final Answer An opto-isolator passes a signal optically — LED to photo-transistor — so the field side and CPU side share no copper connection. This galvanic separation shields the CPU from over-voltage, transients and ground loops, ensuring reliability and operator safety.
Q3

The PLC input module and its block-level structure

Discuss the role of an input module in a PLC and the tasks it carries out. Provide a block-level diagram of a typical DC input module and describe what each block does — the input terminal, the signal-conditioning stage, the isolation stage, the threshold-detection stage and the interface with the processor.

ShowHide worked solution

Role of the input module

The input module is the “ear” of the PLC. Field devices — push-buttons, limit switches, proximity sensors — produce signals at high voltage levels (e.g. 24 V DC or 110 V AC), while the CPU works at 5 V DC logic levels. The module therefore receives the field signal, reduces and cleans it, isolates the field side from the CPU, decides whether it is a logic “1” or “0”, and makes that status available to the processor’s input image table.

1Input terminal24 V DC field wire connects here
2Signal conditioningRectify & filter
3IsolationOpto-coupler
4Threshold detectionSchmitt trigger
5Logic interfaceLatch → processor

Block diagram of a typical DC input module — 24 V field signal in, clean logic bit to the CPU.

Function of each block

  1. Input terminal — the physical screw or spring terminal where the field wire connects; usually includes a status LED that lights when the field signal is present.
  2. Signal conditioning — a series resistor / voltage divider reduces the input voltage to a safe level, and an RC filter removes contact bounce and high-frequency noise (typical filter time around 10 ms).
  3. Isolation — an opto-isolator carries the signal optically, completely separating the field side from the CPU side.
  4. Threshold detection — a Schmitt trigger compares the signal against upper and lower thresholds and produces a clean logic 0 or 1, preventing chatter on slow rising or falling edges.
  5. Logic interface — a latch / buffer presents the bit to the processor bus so it can be read into the input image table during the input-scan phase.
Final Answer The input module receives a field signal, conditions it, isolates it optically, converts it to a clean logic level, and presents it to the CPU. The five stages are Terminal → Conditioning → Isolation → Threshold → Logic interface.
Q4

Block diagram and operation of a DC output module

Sketch the block diagram of a DC output module of a PLC and describe the operation of every block within it.

ShowHide worked solution

The output module is the “voice” of the PLC. The CPU sends a low-power 5 V logic signal, and the output module amplifies and isolates it before driving a real-world load — a relay coil, solenoid, lamp or motor contactor.

1From CPUOutput image table
2Logic latch / bufferHolds the bit; current gain
3IsolationOpto-coupler
4Switching deviceMOSFET / triac
5Output terminalDrives the field load

Block diagram of a typical DC output module — a 5 V logic bit becomes a controlled 24 V load signal.

Block-by-block operation

  1. From CPU / image table — at the output-update phase of the scan, the processor copies the bit from the output image table to the module.
  2. Logic latch / buffer — stores the bit so it stays stable for the rest of the scan, and provides current gain.
  3. Isolation — an opto-coupler galvanically separates the CPU side from the field switching circuit, protecting the CPU from inductive kick-back and field-wiring short-circuits.
  4. Switching device — a power transistor or MOSFET (for DC), or a triac (for AC), actually switches the load current; a free-wheeling diode across inductive loads absorbs the back-EMF.
  5. Output terminal — the screw terminal connecting to the field device, with an indicator LED showing the output state and often a fuse for short-circuit protection.
Final Answer The DC output module’s five blocks are CPU input → Latch → Optical isolation → Power switching device → Output terminal, together converting a 5 V logic bit into a controlled 24 V DC load signal.
Q5

Four principal PLC selection criteria

A number of parameters influence the choice of a PLC for a given application. List and discuss any four of the principal selection criteria.

ShowHide worked solution

When engineers select a PLC they balance technical needs against cost. Four of the most important criteria are:

  1. Number and type of I/O. Count every field signal — digital inputs (push-buttons, limit switches), digital outputs (lamps, contactors), analogue inputs (4–20 mA sensors) and analogue outputs (variable-speed drives). Add about 20% spare for future expansion, then pick a PLC whose maximum I/O exceeds that figure.
  2. Memory size and instruction set. Program memory must hold the ladder logic, data tables, recipes and message buffers — roughly 5–10 words per rung plus data. A wider instruction set (PID, math, communications) reduces development time.
  3. Speed of operation (scan time). For a fast process, such as high-speed packaging, the scan time must be much shorter than the shortest signal. Typical scan times range from about 0.1 ms per K-word on high-end CPUs up to several milliseconds.
  4. Communication and networking ability. Modern plants need Modbus, EtherNet/IP, Profibus or Profinet to talk to HMIs and SCADA — choose a PLC whose ports match the existing network.

Other valid criteria include cost, brand support and spare-part availability, environmental rating (temperature, vibration), power-supply requirements, programming-software ease of use, and redundancy or hot-standby features.

Final Answer Four main PLC-selection criteria are: (1) I/O count and type, (2) memory size and instruction set, (3) scan speed, and (4) communication options.
Q6

The PLC scan cycle and end-of-scan output update

Describe the PLC scan cycle, including the input-scan, program-execution, output-update and housekeeping phases. State the order in which they are performed, and explain why physical outputs are written only at the end of each scan.

ShowHide worked solution

The PLC repeats the same sequence of operations forever — this is the scan cycle. One pass through the cycle is a scan, and the time it takes is the scan time.

1Input scanRead all inputs
2Program executionSolve ladder rungs
3Output updateWrite all outputs
4HousekeepingComms & diagnostics

The four phases run in this order and repeat continuously — one full pass is one scan.

The four phases

  1. Input scan. The CPU reads all physical inputs simultaneously and copies their states into the input image table. This snapshot is frozen — even if a button is released during program execution, the table value stays unchanged for this scan.
  2. Program execution. The CPU solves the ladder logic rung-by-rung, left-to-right and top-to-bottom, using values from the input image table and writing results to the output image table.
  3. Output update. The CPU copies the entire output image table to the physical output terminals in one operation — only now do the real coils, lamps and contactors change.
  4. Housekeeping. The CPU handles communications (HMI, programming-port messages), runs self-diagnostics (watchdog, memory checks), updates timers and counters, and prepares for the next scan.

Why outputs are written only at the end

If outputs were updated the moment each rung completed, a later rung depending on the same bit could see a half-updated state — a race condition. Writing all outputs in one batch at the end of the scan guarantees the logic is deterministic (the same inputs always give the same outputs), the output state stays consistent with all the inputs read at the start, and each output changes at most once per scan, reducing switching wear and EMI.

Final Answer The scan cycle order is Input Scan → Program Execution → Output Update → Housekeeping, repeated forever. Outputs are written together at the end of every scan so the ladder logic stays deterministic and race-free.