Irai Automgen 7 User manual

Type
User manual
Post-processor Manual
Release #4
www.irai.com
Post-processor manual
GENERAL INFORMATION .............................................................................................................................. 7
CONFIGURATION.............................................................................................................................................. 8
CONFIGURATION FILES ........................................................................................................................................ 8
System............................................................................................................................................................ 8
Variable functions ......................................................................................................................................... 8
Start-up manufacturer code........................................................................................................................... 8
End manufacturer code ................................................................................................................................. 8
CONFIGURATION BY DEFAULT............................................................................................................................. 8
Modifying the default statements................................................................................................................... 9
Using the default statements.......................................................................................................................... 9
DISPLAYING AND MODIFYING CONFIGURATION ELEMENTS ................................................................................. 9
SYSTEM............................................................................................................................................................... 9
Hardware configuration................................................................................................................................ 9
Software configuration .................................................................................................................................. 9
Code generation options................................................................................................................................ 9
Stating the variables .................................................................................................................................... 10
Other elements............................................................................................................................................. 10
See the « System » element in text format.................................................................................................... 10
Displaying system elements......................................................................................................................... 11
VARIABLE FUNCTIONS ...................................................................................................................................... 11
Single assignment ........................................................................................................................................ 12
Linear assignment ....................................................................................................................................... 12
Automatic assignment.................................................................................................................................. 12
Types of AUTOMGEN elimination variables .............................................................................................. 13
Modifying a variable function element........................................................................................................ 17
Adding a variable function element............................................................................................................. 17
Deleting a variable function element........................................................................................................... 19
Associating an AUTOMGEN bit to a target system bit ............................................................................... 19
Associating a table of AUTOMGEN words to a table of fixed target words ............................................... 20
Associating AUTOMGEN words to target analog inputs or outputs........................................................... 20
Associating a table of AUTOMGEN bits to a table of target bits................................................................ 21
See the variable functions in text format ..................................................................................................... 21
START-UP MANUFACTURER CODE, END MANUFACTURER CODE ........................................................................ 22
Reference to an AUTOMGEN variable ....................................................................................................... 22
Referring to an AUTOMGEN application symbol....................................................................................... 22
Setting and referring to a label.................................................................................................................... 22
ENTERING MACHINE CODE IN AN APPLICATION ................................................................................................. 22
SELECTING CONNECTION OPTIONS .................................................................................................................... 22
SELECTING A CONNECTION MODE ..................................................................................................................... 23
SETTING COMMUNICATION MODULE PARAMETERS ........................................................................................... 23
POST-PROCESSOR PL7 .................................................................................................................................. 24
COMMUNICATION MODULE ............................................................................................................................... 24
GENERATING AN EXECUTABLE FILE .................................................................................................................. 25
Direct generation of a binary file ................................................................................................................ 25
Generating an « .FEF » executable file....................................................................................................... 27
USING INTERRUPT TASKS .................................................................................................................................. 29
SPECIFIC EXAMPLES .......................................................................................................................................... 29
Analog inputs/outputs.................................................................................................................................. 29
Fast counter TSX 37-10............................................................................................................................... 29
Fast counter TSX 37-10 used in counting.................................................................................................... 29
Fast counter TSX 37-22............................................................................................................................... 29
ASI ............................................................................................................................................................... 30
MAGELIS .................................................................................................................................................... 30
POST-PROCESSOR PL72 ................................................................................................................................ 31
SELECTING PROCESSOR TYPE ............................................................................................................................ 31
SPECIFIC SYNTAX ELEMENTS............................................................................................................................. 31
AUTOMGEN
7
3 (C)opyright 2004 IRAI
Post-processor manual
Calling up PL72 function blocks ................................................................................................................. 31
Using a fast task .......................................................................................................................................... 33
COMMUNICATION MODULE ............................................................................................................................... 33
SPECIFIC EXAMPLES .......................................................................................................................................... 33
Analog inputs/outputs.................................................................................................................................. 34
Fast counter................................................................................................................................................. 34
Text blocks and xbt ...................................................................................................................................... 35
UNITELWAY text blocks ............................................................................................................................. 37
POST-PROCESSOR S7200 ............................................................................................................................... 40
SELECTING CPU TYPE....................................................................................................................................... 40
COMMUNICATION MODULE ............................................................................................................................... 40
SPECIFIC EXAMPLE ............................................................................................................................................ 40
POST-PROCESSOR ABB ................................................................................................................................. 41
SELECTING PROCESSOR TYPE ............................................................................................................................ 41
Processor AC31........................................................................................................................................... 41
Processor CS31 ........................................................................................................................................... 41
COMMUNICATION MODULE ............................................................................................................................... 41
UTILITY............................................................................................................................................................. 41
SPECIFIC EXAMPLES .......................................................................................................................................... 41
Analog inputs/outputs.................................................................................................................................. 41
Interrupt....................................................................................................................................................... 41
POST-PROCESSOR GE-FANUC / ALSPA .................................................................................................... 42
SELECTING PROCESSOR TYPE ............................................................................................................................ 42
COMMUNICATION MODULE ............................................................................................................................... 42
UTILITY............................................................................................................................................................. 42
POST-PROCESSOR STEP5.............................................................................................................................. 43
COMMUNICATION MODULE ............................................................................................................................... 43
APPLICATION STRUCTURE ................................................................................................................................. 43
Selecting program blocks to use.................................................................................................................. 45
Selecting data blocks ................................................................................................................................... 45
SELECTING PROCESSOR TYPE ............................................................................................................................ 46
ASSOCIATING CODE WRITTEN ON A SHEET TO A PROGRAM BLOCK .................................................................... 46
SPECIFIC SYNTAXES .......................................................................................................................................... 46
Setting blocks............................................................................................................................................... 46
POST-PROCESSOR TSX 07............................................................................................................................. 49
COMMUNICATION MODULE ............................................................................................................................... 49
POST-PROCESSOR PS3-PS4........................................................................................................................... 50
COMMUNICATION MODULE ............................................................................................................................... 50
POST-PROCESSOR PS4................................................................................................................................... 51
MODULE DE COMMUNICATION .......................................................................................................................... 51
TRANSFERRING PROGRAMS TO MOELLER SUCOSOFT SOFTWARE ............................................................... 51
Proceed as follows to import the file generated by AUTOMGEN in the MOELLER software then inject it in
the processor. .............................................................................................................................................. 52
POST-PROCESSOR RPX ................................................................................................................................. 56
SELECTING PROCESSOR TYPE ............................................................................................................................ 56
COMMUNICATION MODULE ............................................................................................................................... 56
UTILITY............................................................................................................................................................. 56
POST-PROCESSOR PL71 ................................................................................................................................ 57
SELECTING PROCESSOR TYPE ............................................................................................................................ 57
COMMUNICATION MODULE ............................................................................................................................... 57
FAST COUNTER TASK......................................................................................................................................... 57
AUTOMGEN
7
4 (C)opyright 2004 IRAI
Post-processor manual
SPECIFIC EXAMPLES .......................................................................................................................................... 57
Counting ...................................................................................................................................................... 57
Fast counter................................................................................................................................................. 58
POST-PROCESSOR PB .................................................................................................................................... 59
SELECTING PROCESSOR TYPE ............................................................................................................................ 59
COMMUNICATION MODULE ............................................................................................................................... 59
SPECIFIC SYNTAXES .......................................................................................................................................... 59
POST-PROCESSOR SMC................................................................................................................................. 61
SELECTING PROCESSOR TYPE ............................................................................................................................ 61
COMMUNICATION MODULE ............................................................................................................................... 61
SPECIFIC SYNTAXES .......................................................................................................................................... 61
POST-PROCESSOR S7300 ............................................................................................................................... 62
COMMUNICATION MODULE ............................................................................................................................... 62
SPECIFIC SYNTAXES .......................................................................................................................................... 62
Setting block variables................................................................................................................................. 63
Calling up blocks......................................................................................................................................... 63
IMPORTING IN SIEMENS SIMATIC SOFTWARE............................................................................................... 64
STRUCTURE OF GENERATED CODE..................................................................................................................... 66
Selecting program blocks to use.................................................................................................................. 68
ASSOCIATING CODE WRITTEN ON A SHEET TO A PROGRAM BLOCK .................................................................... 68
SPECIFIC EXAMPLES .......................................................................................................................................... 68
Calling up a STEP7 block ........................................................................................................................... 68
Using an OB block....................................................................................................................................... 68
POST-PROCESSOR OMRON.......................................................................................................................... 69
SELECT PLC MODEL ......................................................................................................................................... 69
COMMUNICATION MODULE ............................................................................................................................... 69
TRANSFERRING APPLICATIONS TO THE CX-PROGRAMMER SOFTWARE ........................................................ 69
SPECIFIC SYNTAX .............................................................................................................................................. 72
ASSOCIATING CODE WRITTEN ON A SHEET TO A PROGRAM BLOCK .................................................................... 72
SPECIFIC EXAMPLE ............................................................................................................................................ 72
POST-PROCESSOR ALSPA ............................................................................................................................ 73
COMMUNICATION MODULE ............................................................................................................................... 73
POST-PROCESSOR ZELIO............................................................................................................................. 74
COMMUNICATION MODULE ............................................................................................................................... 74
POST-PROCESSOR FESTO ............................................................................................................................ 75
COMMUNICATION MODULE ............................................................................................................................... 75
GENERATING A BINARY FILE ............................................................................................................................. 75
IMPORTATION IN A FESTO SOFTWARE WORKGROUP ........................................................................................ 75
POST-PROCESSOR ALLEN-BRADLEY ....................................................................................................... 77
COMMUNICATION MODULE ............................................................................................................................... 77
TRANSFERRING PROGRAMS TO ROCKWELL RS-LOGIX 500 SOFTWARE......................................................... 77
POST-PROCESSOR TWIDO ........................................................................................................................... 79
PROCESSOR CONFIGURATION SELECTION .......................................................................................................... 79
COMMUNICATION MODULE ............................................................................................................................... 79
POST-PROCESSOR MITSUBISHI ................................................................................................................. 80
SELECTING THE TYPE OF PROCESSOR ................................................................................................................ 80
COMMUNICATION MODULE ............................................................................................................................... 80
TRANSFERRING PROGRAMS TO MITSUBISHI FX-WIN SOFTWARE................................................................. 80
TRANSFERRING PROGRAMS TO MITSUBISHI GX-DEVELOPPER SOFTWARE .............................................. 81
AUTOMGEN
7
5 (C)opyright 2004 IRAI
Post-processor manual
POST-PROCESSOR MITSUBISHI-Q............................................................................................................. 82
COMMUNICATION MODULE ............................................................................................................................... 82
TRANSFERRING PROGRAMS TO MITSUBISHI GX-DEVELOPPER SOFTWARE .............................................. 82
POST-PROCESSOR GEM................................................................................................................................ 83
COMMUNICATION MODULE ............................................................................................................................... 83
AUTOMGEN
7
6 (C)opyright 2004 IRAI
Post-processor manual
General Information
Post-processors are software modules used to translate pivot code files generated by
the AUTOMGEN compiler into executable files on a target as well as ensuring
dynamic connection of the target.
The word « Target» is a generic reference for a programmable system capable of
executing an application.
An AUTOMGEN post-processor is used to program a type or type set of targets
(generally a family of processors sharing the same language can be programmed
with the same post-processor in AUTOMGEN).
The first part of this manual contains basic information that is common to all post-
processors. Specific information regarding applications for each post-processor is
described further on.
AUTOMGEN
7
7 (C)opyright 2004 IRAI
Post-processor manual
Configuration
Please carefully read the explanations in this chapter.
Configuration files
Four configuration elements are used for each post-processor. Each is used for a
specific purpose.
System
This contains the hardware configuration of the target, software configuration, options
for modifying the way the post-processor generates the code as well as reserved
variable statements (for using inside the post-processor). Generally, depending on
the target, you will modify the hardware configuration contained in that element (for
example the type of UC or a configuration of the type of input/output cards)
Variable functions
Mastering variable functions is one of the fundamental elements for mastering the
use of post-processors.
When the post-processor translates a AUTOMGEN pivot language file into a specific
target language, it must attribute AUTOMGEN variables to the target variables.
This element contains the exact description of variable attribution. By modifying this
element you have total control over the use of the target variable space.
Start-up manufacturer code
This element contains the machine language for the target which will be placed at the
beginning of the executable code generated by the post-processor (executed at the
beginning of the cycle).
End manufacturer code
This element contains the machine language for the target which will be placed at the
end of the executable code generated by the post-processor (executed at the end of
the cycle).
Configuration by default
When a project is created, the default configuration elements are duplicated in the
project. Modifications to the project configuration elements will not affect the default
statements.
AUTOMGEN
7
8 (C)opyright 2004 IRAI
Post-processor manual
Modifying the default statements
Use the right side of the mouse to click on the element « Configuration / Post-
processor / <target name> / … » and select « Set as default configuration». The
project configuration will then be set by default (canceling of the default
configuration).
Be careful, this operation is irreversible. The configuration
element can only be restored if the post-processor is reinstalled.
Using the default statements.
Use the right side of the mouse to click on the element « Configuration / Post-
processor / <target name> / … » and select « Using default configuration». The
project configuration in progress is cancelled by the default configuration.
Displaying and modifying configuration elements
Access the configuration files by double clicking on the « Configuration / Post-
processors / <target name> / … » element. A window will open that can be used to
display and modify the configuration element.
System
This configuration element is specific for each post-processor
Hardware configuration
This area (optional) is modified to establish the hardware configuration of a target (for
example, type of CPU, input/output cards)
Software configuration
This area (optional) is modified to establish the characteristics of an application
configuration (for example, the value of a watchdog).
Code generation options
This area contains the settings for the translation method that the post-processor
must use (only for specialists). The number of options may differ from one
AUTOMGEN
7
9 (C)opyright 2004 IRAI
Post-processor manual
post-processor to another. The list below shows the options which all post-
processors have in common:
« Optimize generated code »
Generally set on « Yes».. A « No » setting is used for an easier analysis of generated
code.
« Do not generate the code of Grafcet steps »
Set to « No ». by default. If set to « Yes», in the « End machine code » you must
write the instructions used to recopy the immediate states of boolean variables
transferred to the past states (see chapter ) Managing AUTOMGEN boolean variables
« Do not generate the evolution code of user bits »
Identical to the previous option but applied to AUTOMGEN user bits (« U »
variables).
Stating the variables
These are statements of variables used internally by the post-processor. Only
specialists can modify these variables.
Other elements
There may be other specific elements for each post-processor.
See the « System » element in text format.
By clicking on the icon in the toolbar, you go from tree mode to « text » mode
(format of old AUTOMGEN versions). In « Text » format you can copy and paste
information into the configuration files.
Modification to « text » mode must be made by specialists,
inopportune modifications can lead to compiling errors which are
difficult for an inexperienced person to find.
AUTOMGEN
7
10 (C)opyright 2004 IRAI
Post-processor manual
Displaying system elements
By double clicking on « Configuration / Post-processors / <name of post-processor> /
System » the following window opens.
Example of system configuration
Variable functions
Mastering variable functions is one of the fundamental elements for mastering the
use of post-processors.
When the post-processor translates a AUTOMGEN pivot language file into a specific
target language, it must attribute AUTOMGEN variables to the target variables.
For example, if you use the AUTOMGEN word 200 in your application (called M200
or %MW200 in AUTOMGEN) this word must exist in the target memory and thus
must have a name for that target.
AUTOMGEN proposes three types of statements for variable functions.
- single assignment;
- linear assignment
- automatic assignment
Variable functions for a project will be composed of « n » assignments each one
using one of the three types.
AUTOMGEN
7
11 (C)opyright 2004 IRAI
Post-processor manual
Single assignment
This is used to associate an AUTOMGEN variable to a target variable. It is the
simplest of the statements
It can only be used if a single statement is necessary.
This statement uses two pieces of information. the name of the AUTOMGEN variable
and the name of the target variable.
« Associate this AUTOMGEN variable to that target variable », to effect a single
assignment..
Linear assignment
This form is more evolved than a single assignment.
It is used to associate a series of consecutive AUTOMGEN variables (multiple
variables of the same type where the numbers are in order) to a series of consecutive
target variables.
The assignment is normally used for:
- stating input/output variables;
- stating bit or word tables which must have a fixed address (for example, for a
link with an operator control panel).
This statement uses three pieces of information: the name of the first AUTOMGEN
variable, the name of the first target variable and the dimension of the table in
number of variables.
« Associate this AUTOMGEN variable table in order to that target variable table », to
effect a linear assignment.
Automatic assignment
This is the most complex and powerful type of statement. It is used to associate one
or more types of AUTOMGEN variables to a range of target variables.
This assignment gives the compiler the task of finding an assignment for each
variable in the generated code (as long as it corresponds to one of the types) of the
statement.
This type of statement is normally used for all AUTOMGEN application variables
where the address of the variable associated in the target does not need a precisely
fixed address.
This statement uses three pieces of information:
- the type of AUTOMGEN variables (see the chapter
)
Types of AUTOMGEN
elimination variables
- the name of the first variable of the target range;
- the number of the last variable (included) of the target range.
AUTOMGEN
7
12 (C)opyright 2004 IRAI
Post-processor manual
Automatic assignment is not used for a post-processor if another statement has not
been found for a variable. For example, if a linear assignment command sets an
attribution for the words 200 to AUTOMGEN 210, the post-processor will not use
automatic assignment to try and allocate these words.
If multiple automatic assignments exist for the same type of AUTOMGEN variable,
the post-processor will use the first range of target variables until saturation, then the
second until saturation, then the third etc.
If a variable has not been allocated at the end of using all the automatic assignments,
the compiler generates an error message indicating that the variable has not been
set.
« When you find one of these types of variables, use a variable of the target in that
area», to effect an automatic assignment.
Types of AUTOMGEN elimination variables
These are used to state variable functions, they are a subset (because more than
one target variable may be needed to allocate an AUTOMGEN variable) of
AUTOMGEN variable types.
Managing AUTOMGEN boolean variables
One of the basic principles of boolean language translation for the AUTOMGEN
compiler is to be able to access two states for the same boolean variable.
This concept refers to the idea of « execution cycle » : an entity representing the
action created by the target, consisting in reading the application instructions in a
linear mode (from the beginning to the end) and accomplishing the processing they
correspond to.
These two states are set as follows:
1- The immediate state of the variable: the state written for the last instruction
executed by the target transfers that variable either by default to the state of
the variable at the end of the last execution cycle, or if it is the first execution
cycle by default to the initialization state of the variable.
2- The past state of the variable: the state of the variable at the end of the last
execution cycle.
Comments: the two states are only valid for the main application task. Only the
immediate state has meaning for asynchronous tasks.
The code generated by the AUTOMGEN compiler assumes the following:
- assignment of a boolean variable is effected on its immediate state;
- testing of a boolean variable is effected on its past state.
AUTOMGEN
7
13 (C)opyright 2004 IRAI
Post-processor manual
These two rules are used to ensure a consistent evolution of boolean applications
and to observe the evolution rules of programs generated by a Grafcet language
description.
The code generated by the post-processor manages recopying of the variable
immediate states to variable past states at cycle end.
When a boolean variable is used in AUTOMGEN two boolean variables are used on
the target.
There are three exceptions:
1- for an all or none input, if no edge test is used, only the past state (« bi ») is
used (economy of a boolean variable).
2- for an all or none output, if no edge test is used, only the immediate state
(« o ») is used.
(this explains why only the « bi » and « o » variables are found in variable attribution
commands).
3- for the ZELIO post-processor, which effects time management of the variables
(almost identical to AUTOMGEN's) only immediate states are used in ZELIO
programming language.
Standard element syntax
« <AUTOMGEN variable name> » refers to the immediate state of a boolean
variable or a numeric variable..
« b<AUTOMGEN variable name> » refers to the past state of a boolean variable.
Special edge syntaxes
« u<AUTOMGEN variable name> » refers to the « rising edge » state of a boolean
variable.
« d<AUTOMGEN variable name> » refers to the « falling edge » state of a boolean
variable.
Special time delay syntaxes
« time <number> » refers to a time delay number.
« tproc<number> » refers to a time delay procedure..
« tcount<number> » refers to a time delay time counter.
Other special syntaxes
(only for specialists)
AUTOMGEN
7
14 (C)opyright 2004 IRAI
Post-processor manual
« ac » refers to the 16 bit accumulator.
« al » refers to the 32 bit accumulator.
« af » refers to the float accumulator.
« cf » refers to the carry flag.
« zf » refers to the zero result flag
« sf » refers to the negative result flag.
« of » refers to the overflow flag.
Displaying the variable function elements
By double clicking on « Configuration / Post-processors / <name of post-processor> /
Variable function » the following window opens.
Example of variable functions
Comment: in the event that the same post-processor can generate code for multiple
types of target (for example multiple types of processor CPU's) the different elements
can be conditioned for all of the target types or for one particular target type. If the
elements are conditioned, they are associated to « Only for xxx » lines. See the
examples below.
AUTOMGEN
7
15 (C)opyright 2004 IRAI
Post-processor manual
By clicking on the elements « + » on the tree you open the branches, « - » closes
them.
AUTOMGEN
7
16 (C)opyright 2004 IRAI
Post-processor manual
Modifying a variable function element
You can modify the elements by double clicking on them.
Example of a configuration dialogue box for a linear assignment.
Adding a variable function element
To add a new assignment, click with the right side of the mouse on the « Assignment
… » elements of the tree and select « Add » from the menu.
If multiple target types are managed by the post-processor, the following dialogue
box is used to establish if the new assignment is only for one type in particular or all
the types.
AUTOMGEN
7
17 (C)opyright 2004 IRAI
Post-processor manual
Single assignment
Linear assignment
AUTOMGEN
7
18 (C)opyright 2004 IRAI
Post-processor manual
Automatic assignment
Note that AUTOMGEN variables must always be separated using the « & »
character.
Deleting a variable function element
With the right side of the mouse, click on the variable function element and select
« Delete » from the menu.
Associating an AUTOMGEN bit to a target system bit
Two statements are necessary, the two state variables of a bit « U » (« u » and
« bu ») must be associated to a target system bit. You must create two single
assignments, for example:
Be careful, when you assign the AUTOMGEN u and bu variable to the same target
system bit, you eliminate the possibility of creating a rising or falling edge test in the
application. You can get around this problem by using the syntax « (u<n>) » or
AUTOMGEN
7
19 (C)opyright 2004 IRAI
Post-processor manual
« (u<n>) » (where « <n> » represents the bit number) in the application (this syntax
generates an intermediate bit where the edge will be correctly evaluated).
Associating a table of AUTOMGEN words to a table of fixed
target words
Only a single linear statement is necessary for this, for example:
The target words that are allocated must be free from other
assignments or the same target variables may be assigned
twice to different AUTOMGEN variables.
Associating AUTOMGEN words to target analog inputs or
outputs
Use linear statements, for example:
AUTOMGEN
7
20 (C)opyright 2004 IRAI
  • Page 1 1
  • Page 2 2
  • Page 3 3
  • Page 4 4
  • Page 5 5
  • Page 6 6
  • Page 7 7
  • Page 8 8
  • Page 9 9
  • Page 10 10
  • Page 11 11
  • Page 12 12
  • Page 13 13
  • Page 14 14
  • Page 15 15
  • Page 16 16
  • Page 17 17
  • Page 18 18
  • Page 19 19
  • Page 20 20
  • Page 21 21
  • Page 22 22
  • Page 23 23
  • Page 24 24
  • Page 25 25
  • Page 26 26
  • Page 27 27
  • Page 28 28
  • Page 29 29
  • Page 30 30
  • Page 31 31
  • Page 32 32
  • Page 33 33
  • Page 34 34
  • Page 35 35
  • Page 36 36
  • Page 37 37
  • Page 38 38
  • Page 39 39
  • Page 40 40
  • Page 41 41
  • Page 42 42
  • Page 43 43
  • Page 44 44
  • Page 45 45
  • Page 46 46
  • Page 47 47
  • Page 48 48
  • Page 49 49
  • Page 50 50
  • Page 51 51
  • Page 52 52
  • Page 53 53
  • Page 54 54
  • Page 55 55
  • Page 56 56
  • Page 57 57
  • Page 58 58
  • Page 59 59
  • Page 60 60
  • Page 61 61
  • Page 62 62
  • Page 63 63
  • Page 64 64
  • Page 65 65
  • Page 66 66
  • Page 67 67
  • Page 68 68
  • Page 69 69
  • Page 70 70
  • Page 71 71
  • Page 72 72
  • Page 73 73
  • Page 74 74
  • Page 75 75
  • Page 76 76
  • Page 77 77
  • Page 78 78
  • Page 79 79
  • Page 80 80
  • Page 81 81
  • Page 82 82
  • Page 83 83

Irai Automgen 7 User manual

Type
User manual

Ask a question and I''ll find the answer in the document

Finding information in a document is now easier with AI