Function Block Specifications; Function Block Elements - Omron CX-PROGRAMMER V8.1 Operation Manual

Function blocks/ structured text
Table of Contents

Advertisement

Function Block Specifications

2-1-2

Function Block Elements

Function Block
Definition Name
Language
Note
Variable Definitions
Variable Names
The following table shows the items that must be entered by the user when
defining function blocks.
Item
Function block
The name of the function block definition
definition name
Language
The programming language used in the function block defini-
tion. Select ladder programming or structured text
Variable definitions
Variable settings, such as operands and return values,
required when the function block is executed
• Type (usage) of the variable
• Name of the variable
• Data type of the variable
• Initial value of the variable
Algorithm
Enter the programming logic in ladder or structured text.
• Enter the programming logic using variables.
• Input constants directly without registering in variables.
Comment
Function blocks can have comments.
Each function block definition has a name. The names can be up to 64 char-
acters long and there are no prohibited characters. The default function block
name is FunctionBlock@, where @ is a number (assigned in order).
Function block definition name
CLOCK PULSE
EN
ENO
(BOOL) (BOOL)
ON_TIME
(INT)
OFF_TIME
(INT)
Select either ladder programming language or structured text (ST language).
(1) For details on ST language, refer to SECTION 5 Structured Text (ST)
Language Specifications in Part 2: Structured Text (ST).
(2) When nesting, function blocks using ST language and ladder language
can be combined freely (version 6.0 and higher only).
Define the operands and variables used in the function block definition.
• Variable names can be up to 30,000 characters long.
• Variables name cannot contain spaces or any of the following characters:
! " # $ % & ' ( ) = - ~ ^ \ | ' @ { [ + ; * : } ] < , > . ? /
• Variable names cannot start with a number (0 to 9).
• Variable names cannot contain two underscore characters in a row.
• The following characters cannot be used to indicate addresses in I/O
memory.
A, W, H (or HR), D (or DM), E (or EM), T (or TIM), C (or CNT) followed
by the numeric value (word address)
Section 2-1
Description
31

Hide quick links:

Advertisement

Table of Contents
loading
Need help?

Need help?

Do you have a question about the CX-PROGRAMMER V8.1 and is the answer not in the manual?

This manual is also suitable for:

Sysmac ws02-cxpc1-v8Sysmac cx-programmer 8.1

Table of Contents

Save PDF