Textual Languages

Textual languages has been developed to accomodate advanced programmers who prefer to program the plcs using known programming languages such as C or Pascal. This type of language is the closest possible to ordinary English, therefore the name structured text, as their functions can be understood by reading the program listing. The following will exclude actual structured text, as it is just a close approximation of Pascal.

Instruction List

Also known as a statement list, the instruction list is a set of instructions which operates at one instruction per line. It is comparable to the computer's assembly language which represent the lowest level language before the actual machine codes. For the experienced user, it is a very adaptable form of programming but may prove troublesome and time consuming with the availability of the graphical languages which are far easier to learn and understand. The option of instruction lists are available on the Siemens and Mitsubishi PLC range.

Firstly, a few examples will be shown in the comparison and/or conversion of ladder language in Siemens notation to instruction list. Figure 4.1 represents a simple operation in ladder format followed by the equivalent instruction list in Table 4.1. An AND operation is denoted by an A, AND/NOT operation by an AN and = sends the result to the output address Q4.11.

 

Figure 4.2 exhibits an OR operation where the equivalent instructions O denotes an OR and ON denotes an OR/NOT, as shown in Table 4.2.

 

A set of statements may be cleared of ambiguity by inserting brackets, such in the case of 5+7/3, which could be defined as (5+7)/3 or 5+(7/3) (in which case the latter is the default). An operation can be defined precisely using brackets as figure 4.3 and table 4.3 will show.

 

The Mitsubishi range of PLCs use a different format of instruction list, more resembling the computer assembly language in its commands. The PLC manual however, encourages the designer to construct a ladder language (figure 4.4) and converting it into an instruction list in Table 4.4.