Download Print this page

Omron NS Reference Manual page 10

Hide thumbs Also See for NS:

Advertisement

Section 1 Outline of Macro Function
NS series Macro Reference
1-3 Macro Programming
This section describes macro creation procedures and programming terms.
The Method for Writing a Macro
Delimiter of the Program
Put a semicolon (;) at the end of each program as a delimiter. However, it is not
necessary for IF (), ELSEIF (), ELSE(),ENDIF.
Example;
$W0=2;
IF ($W0>=10)
$W5=$W0-$W2;
ELSE
$W5=$W0+$W2;
ENDIF
Comment
Put single quotation mark at the beginning of the sentence when you add the comment
for each program. From single quotation mark (') to the end of character sting will be
regarded as a comment.
Example:
$W0 = 100; 'Comment
'Comment
IF ($W1==200)
···
Writing Programming Terms
Both uppercase and lowercase can be used for programming macros because they are
not classified.
Example:
-MovePopwDown () and MOVEPOPWDOWN() are regarded as same function.
-[Host1:DM0]and [host1:dm0] are regarded as same host address.
1-8

Advertisement

loading

This manual is also suitable for:

Ns-series