![SEW-Eurodrive MOVI-PLC basic DHP11B-T0 Скачать руководство пользователя страница 48](http://html.mh-extra.com/html/sew-eurodrive/movi-plc-basic-dhp11b-t0/movi-plc-basic-dhp11b-t0_manual_1250108048.webp)
5
PROFIBUS-DP Operating Characteristics
Process data exchange with the MOVI-PLC® basic DHP11B.. controller
48
Manual – MOVI-PLC
®
basic DHP11B.. controller
STEP7 example
program
In this example, project planning for the MOVI-PLC
®
basic
DHP11B.. controller has the
process data configuration
10 PD
on input addresses PIW512... and output addresses
POW512... .
A data block DB3 with approx. 50 data words is created.
When SFC14 is called, the process input data is copied to data block DB3, data words
0 to 18. When SFC15 is called after the control program has been processed,
the process output data are copied from data words 20...38 to the output address
POW 512 ...
Note the length specification in bytes for the
RECORD
parameter. The length informa-
tion must correspond to the configured length.
Refer to the online help for STEP7 for further information about the system functions.
//Start of cyclical program processing in OB1
BEGIN
NETWORK
TITLE = Copy PI data from DHP11B control card to DB3, words 0...18
CALL SFC 14 (DPRD_DAT)
//Read DP slave record
LADDR := W#16#200
//Input address 512
RET_VAL:= MW 30
//Result in flag word 30
RECORD := P#DB3.DBX 0.0 BYTE 20 //Pointer
NETWORK
TITLE =PLC program with drive application
// PLC program uses the process data in DB3 for data exchange
// with the DHP11B control card
L DB3.DBW 0
//Load PI1
L DB3.DBW 2
//Load PI2
L DB3.DBW 4
//Load PI3
// etc.
L W#16#0006
T DB3.DBW 20 //Write 6hex to PO1
L 1500
T DB3.DBW 22 //Write 1500dec to PO2
L W#16#0000
T DB3.DBW 24 //Write 0hex to PO3
// etc.
NETWORK
TITLE = Copy PO data from DB3, words 20...38 to DHP11B control card
CALL SFC 15 (DPWR_DAT)
//Write DP slave record
LADDR := W#16#200
//Output address 512 = 200hex
RECORD := P#DB3.DBX 20.0 BYTE 20 //Pointer to DB/DW
RET_VAL:= MW 32
//Result in flag word 32
This program example is a special and free service that demonstrates only the basic
principles of generating a PLC program as a non-binding sample. We are not liable for
the contents of the sample program.
0
0
I
Содержание MOVI-PLC basic DHP11B-T0
Страница 2: ...SEW EURODRIVE Driving the world ...
Страница 95: ...SEW EURODRIVE Driving the world ...