The software is supplied to the user as described in this document. Any risks resulting from its quality or use remain the responsibility of the
user. The user must provide all safety measures protecting against possible maloperation.
We do not take any liability for direct or indirect damage, e.g. profit loss, order loss or any loss regarding business.
2001 Lenze GmbH & Co KG
No part of this documentation may be copied or made available to third parties without the explicit written approval of Lenze GmbH & Co KG.
All information given in this online documentation has been carefully selected and tested for compliance with the hardware and software
described. Nevertheless, discrepancies cannot be ruled out. We do not accept any responsibility or liability for any damage that may occur.
Required corrections will be included in updates of this documentation.
Windows, Windows NT and MS−DOS are either registered trademarks or trademarks of Microsoft Corporation in the U.S.A and/or other countries.
IBM and VGA are registered trademarks of International Business Machines, Inc.
All other brand names are trademarks of the corresponding owners.
This manual contains information about the function library LenzeFpiDrv.lib for the Drive PLC
Developer Studio.
· The function library LenzeFpiDrv.lib contains functions for a freely programmable RS−232C
interface with the 2103 FP interface communication module.
· With the 2103 FP interface communication module the automation interface (AIF) of the
9300 Servo PLC / Drive PLC can be used as freely programmable RS−232C interface for
controlling printers, modems, measuring devices and other components equipped with a
serial RS−232C interface.
Tip!
For installation and technical data of the 2103 FP interface communication module please see the
Mounting Instructions.
1.1.1Conventions used in this Manual
This Manual uses the following conventions to distinguish between different types of information:
Variable identifiers
are shown in the explanatory texts in italics:
· Use byEndChar1 ..."
Tip!
for information about the conventions which are used for variables of Lenze system organization
units, function blocks and functions can be obtained from the appendix of the DDS online
documentation Introduction into IEC1131−3 programming". The conventions ensure universal and
uniform labelling and support the readability of PLC programs.
Functions
can be recognized by the names. They always begin with L_":
· The function L_Rs232Open..."
Program listings
are written in Courier", keywords are printed in bold:
· IF (ReturnValue < 0) THEN..."
l
LenzeFpiDrv.lib EN 1.1
1−1
LenzeFpiDrv.lib function library
Preface and general information
1.1.2Structure of function descriptions
All function descriptions given in this Manual have the same structure:
Headline stating the function and the function identifier
Declaration of the function:
· Data type of the feedback value
· Function identifier
· List of transfer parameters
Short description of the function and its most important features
Function chart including all corresponding variables (transfer parameters
and feedback value)
Table giving information about the transfer parameters:
· Identifier
· Data type
· Possible settings
· Info
Table giving information about the feedback value:
· Data type of the feedback value
· Possible feedback values and their meaning:
Note
If a function cannot be executed properly, a negative feedback value
which is an error number, will be sent.
· Every error number stands for an error reason which is shown under
Meaning".
· If different error numbers (−1, −2, ...) are possible, every error
number is assigned to a certain priority (1, 2, ...) Functions
– The lower the number, the higher the priority,
i. e. 1" stands for highest priority.
– If several error reasons occur at the same time, the error number
with the highest priority will be sent first.
More information about the function
(Notes, tips, application examples, etc.)
1.1.3Pictograms used in this Manual
Use of
pictograms
Warning of
material damage
Other notesTip!
Signal words
Stop!Warns of potential damage to material .
Note!
1.1.4Terminology used
TermIn the following text used for
DDSDrive PLC Developer Studio
FBFunction block
FP interfaceLenze 2103 FP interface communication module
GDCGlobal Drive Control (parameter setting program from Lenze)
Parameter codesCodes for setting the functionality of a function block
SBSystem block
Consequences if disregarded:
Damage of the controller/drive system or its environment
Indicates a tip or note.
.
1−2
LenzeFpiDrv.lib EN 1.1
l
LenzeFpiDrv.lib function library
Preface and general information
1.2Version identifiers of the function library
The version of the function library can be found under the global constant
C_w[Function library name]Version .
Version identifiers as of PLC software version 7.x:
· In the example, "01050000" stands for version "1.05".
Example
value
Version: 01050000
l
LenzeFpiDrv.lib EN 1.1
1−3
LenzeFpiDrv.lib function library
Preface and general information
1−4
LenzeFpiDrv.lib EN 1.1
l
LenzeFpiDrv.lib function library
General information about the RS−232C interface
2General information about the RS−232C interface
RS−232C stands for Recommended Standard−232C, which is an American Standard of the EIA
(Electronic Industries Association). It describes the serial connection between a DTE (Data TerminalEquipment) and a DCE (Data Communications Equipment) and all the electrical and mechanical
features.
· The RS−232C is often also described by the V.24/V.28, which is the international
recommendation of the CCITT (today knows as ITU − International Telecommunication Union).
The V.24 specifies the mechanical features and the V.28 the electrical features.
Although the standard RS−232C only describes the connection between a DTE and a DCE, the
RS−232C interface has been established as standard for serial data transmission over short
distances.
The following chapters inform about the mechanical and electrical features of the RS−232C interface
and the serial data transmission.
2.1Mechanical features
2.1.1Types of plug−in connectors
In general subminiature−D−plug−in connectors in 9 or 25−pole design are used as interface
connectors. They are distinguished as follows:
Master
(e. g. Lenze PLC with FP interface)
9−pole SubD connector (male)
or
25−pole SubD socket (female)
The FP interface requires a connection cable with a 9−pole SubD connector (male).
2.1.2Terminal assignment with a FP interface
9−pole SubD socket for RS−232C interface
PinDesignationInput/outputExplanation
1−−not used
2RxDInputReceive data
3TxDOutputSend data
4DTROutputno function (logic 0")
5GND−Reference potential
6DSRInputno function
7−−not used
8−−not used
9+ 5V−max. output current 50 mA
Slave
9−pole SubD socket (female)
l
LenzeFpiDrv.lib EN 1.1
2−1
LenzeFpiDrv.lib function library
General information about the RS−232C interface
2.2Electrical features
2.2.1Voltage level
The logical states of the individual bits are sent as voltage states via send or receive cables:
Logical stateVoltage levelMin. voltage level − sender*
1−3 ... −15 V−5 V
0+3 ... +15 V+5 V
The achievable distance between two RS−232C devices depends on the cable and baud rate used.
We recommend not to exceed a distance of 15 to 30 meters at a baud rate of 9600 baud.
2.2.2Baud rate/data transmission rate
The baud rate indicates how many bits are transferred per second. This figure together with the other
transmission parameters (number of stop bits/data bits and parity bit) result in the data transmission
rate which is usually indicated in characters per second.
The following table indicates the data transmission rates possible when using a FP interface for a
transmission with 8 data bits, 1 stop bit and even parity.