EasyManuals Logo

Nidec SM-Applications Series User Manual

Nidec SM-Applications Series
132 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Page #91 background imageLoading...
Page #91 background image
SM-Applications Modules & Motion Processors User Guide 91
Issue Number: 4
Safety
Information
Introduction Installation
Getting
Started
Parameters
DPL
Programming
Communications
Freeze and
Marker
CTSync
Inter-option
Synchronization
Diagnostics
Migration
Guide
Quick
Reference
Index
Each time a UDFB is used in a DPL program, a separate instance is made that is a copy
of the UDFB with unique local variables.
7.7.4 UDFB Naming
In order to keep UDFBs unique and to avoid any naming collisions between UDFBs and
the standard library function blocks, a UDFB name must start with the underscore
character (_). The name is also limited to 16 characters, however it is recommended for
the name be kept short so that it displays neatly within the SyPTPro FBD and QuickLD
editors, e.g.
_MyFunc, _PID1 and _My_Func
These are examples of illegal names:
MyFunc, UDFB1
7.7.5 Input and Output Arguments
A UDFB can have the following data types passed into and out of it:
Integer variables
Floating point variables
Integer arrays
Floating point arrays
The input and output arguments are standard DPL variables - i.e. case-sensitive and
must start with a letter not a number. The length of input argument names is not limited,
however the FBD and QuickLD editors within SyPTPro will only show the first 5
characters of the argument.
The quantity of inputs and outputs is limited only by available memory unlike the UD70
product which was limited to 10 integer inputs and 10 integer outputs.
7.7.6 UDFB Code Sections
The code within a UDFB is split into two sections:
The initial code section
The body code section
The initial section is used for declaring and initialising any local variables that the UDFB
will use. The initial section is run for every instance of a UDFB at start-up or reset (this
occurs prior to the DPL Initial task).
The body section is where the actual code of the function block exists the part that does
the work of the function. Input and output arguments only have context within the body
section.
The two sections are separated by the keyword FBbody. Initial code goes before this
keyword, body code after.
Remember that the actual code can consist of a mixture of DPL, FBD diagrams and
QLD diagrams.
The local variables of a UDFB cannot be watched in the SyPTPro Watch Window
NOTE
The input and output arguments of a UDFB cannot be used in the initial section of the
UDFB.
NOTE

Table of Contents

Questions and Answers:

Question and Answer IconNeed help?

Do you have a question about the Nidec SM-Applications Series and is the answer not in the manual?

Nidec SM-Applications Series Specifications

General IconGeneral
BrandNidec
ModelSM-Applications Series
CategoryControl Unit
LanguageEnglish

Related product manuals