Leroy-Somer MD2 User Manual

User Guide
MD29
Microprocessor card and software for
Mentor II, Vector, CDE
and HPCDE Drives
Part Number: 0400-0030
Issue Number: 4
Safety Information
Persons supervising and performing the electrical installation or maintenance of a Drive and/or an external Option Unit must be suitably qualified and competent in these duties. They should be given the opportunity to study and if necessary to discuss this User Guide before work is started.
The voltages present in the Drive and external Option Units are capable of inflicting a severe electric shock and may be lethal. The Stop function of the Drive does not remove dangerous voltages from the terminals of the Drive and external Option Unit. Mains supplies should be removed before any servicing work is performed.
The installation instructions should be adhered to. Any questions or doubt should be referred to the supplier of the equipment. It is the responsibility of the owner or user to ensure that the installation of the Drive and external Option Unit, and the way in which they are operated and maintained complies with the requirements of the Health and Safety at Work Act in the United Kingdom and applicable legislation and regulations and codes of practice in the UK or elsewhere.
The Drive software may incorporate an optional Auto-start facility. In order to prevent the risk of injury to personnel working on or near the motor or its driven equipment and to prevent potential damage to equipment, users and operators, all necessary precautions must be taken if operating the Drive in this mode.
The Stop and Start inputs of the Drive should not be relied upon to ensure safety of personnel. If a safety hazard could exist from unexpected starting of the Drive, an interlock should be installed to prevent the motor being inadvertently started.
General information
The manufacturer accepts no liability for any consequences resulting from inappropriate, negligent or incorrect installation or adjustment of the optional operating parameters of the equipment or from mismatching the variable speed drive (Drive) with the motor.
The contents of this User Guide are believed to be correct at the time of printing. In the interests of a commitment to a policy of continuous development and improvement, the manufacturer reserves the right to change the specification of the product or its performance, or the contents of the User Guide, without notice.
All rights reserved. No parts of this User Guide may be reproduced or transmitted in any form or by any means, electrical or mechanical including photocopying, recording or by any information-storage or retrieval system, without permission in writing from the publisher.
Copyright © November 1997 Control Techniques Drives Ltd Author: CT SSPD Originators AH, PB Issue Code: 29nu4 Issue Date: November 1997 S/W Version: V2.6.0 system files and later.
Contents
1 Introduction 1-1
1.1 Overview 1-1
1.2 Memory 1-2
1.3 PC requirements 1-3
1.4 Technical data for the MD29 1-3
1.5 User knowledge 1-3
2 Installation 2-1
2.1 Installation procedure 2-1
2.2 Configuring the system 2-7
3 Getting Started 3-1
3.1 Introduction 3-1
3.2 Example DPL program 3-1
3.3 Creating a DPL file using the DPL Toolkit 3-5
4 DPL Programming 4-1
4.1 Program headers 4-1
4.2 Comments 4-3
4.3 Variables 4-3
4.4 Parameters 4-5
4.5 Operators 4-5
4.6 Tasks and real-time programming 4-7
4.7 Instructions and functions 4-13
4.8 Optimizing programs 4-15
4.9 Parameter pointers 4-17
4.10 Defining aliases (constants) 4-18
5 DPL Toolkit 5-1
5.1 Overview of the DPL Toolkit 5-1
5.2 File management 5-2
5.3 Editing a program 5-5
5.4 Applying styles 5-7
5.5 Compiling and running a program 5-8
5.6 Downloading a program 5-10
5.7 Running a program 5-11
5.8 Program monitoring and debugging facilities 5-11
6 Serial Communications 6-1
6.1 Introduction 6-1
6.2 Hardware connections 6-2
6.3 ANSI communications 6-4
6.4 Serial communications modes 6-13
6.5 ANSI instructions 6-16
6.6 Example ANSI instructions 6-16
7 Reference 7-1
7.1 Tasks 7-1
7.2 Instructions and functions 7-4
8 Features 8-1
8.1 Overview 8-1
8.2 PLC parameters 8-1
8.3 Introduction 8-2
8.4 Encoder lines 8-3
8.5 Position 8-3
8.6 Enabling the position controller 8-5
8.7 Default and Reset Values 8-6
8.8 Parameter descriptions 8-7
8.9 Logic diagrams 8-19
8.10 Using S-Ramps with Digital Lock 8-24
8.11 Cam function 8-25
8.12 Reference switching 8-28
8.13 Timer/Counter unit 8-30
8.14 Digital I/O ports 8-34
8.15 Non-volatile memory storage 8-35
8.16 Using the RS232 port for Drive to Drive communications 8-35
9 Diagnostics 9-1
9.1 Run-time errors 9-1
9.2 Run-time trip codes 9-2
9.3 Compiler error messages 9-3
9.4 Advanced error-handling 9-5
10 Parameters 10-1
10.1 MD29 set-up parameters 10-1
10.2 Virtual parameters 10-4
10.3 RS485 port modes 10-10
10.4 General-purpose parameters 10-11
MD29 Issue code: 29nu4
Introduction 1-1
1 Introduction
On a Variable Speed Drive (such as Mentor II, Vector or CDE), timing functions necessary for the correct operation of power devices are performed by its own microprocessor operating in real-time. This imposes limitations on the microprocessor when carrying out other duties, resulting in a reduction of flexibility of the Drive.
To maximize this flexibility, a second processor can be used for running application-specific software. This second microprocessor is the
MD29
which allows the Drive to be easily adapted to applications by programming software in the MD29.
1.1 Overview
The MD29 is a compact microcomputer using surface-mount components on a single printed circuit board. The board is designed for easy installation.
Together with the DPL Toolkit, the
MD29 allows the programmer to write
software or use pre-written software in order to enhance the flexibility of a Variable Speed Drive.
The
MD29 is compatible with the following Drives:
Mentor II, Vector, CDE, HPCDE
The MD29AN is a special version of the MD29. It has the full functionality of the MD29 plus a CTNet interface for Mentor II Drives only. This interface replaces the dedicated RS485 port for the Control Techniques I/O Box.
Note
The term MD29 in this manual also refers to the MD29AN, unless specified otherwise.
The terms CDE750 and CDE7500 are used in this manual. CDE750 refers to the bookcase CDE 0.75kW to 11kW range (1
HP to 15HP); CDE7500 refers to the CDE 11kW to 90kW
range (7.5HP to 150HP), including the HPCDE.
MD29
Issue code: 29nu4
1-2 Introduction
DPL Toolkit (Windows™ interface)
The DPL Toolkit is contained on two diskettes. It is a program which runs in Microsoft® Windows™ Version 3.1x and Windows™ 95. Programs for the MD29 are written on a host PC using the DPL Toolkit.
Serial communications link
Host PC (Desk-top or industrial)
The MD29 uses a high-level programming language called DPLDPL (Drive Programming Language) which is in many respects similar to the BASIC language. DPL is a compiled program which gives it the ability to run at high speed.
The DPL Toolkit is used to write, compile and download a DPL program to an MD29. The Toolkit also has a comprehensive set of de-bugging facilities to aid the development and testing of the DPL program.
Connection between the MD29 and host PC is via an
RS232 serial
communications link. This link need only be used during program development, testing and commissioning. It can be disconnected after the software has been successfully loaded.
1.2 Memory
The compiled MD29 program and the user-created source program are stored in non-volatile EEPROM memory on the MD29 card. This type of memory allows the programs to be loaded using the serial port.
Latest versions of programs can be easily updated without removing any integrated circuits or without using any specialized programming equipment.
The filing system of the
MD29 allows only one program to be stored in the
MD29 at any one time.
The compiled program can be stored along with the DPL source code. This allows the site engineer to read the program stored in the
MD29, even if the
program is not on the host PC. (This option can be disabled if it is not required.)
MD29 Issue code: 29nu4
Introduction 1-3
1.3 PC requirements
The minimumminimum requirement for the DPL Toolkit is as follows:
IBM AT compatible 386SX PC, Windows™ 3.1, 4Mb RAM, DOS5
A 486
PC with 8MB RAM is recommended
1.4 Technical data for the MD29
Intel 960 32-bit RISC processor 96kb of user program storage 8kb user
RAM
16MHz clock
RS232 port for programming (IBM AT compatible) RS485 optically isolated port for permanent serial communications
Dedicated, optically-isolated
RS485 port for a Control Techniques
I/O Box (not available on MD29AN)
1.5 User knowledge
This User Guide assumes that the user has at least superficial knowledge of Microsoft® Windows™. Refer to the Windows User’s Guide for specific information on performing operations in Windows™.
MD29
Issue code: 29nu4
1-4 Introduction
MD29 Issue code: 29nu4
Installation 2-1
2 Installation
Warning
The voltages present in the Drive are capable of inflicting a severe electric shock and may be lethal. The Stop function of the Drive does not remove dangerous voltages from the Drive or the driven machine.
AC supplies to the Drive must be disconnected at least 15 minutes before any cover is removed or servicing work is performed.
2.1 Installation procedure
Installation procedures are given for the following Drives:
Mentor II,
CDE7500/ HPCDE, Vector
Mentor II Drive
Mentor II
MD29
Location of the MD29 in the Mentor II DriveLocation of the MD29 in the Mentor II Drive
MD29
Issue code: 29nu4
2-2 Installation
Refer to the Mentor II User Guide for the mechanical details. Use the following procedure to fit the
MD29 to the MDA2B circuit board of
the Drive:
1 Isolate the AC supply from the Drive. 2 Remove the front cover from the Drive. 3 Fit the four small securing pillars to the corners of the MD29. 4 Find the 40-pin header connector on the MDA2B circuit board of the
Drive.
Note
The following instruction requires you to fit the MD29 to the Drive. Correct location of the header connector is essential.
5 Fit the 40-pin connector of the MD29 on to the connector on the MDA2B
circuit board, ensuring the pins are aligned, and that the pillars on the
MDA2B circuit board are correctly aligned with the locating holes in the MD29.
6 Push the MD29 carefully into position. 7 Check again that the 40-pin connector is correctly plugged in. 8 Fit the four securing pillars on each corner of the MD29 to the Drive
circuit board.
9 Make any necessary serial cable connections to the MD29. 10 Replace the Drive cover.
MD29 Issue code: 29nu4
Installation 2-3
CDE7500 and HPCDE Drives
Refer to the
CDE
User Guide for the mechanical details.
Use the following procedure to fit the
MD29 to the IN–82 control board in the
Drive, or to the IN-90 board in the HPCDE Drive:
1 Isolate the AC supply from the Drive. 2 Remove the front cover from the Drive. 3 Fit the four long pillars to the corner holes of the MD29. 4 Find the 40-pin header connector on the IN–82 control board in the
Drive.
MD29
IN-82
SMPS
Terminal Block
Location of the MD29 on the IN-82 card in the CDE7500Location of the MD29 on the IN-82 card in the CDE7500 Drive Drive
Note
The following instruction requires you to fit the MD29 to the Drive. Correct location of the header connector is essential.
MD29
Issue code: 29nu4
2-4 Installation
5 Fit the 40-pin connector of the MD29 on to the connector on the IN–82
control board, ensuring the pins are aligned, and that the pillars on the
IN–82 control board are correctly aligned with the locating holes in the MD29.
6 Push the MD29 carefully into position. 7 Check again that the 40-pin connector is correctly plugged in. 8 Locate the four securing pillars on the corners of the MD29 to the IN–82
control board.
Note
The Drive cover cannot be re-fitted directly to the case. The cover must be raised to allow room for the MD29 card. Use the following procedure to fit the cover.
9 Fit the four hole-stud pillars (supplied with the MD29) to the corners of
the Drive.
10 Fit the pod extension connector (supplied with the MD29) to the
D-type connector of the control pod.
11 Make any necessary serial cable connections to the MD29. 12 Fit the cover on to the pillars.
MD29 Issue code: 29nu4
Installation 2-5
Vector Drive
IN-31
Terminal Block
MD29
Location of the MD29 on the IN-31 control board in the Vector DriveLocation of the MD29 on the IN-31 control board in the Vector Drive
Refer to the Vector User Guide for mechanical details. Use the following procedure to fit the MD29 to the IN-31 control board in the
Drive:
1 Isolate the AC supply from the Drive. 2 Remove the front cover from the Drive. 3 Fit the four long pillars to the corner holes of the MD29. 4 Find the 40-pin header connector on the IN–31 control board in the
Drive.
Note
The following instruction requires you to fit the MD29 to the Drive. Correct location of the header connector is essential.
MD29
Issue code: 29nu4
2-6 Installation
5 Locate the 40-pin connector of the MD29 on to the connector on the
IN–31 control board, ensuring the pins are aligned, and that the pillars
on the
IN–31 control board are correctly aligned with the locating holes
in the
MD29.
6 Push the MD29 carefully into position. 7 Check again that the 40-pin connector is correctly plugged in. 8 Fit the four securing pillars on the corners of the MD29 to the IN–31
control board.
Note
The Drive cover cannot be re-fitted directly to the case. The cover must be raised to allow room for the MD29 card. Use the following procedure to fit the cover.
9 Fit the four hole-stud pillars (supplied with the MD29) to the corners of
the Drive.
10 Fit the pod extension connector (supplied with the MD29) to the D-
type connector of the control pod.
11 Make any necessary serial cable connections to the MD29. 12 Fit the cover on to the pillars.
Bookcase CDE
It is recommended that fitting of the MD29 to bookcase Drives is carried out by an authorized distributor since internal access to the Drive is required.
MD29 Issue code: 29nu4
Installation 2-7
2.2 Configuring the system
Host PC connections
RS232 Port
The
RS232 serial port is a dedicated link to the host PC. The port is a 9-way
female D-type connector. Ready-made cables for RS232 serial communications are generally available.
The table below gives the minimum required connections between the
MD29
and a 9-way and 25-way pin COM port connector.
MD29
pin no.
9-pin connector
pin no.
25-pin connector
pin no.
22 3 33 2 55 7
The RS232 port should be used only for commissioning because isolation or protection of the port is not included.
Use the following instructions for connecting a host
PC:
1 Ensure no static charge has built up when the plug is inserted. 2 Using a maximum cable length of not more than 3 metres (10 feet),
connect an
RS232 cable to the RS232 serial port on the MD29 and to the
communications serial port of the host
PC.
Installing the DPL Toolkit in the host PC
Use either of the following procedures:
Windows 3.1
The DPL Toolkit requires a minimum of 4Mb of computer memory. This may be
RAM or
virtual memory. Virtual memory may be set in the 386386 Enhanced Enhanced section of Windows Control Panel.
1 Start Microsoft Windows 2 Insert disk 1 of the DPL Toolkit into the A: drive of the host PC. 3 In Windows Program Manager, select FileFile on the menu bar. Select RunRun. 4 Type A:\SETUP.
5 Click on
MD29
Issue code: 29nu4
2-8 Installation
Windows 95
1 Insert disk 1 of the DPL Toolkit into the A:A: drive of the host PC.
2 In the menu, select RRun...un....
3 Type A: \SETUP .
4 Click on
Downloading the system file
The MD29 has no pre-loaded system software. The first task is to program the system software using the DPL Toolkit. Use the following procedure:
1 Connect the serial communications cable to the MD29. 2 Apply AC power to the Drive. 3 In Windows 3.xx Program Manager, or in the Windows 95 Start menu,
click on:
The DPLDPL Toolkit Toolkit window appears. At the top of the window are a
menu bar and toolbar.
4 If the serial port of the host PC is not COM1, open the ProjectsProjects menu
and select ConfigureConfigure. In the drop-down menu that appears, select ComportComport. This opens a further drop-down menu which allows selection of the required communications port.
5 Click on (Open Task ManagerOpen Task Manager). After a few moments, the DPLDPL
Task ManagerTask Manager dialog box appears.
MD29 Issue code: 29nu4
Installation 2-9
If the dialog box does not appear, and all the buttons in the lower
toolbar of the window appear shaded (inactive), communications could not be established with the
MD29. Check the connecting cable is
correct, and the correct
COM port is used.
6 Click on . The File Viewer File Viewer dialog box appears.
In the panels on the left side of the dialog box the path and names of
the
.SYS files can be selected.
Note
The system files are located in directory MD29GUI\BIN\SYS.
7 Select the correct path for the required system files. Double-click on
the .
SYS file specified in the following table:
Drive File
Mentor II M2.SYS Mentor II (MD29AN) M2NET.SYS Vector VECT.SYS CDE (bookcase) CDES.SYS CDE and HPCDE CDEL.SYS
MD29
Issue code: 29nu4
2-10 Installation
Note
The system files for MD29 issue 1 are located in directory MD29GUI\BIN\SYS\MD29ISS1.
The ProgrammerProgrammer dialog box appears.
8 Click on (green light showing). The system file is now loaded
into the
MD29.
MD29 Issue code: 29nu4
Getting Started 3-1
3 Getting Started
3.1 Introduction
This chapter explains the key elements of DPL programming, and the methods used to create, compile and run an example program using the DPL Toolkit.
An example of a short
DPL program is given below, followed by explanations
of the program instructions.
3.2 Example DPL program
The DPL program described here is called SawtoothSawtooth, because it applies a repetitive cycle consisting of a linear increase in speed demand followed by an instantaneous reduction to zero, as shown in the following diagram.
Repetitve cycle produced by the Repetitve cycle produced by the SawtoothSawtooth program program
MD29
Issue code: 29nu4
3-2 Getting Started
Start
#1.18 = 0
Is #1.18 < 1000?
#1.18=#1.18+1
Yes
No
Flow diagram of program Flow diagram of program SawtoothSawtooth
Program instructions
$TITLE Sawtooth $VERSION 1.1.1 $DRIVE Mentor $AUTHO R MyName $COMPA NY MyCo //Note: T his is a c o mm e nt.
BACKGROUND{
Top: #1.18=0
DO WHI LE #1.18<1000
#1.18=#1.18+1
LOOP GOTO
Top:
}
MD29 Issue code: 29nu4
Getting Started 3-3
Explanation of the example program
$TITLE Sawtooth
The first line of a program must be
$TITLE program name. The name
can have a maximum of 64 characters.
$VERSION 1.1.1
The second line is
$VERSIO N number. The number can have a maximum
of eight characters. The recommended format is $VERSI ON 1.0.0. Updates are easily shown by increasing the last number, eg. 1.0.11.0.1.
Major modifications are shown by 2.0.02.0.0, 3.00 3.00, etc.
$DRIVE Mentor
The third line is
$DRIVE drive name. This tells the compiler which Drive
it is installed in. (Since the DPL Toolkit can be used with different types of Drive, the name of the Drive must be stated.) The list of suffixes are as follows:
MENTOR
CDE750 (bookcase CDE)
CDE7500 (large CDE and HPCDE)
VECTOR
$AUTHOR MyName $COMPANY MyCo
The fourth and fifth lines are used to define the author of the program and the company name.
Note
Unless these lines are included, the program will not be compiled.
//Note: This is a comment.
The program ignores comment lines which can be placed anywhere in a program. Comments are always preceded by either a double forward slash [////] or a semi colon[;].
Comments are useful for inserting descriptions, or for giving explanations for the benefit of the user or programmer.
BACKGROUND{
BACKGROUND is a type of Task. (All executable code must be
contained within a Task.) There are many different types of Task, which, in effect, define the priority of the code and allow blocks of code to be run on different time-bases.
The
BACKGROU N D task is a free-running task which can be compared to
the way a PLC runs a program, for example. Full details of the Tasks are given in Real-time programming in Chapter 4 DPL Programming.
MD29
Issue code: 29nu4
3-4 Getting Started
Top:
Top:Top: is a label which marks an absolute position in the program. A label must always be followed by a colon [::].
A label defines the destination of a
GOTO statement. It can be given
any name (eg. mylabelmylabel).
#1.18=0
A hash (##) expression accesses Drive parameters. In this case the parameter is 1.18 (menu 1, parameter 18). This is a preset speed reference parameter in the Mentor Drive, and it is set at zero.
DO WHILE #1.18<1000
DO WHILE is a loop statement. In this example, it gives the program an
instruction to repeat the following block of code while the value of parameter 1.18 is less than 1000.
#1.18=#1.18+1
This line adds the value 11 to parameter 1.18. Every time this command is executed, 11 is added to the parameter value.
LOOP
LOOP is the end expression for the Instruction DO WHILE. LOOP tells
the program to go back to the line DO WHILE and check that the DO
WHILE
instruction remains true. When the value of #1.18 = 10001.18 = 1000, DO
WHILE
#1.18 < 1000 #1.18 < 1000 becomes false. The instructions between DO
WHILE
and LOOP stop being repeated and the program goes to the
next line after the LOOP command.
GOTO Top:
GOTO is a flow-control instruction. In this case, it tells the program to
go to the label Top:Top:. This causes the program to run continuously.
Note
The label name must be specified using a colon[:].
} Closing brace
Instructions within braces belong to the defined Task. Closing-braces work in conjunction with opening-braces. In this example, the opening- and closing-braces work in conjunction with the Task
BACKGROUND..
MD29 Issue code: 29nu4
Getting Started 3-5
3.3 Creating a DPL file using the DPL Toolkit
This section shows how to write, compile and download the example DPL program for the Mentor II Drive.
Opening the DPL Toolkit
In Windows 3.xx Program Manager, or Windows 95 Start menu, click on:
The DPLDPL Toolkit Toolkit window appears. At the top of the window are a menu bar and toolbar.
Creating a file
1 Click on or open the File File menu and select NewNew. 2 Enter the following program exactly as it appears, using the tab key to
indent lines.
$TITLE Sawtooth $VERSION 1.1.1 $DRIVE mentor $AUTHO R MyName $COMPA NY MyCo //Note: T his is a c o mm e nt.
BACKGROUND{
Top: #1.18=0
DO WHI LE #1.18<1000
#1.18=#1.18+1
LOOP GOTO
Top:
}
MD29
Issue code: 29nu4
3-6 Getting Started
3 Open the FileFile menu and select Save As...Save As.... The Save File AsSave File As dialog box
appears.
4 In the Folders: Folders: list, select the ProjectsProjects directory. In the FileFile name: name:
text box, type
SAWTOOTH.DPL.
5 Click on . The file is now saved.
The program is ready for compiling into machine code.
Important Note
DPL programs must be saved as .DPL files. If this is not
done, the program cannot be compiled into machine code. Only the saved version of the program is compiled.
Compiling the program
The DPL Toolkit contains a compiler which converts DPL programs from text format to binary machine code which the MD29 can understand. The compiler converts the .DPL file into a binary file with a .BIN extension.
Use the following procedure.
1 Click on at the right of the Toolbar. The Compile...Compile... dialog box
appears.
MD29 Issue code: 29nu4
Getting Started 3-7
2 If the DPL source file is required to be downloaded to the MD29, ensure
the Embed DPL Source CodeEmbed DPL Source Code check box is checked. This facility allows the DPL program to be read back to the
PC at a later date (if the
computer copy becomes lost, for example).
If the DPL source file is not to be downloaded, ensure the check box is
unchecked. When the Compile...Compile... dialog box next appears, the check box retains the last setting.
(The other options in this dialog box are described in Compiling and
running programs in Chapter 5 DPL Toolkit.)
3 Click on 4 The CompilationCompilation box appears for a few seconds. It is not necessary to
observe the contents of the CompilationCompilation box.
5 The program is now compiled, ready for downloading to the MD29.
If instead a Build errorsBuild errors window appears with errors displayed, correct
the program for typing mistakes and repeat the compilation. (Error messages are described in Chapter 9, Diagnostics.)
MD29
Issue code: 29nu4
3-8 Getting Started
Connecting to the MD29
It is now necessary to establish communications from the host PC to the
MD29 in order to download the compiled file.
Use the following procedure:
Click on
. The Task Manager opens with the Task Manager toolbar
appearing below the standard toolbar.
Note
If all the buttons on the lower toolbar appear shaded, it is an indication that communications could not be established with the MD29. Check that AC power is applied to the Drive, and that the serial communications cable is correctly inserted.
Downloading the program
1 In the Task Manager toolbar, click on . The ProgrammerProgrammer dialog
box appears.
MD29 Issue code: 29nu4
Getting Started 3-9
2 In the ProgrammerProgrammer dialog box, click on (green light showing).
The files
SAWTOOTH..BIN and SAWTOOTH.. DPL are now downloaded to
the
MD29. Down-loading takes a few seconds to complete.
Note
The MD29 can hold only one compiled program (ie. .BIN file) in memory at one time. A program that is downloaded to the MD29 will over-write an existing program.
Running the program
Warning
The Sawtooth program rapidly alters the speed reference parameter of the Drive. For safety, ensure the Drive is disabled before running the program.
In the Task Manager toolbar, click on The Speed referenceSpeed reference parameter #1.18 #1.18 in the Drive will change value.
Note that the ramping-up behavior cannot be observed since the program alters the parameter value at a faster rate than the display is updated.
MD29
Issue code: 29nu4
3-10 Getting Started
Loading...
+ 128 hidden pages