Instruction list

from Wikipedia, the free encyclopedia

The instruction list , usually called AWL or IL (Instruction List) for short , is one of the methods standardized in IEC 61131-3 for programming programmable logic controllers (PLC). Many PLC manufacturers refer to the language they use as STL even if they do not strictly adhere to IEC 61131-3, so that existing STL programs can hardly be transferred to controllers from other manufacturers.

STL is mainly used for the logical connection of control inputs and outputs. Typically a (digital) input is loaded into the working register (also called an accumulator) (load digital input 0, "LD% IX0.0"), linked with other inputs, constants or memory values ​​( exclusive or memory bit 3, "XOR%" MX0.3 ") and written to an output (store digital output 1," ST% QX0.1 ").

The main features of STL are that operators only have one operand and the syntax of the language is based on the assembly language . It therefore only offers very cumbersome structuring options using jump commands. However, there are advantages if the program code is to be kept small due to a lack of memory in the CPU used. STL programs are still relatively common on older controls. However, compared to programs in higher languages, STL programs are very confusing and difficult to maintain, especially for larger projects. Today, therefore, the higher-level languages ​​of IEC 61131-3, in particular structured text (ST) or sequential function chart , continuous function chart or in many cases also C, are normally used for programming controls .

STL example programs

Example 1: AND operation of two binary inputs on one output

LD  INPUT1
AND INPUT2
ST  OUTPUT

Example 2: Adding two integer values

LD  WERT1
ADD WERT2
ST  OUTPUT

Example 3: RS flip-flop (reset dominant)

LD  S-INPUT
S   AUSGANG
LD  R-INPUT
R   AUSGANG

literature