ORGANIZATION_BLOCK 主程序:OB1
TITLE=程序注释
BEGIN
Network 1 // 网络标题
// 网络注释
LD I0.1
O M0.6
S M31.0, 1
R Q2.0, 1
Network 2
LD I0.0
O I0.2
O M0.5
O M0.7
R M31.0, 1
Network 3
LD I0.2
O M0.7
R M1.1, 5
R M2.1, 7
R M3.0, 5
R M4.1, 4
S M1.0, 1
S M2.0, 1
S M4.0, 1
R M0.5, 2
Network 4
LD M31.0
O M1.0
= Q1.2
Network 5
LDN M31.0
AN Q1.2
= Q1.3
Network 6
LDN I0.3
TON T38, +50
Network 7
LD T38
A SM0.5
= Q1.4
Network 8
LD M31.0
JMP 4
Network 9
LD SM0.1
O M1.0
AN M0.1
= M1.0
Network 10
LD M1.0
LD I0.0
O M0.5
ALD
LD M1.1
A I0.3
A T37
LD M1.2
AN I0.4
A I0.6
OLD
LD M1.3
A I0.4
A I0.5
OLD
LD M1.4
A M2.5
OLD
OLD
SHRB M0.0, M1.0, +8
Network 11
LD M1.5
S M1.1, 1
Network 12
LD M1.1
A I0.3
TON T37, +20
Network 13
LD M1.3
O M1.4
= Q0.3
Network 14
LD SM0.1
O M2.0
AN M0.1
= M2.0
Network 15
LD M2.0
LD I0.2
O M0.7
ALD
LD M2.1
A I1.0
A I1.2
AN I1.3
AN M0.3
A I1.4
LD M2.2
A I0.4
OLD
LD M2.3
A I0.7
A T40
OLD
LD M2.4
A I1.1
A T41
OLD
LD M2.5
A I1.3
A T42
OLD
LD M2.6
A I1.2
OLD
LD M2.7
A I1.0
OLD
LD M3.0
AB= SMB166, 3
OLD
LD M3.1
A I0.7
AN I2.1
AN M4.3
OLD
LD M3.2
A I1.1
A T43
OLD
LD M3.3
AN I1.3
A T44
OLD
OLD
SHRB M0.0, M2.0, +13
Network 16
LD M3.4
S M2.1, 1
Network 17
LD M2.3
A I0.7
TON T40, +10
Network 18
LD M2.4
A I1.1
TON T41, +5
Network 19
LD M2.5
A I1.3
TON T42, +5
Network 20
LD M3.2
A I1.1
TON T43, +5
Network 21
LD M3.3
AN I1.3
TON T44, +5
Network 22
LD M2.3
O M3.1
S Q0.4, 1
Network 23
LD M2.7
O M2.1
R Q0.4, 1
Network 24
LD M2.4
O M2.5
O M3.2
O M3.3
= Q0.5
Network 25
LD M2.5
S Q0.6, 1
R Q0.7, 1
Network 26
LD M3.3
O I0.2
O M0.7
S Q0.7, 1
R Q0.6, 1
Network 27
LD M2.1
AN I1.4
AN M0.3
EU
MOVR 3000.0, VD300
Network 28
LD M2.1
LPS
AN M0.3
TON T50, +50
LPP
AN I0.4
A T50
S M0.3, 1
Network 29
LD M0.3
A I1.4
S M0.4, 1
Network 30
LD M0.4
TON T51, +20
Network 31
LD T51
R M0.3, 2
Network 32
LD M3.0
O M2.7
O M0.4
= Q0.1
EU
MOVR 1750.0, VD300
Network 33
LD M0.3
= Q0.2
Network 34
LD SM0.1
O M4.0
AN M0.1
= M4.0
Network 35
LD M4.0
LD I0.2
O M0.7
ALD
LD M4.1
A T52
LD M4.2
A T53
OLD
LD M4.3
A I2.4
OLD
OLD
SHRB M0.0, M4.0, +6
Network 36
LD M4.4
S M4.2, 1
Network 37
LD M4.1
TON T52, +40
Network 38
LD I2.1
TON T53, +10
Network 39
LD M4.1
O M4.3
= Q2.0
Network 40
LD M4.3
A I1.6
A I2.2
S Q1.0, 1
Network 41
LD I1.5
R Q1.0, 1
Network 42
LD M4.3
A I2.0
A I2.3
S Q1.1, 1
Network 43
LD I2.4
A I1.7
R Q1.1, 1
Network 44
LBL 4
Network 45
LD M2.1
AN I1.4
AN M0.3
O M3.0
= M10.0
Network 46
LD M10.0
CALL SBR1
Network 47
LDN M10.0
OB= SMB166, 3
CALL SBR0
END_ORGANIZATION_BLOCK
SUBROUTINE_BLOCK SBR_1:SBR0
TITLE=子程序注释
BEGIN
Network 1 // 网络标题
// 网络注释
LD SM0.0
MOVB 0, SMB67
PLS 0
END_SUBROUTINE_BLOCK
SUBROUTINE_BLOCK SBR_0:SBR1
TITLE=
BEGIN
Network 1
LD SM0.0
MOVB 3, VB500
MOVW +2000, VW501
MOVW -4, VW503
MOVD +10, VD505
MOVW +800, VW509
MOVW +0, VW511
ROUND VD300, VD300
MOVD VD300, VD513
MOVW +2000, VW517
MOVW +1, VW519
MOVD +1, VD521
Network 2
LD SM0.0
MOVB 16#A0, SMB67
MOVW +500, SMW168
ENI
PLS 0
END_SUBROUTINE_BLOCK
INTERRUPT_BLOCK INT_0:INT0
TITLE=中断程序注释
BEGIN
Network 1 // 网络标题
// 网络注释
END_INTERRUPT_BLOCK