WinPLC Engine en
WinPLC Engine en
WinPLC Engine en
WinPLC-Engine
Version 1
English
Contents
1 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 4
1.1 What is WinPLC-Engine? . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 4
1.2 Applications . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6
2 Installation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7
2.1 System requirement . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7
2.2 Installation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7
2.3 Uninstall . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7
3 Getting started . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8
3.1 The STEP7 software configuration . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8
3.2 Loading mask . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11
3.3 Operating the masks in cycle mode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11
4 User interface . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20
4.1 Outline . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20
4.2 Context menu . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21
4.3 Keyboard shortcuts . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21
5 Object . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23
5.1 Text objects . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23
5.2 Dynamic text objects . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 24
5.3 LED object . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26
5.4 Analog input and output . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 27
6 Motion profiles . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 29
7 Configuration of the Software-PLC of WinPLC-Engine . . . . . . . . . . . . . . . . . . . . . . . . . . . . 30
7.1 Configuration with the WinPLC7-Engine dialog . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 30
7.1.1 PLC-Type . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 31
7.1.2 Net-Interface . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 31
7.1.3 Cycle . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 31
7.1.4 Remanence . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 31
7.1.5 Alarms . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 31
7.1.6 Time Alarms . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 31
7.1.7 Cycle Alarms . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 31
7.2 Configuration using STEP7 V5.x . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 32
8 Settings . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 33
9 Technical specifications of the Software-PLC . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 34
10 External access to the Software-PLC . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 35
11 Call parameters . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 37
English
1
1.1
Introduction
What is WinPLC-Engine?
It is possible to animate objects using motion profiles, i.e. you can, for instance,
generate a proper simulation of an elevator or lift.
The configuration of the Software-PLC may be defined by means of the configuration
dialog in WinPLC-Engine or with a hardware configuration in STEP7. If you are
entering the configuration into STEP7, you must insert the same CPU that you have
selected in WinPLC-Engine from the list in the settings dialog.
Freeware-Edition
Standard-Edition
You can use the purchased standard edition to load and simulate
all available PLC masks. You can insert text into PLC masks and
modify the addresses of inputs and outputs. However, you cannot
insert new objects. The memory of the Soft-PLC is limited to 32
KB RAM.
Compatible with "ITS-PLC MHJ-Edition".
Pro-Edition
You can use the purchased Pro-edition to load and simulate all
available PLC masks. In addition, the user can create new PLC
masks.
The memory of the Soft-PLC is limited to 240 KB of RAM.
Compatible with "ITS-PLC MHJ-Edition".
English
1.2 Applications
WinPLC-Engine is used to simulate an S7 program. The application responds like a real
S7 PLC. This means that you must first transfer the different blocks into the
Software-PLC before you turn on the RUN mode of the Software-PLC. Now you can
use all the diagnostic options provided the programming environment:
monitoring blocks
monitoring variables
module status with diagnostic buffer, I-STACK and B-STACK
etc.
In addition, you can define the hardware configuration using the STEP7 hardware
configurator and transferred the result into the Software-PLC of WinPLC-Engine by
means of the TCP/IP link.
The Software-PLC of WinPLC-Engine is configured to use the PG protocol as well as
the OP protocol via TCP/IP.
Using the OP protocol, WinCC can easily co-operate with WinPLC-Engine. This
means that you can comfortably test your graphic system representation using
WinPLC-Engine.
What is more, the Pro-edition of WinPLC-Engine enables you to create customized
masks. In this case you can insert an arbitrary background image and then place
selected objects as necessary.
The following objects are available:
Static text
Dynamic text
LED
Analog Input
Analog Output
Each of these objects may be animated (motion profiles). The integrated collision check
function can be used to control an input-LED.
Installation
2.2 Installation
English
Start the setup utility and follow the instructions that are displayed on screen.
Once the installation has been completed, a Start icon appears on your Desktop.
The WinPLC-Engine program group also contains a Start icon and the user manual
as a PDF file.
2.3 Uninstall
The Windows Uninstaller Add or Remove Programs contains the WinPLC-Engine icon
to uninstall the application.
The uninstaller also removes the entry for the adapter from STEP7 V5.x.
Getting started
Windows XP configuration:
Select LocalHost for this parameter if WinPLC engine and the programming software
are executed on the same PC.
If the applications are installed on different PCs, enter the IP address of the
WinPLC-Engine PC.
(in this fig. this is 192.168.2.112)
If port 102 is occupied, select another port, e.g. 7000 or any other unused port.
Windows Vista/Windows7 configuration:
For Windows Vista/Windows7 it is necessary to distinguish between "Computer is on a
network" and "Computer is not on a network":
Computer is on a network:
Always enter the IP address of the WinPLC-Engine computer into WinPLC-Engine.
(you cannot use LocalHost here)
Computer is not on a network:
Always specify the LocalHost address in WinPLC-Engine on computers that are not on
a network.
(no other options are available)
If port 102 is occupied, select another port, e.g. 7000 - or any other unused port.
English
Now the IP address and the port number are defined. Open the PG/PC interface dialog
to enable STEP7 V5.x communications with WinPLC-Engine.
In STEP7 V5.x, select menu item Extras->Set PG/PC Interface
Select the entry WinPLC-Engine and click on the properties button. Make sure the tick
box "Connect to real S7-300/400 and compatible PLCs" was not checked:
Enter the IP address and the port number that you have configured in
WinPLC-Engine into this figure.
Confirm the dialog with the OK button. At this point, STEP7 has been configured for
WinPLC-Engine. If WinPLC-Engine was started, you can select menu item
PLC->Accessible nodes in STEP7. You have configured STEP7 correctly if a
window with MPI address 2 is displayed:
10
English
After you have loaded a mask, editor mode is activated. If you wish to change to the
cycle mode you must select Mask->Change to cycle / chance to editor mode
(keyboard shortcut CTRL+F7).
Only now will the Software-PLC be only fully operational.
The next section describes how you can operate the mask in cycle mode.
This means that the PLC program is executed and that it can be tested.
11
You can change analog inputs by means of the mouse and the keyboard. First you must
select the required analog input with the left mouse key. A red frame indicated the
selected input.
Now you can change the analog input value by means of keyboard keys [ + ] , [ Page
Up ] and [ - ], [ Page Down ].
Use the mouse to change the value by clicking and dragging.
Fig.: Analog inputs, the upper one has a red frame and
can be changed by means of the mouse or the keyboard.
You can assign a default value to digital inputs and analog inputs. This default value is
defined in the configuration dialog for the input. The inputs are set to the default values
when you select menu item Mask->Set inputs to default values (keyboard shortcut
CTRL+F9).
At the start of a simulation (cycle mode) the inputs are set once to the default value.
It makes sense to assign default value '1' to "normally closed" contacts. This correctly
configures the inputs when the simulation is started.
12
English
You can now place different objects on the background image. Start by selecting the
object type via the mask-menu or by means of the mouse keys.
The following are available:
Static Label
Dynamic Label
LED (binary Input or Output)
Analog Input
Analog Output
Use the left mouse key to draw a rectangle (click the left mouse key and hold it, draw
the rectangle, release the mouse key).
When you release the mouse key the configuration dialog will be displayed. Here you
can define the properties.
13
Draw a rectangle at the correct position using the left mouse key:
As you can see in the figure we must now draw a rectangle around the input byte. This
means that you can immediately place the 8 LEDs at the correct location.
14
Change on tabsheet
"Common" the address to
"124".
Change the number to "8".
English
15
16
English
Draw a rectangle.
17
18
English
19
User interface
4.1 Outline
1 Menu bar
2 Mouse keys with the most important commands
3 User-defiend area
4 Status bar
20
English
A click with the right mouse key displays the context menu.
This menu contains many important commands:
Function
Remarks
CTRL+O
Open a mask
CTRL+N
CTRL+S
CTRL+B
CTRL+C
CTRL+V
CTRL+A
DEL
CTRL+D
CTRL+F
CTRL+H
CTRL+ALT+H
Align horizontally
CTRL+ALT+V
Align vertically
CTRL+ALT+A
CTRL+T
21
CTRL+F7
CTRL+F9
CTRL+U
F1
CTRL+1
CTRL+2
CTRL+3
CTRL+4
CTRL+5
CTRL+6
+ or [Page Up]
- or
[Page Down]
22
Only in simulation
mode
Object
You can also create multiple text elementsin the same manner as described for the
LEDs. This enables you to label an entire input byte in a single operation. For this
purpose, change the "Number" field in the dialog. If you have checked the tick box
"Increas address" the addresses in the text (e.g. E124.0) are incremented automatically.
23
English
Text
Text color
Background colol
Transparency
$COUNT_S7_COMMANDS
$IP_ADR
IP address of WinPLC-Engine.
Dynamic text can also be used to display text that depends on a bit address.
24
English
"Color" tab:
Here you can define the text color as well
as the background color.
25
26
English
27
"Rang" tab:
Here you select the required measurement
range.
28
Motion profiles
You can use motion profiles to assign animation properties to any object.
You can configure the profile so that a collision with an input LED changes its state to
'1'.
English
To assign a motion profile to an object (e.g., a static text object), select the object
before you open the dialog Mask->Motion profiles (CTRL+B). Choose a motion profile
in the list on the left.
Enter a bit address (e.g. A3.3) into the required directions of motion. If the address is
valid the field turns green. The filed turns red if the address is invalid or incomplete.
In the field "Speed (Pixel/Cycle)" you may specify the speed at which the object should
be moved (pixel per cycle).
If the moving object should control input LEDs check the tick box "Modify Inputs".
Click the button "Assign" to complete your entries. The current motion profile is
assigned to the selected objects.
In this manner, a total of 30 different motion profiles may be created and assigned.
The "Delete" button removes motion profiles from selected objects.
The "Show" button selects all the objects in the mask that are set to the current motion
profile.
29
You can either enter this configuration using the configuration dialog of WinPLC-Engine
or with the STEP7 V5.x hardware configurator.
Diagnostic
Specifications
30
7.1.1 PLC-Type
Here you can select the PLC-type (CPU) from a list. If required, you can extend this list.
Press the Edit button, modify the values and save the file with another name.
The PLC-type affects the properties of the Software-PLC. You can inspect the
properties of the selected CPU in the tab "Specifications".
7.1.2 Net-Interface
Here you can specify the IP address that WinPLC-Engine uses to communicate. This
entry must correspond with the entry in the Siemens dialog "Set PG/PC Interface".
7.1.3 Cycle
Under certain conditions, WinPLC-Engine may not provide all the SFB/SFC of the real
CPU. Check the tick box "Ignore not existing SFB/SFC" if the software PLC should
remain in RUN mode even if an unsupported SFB/SFC is encountered in the PLC
program.
If the values are grayed out they may not be available for changing. This situation could,
however, be modified by a service pack of WinPLC-Engine.
7.1.4 Remanence
At present, the remanence behavior of the current version of WinPLC-Engine is not
available.
For this reason, the input fields in the dialog are not active.
7.1.5 Alarms
This section is used to configure the Alarm-OBs. At present, WinPLC-Engine only
supports delay alarms OB20, OB21, OB22 and OB23.
7.1.6 Time Alarms
Here you can configure the time alarm OBs OB10 to OB17. At the appropriate
execution time, a call is issued to the respective OB if it was loaded into the Soft-PLC.
7.1.7 Cycle Alarms
The cycle alarms (OB30 to OB38) can be used to implement periodic alarms.
For instance, on the CPU315 the OB35 may be programmed. Any OBs that are grayed
out are not supported by the selected CPU.
31
English
Here you can define the different settings for the cycle and the clock memory byte.
In the Siemens hardware configurator you must also insert the CPU with the order
number
6ES7 313-5BF03-0AB0 into the rack.
Please ensure that you use a CPU with firmware rev. level 2.6:
Execute a double-click on the CPU to enter the configuration. You can transfer the
configuration into the Soft-PLC of WinPLC-Engine via PLC->Upload.
32
Settings
The "Edit" button can be used to define the storage location for the masks. Select a
path with write access privileges. This path should normally point to a folder in "My
Documents".
The samples supplied with the package are copied into the selected storage location if
you check the tick box "Add examples" and press OK.
Hint:
You can also define the storage location by specifying the respective path when you
start WinPLC-Engine.
For this purpose, the start icon of WinPLC-Engine must be modified:
Ininput box Target you may add
the storage location path following
the Exe file using the parameter
/PRJ.
Example:
C:\Program
Files\MHJ-Software\WinPLC-Engin
eV1\WinPLCEngine.exe
/PRJ="c:\MyMasks\Mask1"
In this case it is important to
enclose the path in quotes [ " ].
33
English
The following table shows the maximum configuration level of the Software-PLC in
WinPLC-Engine. You can use AG files to limit the technical properties as required by
the different types of PLCs.
The Software-PLC is designed to process the object code (MC7-code) of
S7-controllers directly. For this reason, WinPLC-Engine is also able to process
protected blocks or S7-Graph blocks.
RAM-size in byte
245.760
1.024
FC range of numbers
FC 0 - DC 2047
FB range of numbers
FB 0 - FB 2047
DB range of numbers
DB 0 - DB 1023
AB 0 - AB 2047
MB 0 - MB 2047
T 0 - T 255
Z 0 - Z 255
Accessible OBs
1, (cyclic operation)
10, 11, 12, 13, 14, 15, 16, 17, (timer alarms)
20, 21, 22, 23 (Verzgerungsalarme)
30, 31, 32, 33, 34, 35, 36, 37, 38, (cycle alarms)
40,
100, 101 (start-up)
Accessible SFCs
0, 1, 2, 3, 4, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29,
30, 31, 32, 33, 34, 43, 46, 47, 64
Accessible SFBs
0, 1, 2, 3, 4, 5, 32
Communications
TCP/IP - PG protocol
TCP/IP - OG protocol
34
9
9
English
C-language example:
BYTE *pInputs=S7AG_GetPeriEPtr();
pInputs[0]=200; //write 200decimal into inputbyte 0
pInputs[2]=50; //write 50decimal into inputbyte 2
35
1:
2:
36
11 Call parameters
Parameter
Description
Example
.maske_ini
C:\Program
Files\MHJ-Software\WinPLC-Engi
ne\WinPLCEngine.exe
d:\prj\MeineMaske.maske_ini
/NOMENU
C:\Program
Files\MHJ-Software\WinPLC-Engi
ne\WinPLCEngine.exe /NOMENU
C:\Program
Files\MHJ-Software\WinPLC-Engi
ne\WinPLCEngine.exe
/NOMOUSEBAR
/RUN
C:\Program
Files\MHJ-Software\WinPLC-Engi
ne\WinPLCEngine.exe /RUN
/READONLY
/PRJ=
/RUNTIME
English
C:\Program
Files\MHJ-Software\WinPLC-Engi
ne\WinPLCEngine.exe
d:\prj\MeineMaske.maske_ini
/RUNTIME
37
<End of Doc>
38