Specifications
SIMATIC Instructions
9-95
S7-200 Programmable Controller System Manual
C79000-G7076-C233-01
LAD STL
Network 1
LD SM0.1 //On the first scan call
CALL 0 //the initialization
//subroutine.
Network 1
IN
0.75
MOV_R
OUT
VD104
EN
SM0.0
Network 1
ENI
IN
0.25
MOV_R
OUT
VD112
EN
IN
0.10
MOV_R
OUT
VD116
EN
IN
30.0
MOV_R
OUT
VD120
EN
IN
0.0
MOV_R
OUT
VD124
EN
IN
100
MOV_B
OUT
SMB34
EN
INT
0
ATCH
EN
EVNT
10
SM0.1
Network 1
LD SM0.0
MOVR 0.75, VD104 //Load the loop setpoint.
// = 75% full.
MOVR 0.25, VD112 //Load the loop gain=0.25.
MOVR 0.10, VD116 //Load the loop sample
//time = 0.1 seconds.
MOVR 30.0, VD120 //Load the integral time
//= 30 minutes.
//
MOVR 0.0, VD124 //Set no derivative action.
MOVB 100, SMB34 //Set time interval
//(100 ms) for timed
//interrupt 0.
ATCH 0, 10 //Set up a timed
//interrupt to invoke
//PID execution.
ENI //Enable interrupts.
//End of subroutine 0
SBR0
EN
MAIN OB1
SUBROUTINE 0
ENO
ENO
ENO
ENO
ENO
ENO
ENO
Figure 9-28 Example of PID Loop Control