In the development process of industrial automation, the emergence of programmable controllers (PCs) has completely changed the face of relay control systems. OMRON K-type PLC (including C20K, C28K, C40K, C60K), as a representative of early compact controllers, has been widely used in small and medium-sized automation equipment due to its flexible I/O configuration, rich instruction set, and reliable ladder diagram programming method. Although modern PLCs are more powerful, a large number of K-type PLCs are still in service on production lines. This article is based on the original factory operation manual and provides a comprehensive technical guide for automation engineers and maintenance personnel, covering hardware configuration, memory structure, programming methods, instruction application, debugging skills, and troubleshooting.
Chapter 1: Product Overview and Hardware Configuration
1.1 K-type CPU series
OMRON K-type PLC offers four CPU models, with the difference being the number of I/O points:
Model Input Points Output Points Total I/O
C20K 12 8 20
C28K 16 12 28
C40K 24 16 40
C60K 32 28 60
Each CPU can be connected to expansion I/O units, analog timer units, analog I/O units, or I/O link units. The extended I/O units include models such as C4K, C16P, C20P, C28P, C40P, C60P, etc., which are connected in series on the right side of the CPU through dedicated cables. When configuring the system, it should be noted that the total number of units (2 for C40K/C60K CPU and C40K/C60K expansion units, and 1 for others) should not exceed 5, and the total length of all cables should be less than 1.2 meters.
1.2 Power and Environmental Requirements
The power supply voltage of K-type PLC is 100-240VAC (or 24VDC), the working temperature is 0-50 ℃, and the humidity is 20-85% RH (without condensation). The installation environment should avoid direct sunlight, excessive temperature/humidity, condensation, corrosive or flammable gases, dust/salt, water/oil/chemicals, shock/vibration, strong electromagnetic fields, etc. The control cabinet needs to ensure good ventilation and must be grounded (grounding resistance ≤ 100 Ω).
1.3 Front panel indicator lights
POWER: Power indicator
RUN: Lights up when CPU is running normally
ERR: Illuminates when a fatal error occurs, while RUN goes off, CPU stops, and all outputs are turned off
ALARM: Illuminates when non fatal error occurs, PC continues to run
These indicator lights are the first basis for quickly diagnosing faults on site.
Chapter 2: Memory Structure - Fundamentals of Programming
The memory of K-type PLC is divided into multiple data areas and a program storage area (UM). Understanding these areas is a prerequisite for proper programming.
2.1 Internal Relay Area (IR)
The IR area is used to manage I/O points, control other bits, and temporarily store data. The address range is from words 00 to 18 (16 bits per word). among which
Words 00~09: allocated to I/O points (even numbers are input words, odd numbers are output words)
Words 10-18: As work bits, they can be used for internal logical operations
The allocation of I/O words varies among different CPUs: C20K only has words 00 and 01 (12 inputs/8 outputs); C28K words 00~03 (16 inputs/12 outputs); C40K characters 00~03 (24 inputs/16 outputs); C60K characters 00~03 (32 inputs/28 outputs). Unused IR positions can be used as working positions.
2.2 Special Relay Zone (SR)
The SR area contains system flags and control bits, with address range words 18-19 (bits 1804-1907). The key signs include:
Address function
1808 Battery Alarm Flag (ON when battery voltage is low)
1809 cycle time error flag (ON when ≥ 100ms)
1812 Constant OFF Logo
1813 Constant ON Logo
1815 First cycle flag (first cycle ON after program startup)
1903 instruction execution error flag (ER)
1904 carry mark (CY)
1905 is greater than the symbol (GR)
1906 equals the symbol (EQ)
1907 Less than Flag (LE)
1900~1902 0.1 seconds/0.2 seconds/1 second clock pulse
The constant ON/OFF flag can be used for conditions that require permanent connection or disconnection. Clock pulses can be used to generate timed or flashing outputs.
2.3 Data Storage Area (DM)
The DM area is a word access area (not addressable by bit), with addresses DM00~DM63, and is maintained when powered off. When using the high-speed drum counter (HDM), DM32~63 is occupied; When using the reversible drum counter (RDM), DM00~31 is occupied. The DM area is usually used to store set values, recipe data, etc.
2.4 Maintain Relay Zone (HR)
HR area letters HR0~HR9 (bits HR000~HR915), power off and hold, can be accessed by word or bit. Suitable for control that requires state retention after power outage (such as device state memory).
2.5 Timer/Counter Area (TC)
The TC area provides a total of 48 timer/counter numbers from TC00 to TC47. Each number can only be defined as a timer or counter (non repeatable). Accessing through TC number:
Completion flag (bit): ON when timing/counting arrives
Current value (PV): Word data
Set value (SV): Set through programmer
2.6 Temporary Relay Area (TR)