341
Interrupt Functions
Section 6-1
Prevention of Duplicate Processing
b.
The following example shows duplicate processing by an interrupt
task, which interrupts processing while BSET is writing to a block of
words and yields an incorrect comparison result.
Since the interrupt occurs during BSET(071) processing and before #1234 is
set in D10, the content of D0 and D10 do not match when the comparison is
made in the interrupt task (*1) and output A remains OFF.
In the end (*2), the D0 and D10 both contain #1234 and match, but the correct
comparison result is not reflected in comparison result output A.
+B
D0
#0001
D0
DI
EI
Cyclic task
Disables execution of
interrupt programs.
Enables execution of
interrupt programs.
BSET
#1234
D0
D10
CMP
D0
D10
A
1234
1234
1234
0502
ABCD
ABCD
ABCD
1234
OFF
OFF*
1
003E 0502
D0
D1
D2
D10
A
1234*
2
OFF
Cyclic task
Interrupt task
Equals Flag
#1234 set in D0.
#1234 set in D1.
#1234 set in D2.
#1234 set in D10.
BSET(071)
processing
CMP(020)
processing
Read D0.
Read D1.
Output result.
Compare D0 and D10.
Interrupted.
Continued.
Interrupt occurs.
Interrupt completed.
1234
1234
1234
Flow of Processing
Содержание CP1L CPU UNIT - 03-2009
Страница 1: ...Cat No W462 E1 06 CP1L CPU Unit SYSMAC CP Series CP1L L_0D_ CP1L M_0D_ OPERATION MANUAL...
Страница 2: ......
Страница 4: ...iv...
Страница 10: ...x...
Страница 22: ...xxii...
Страница 34: ...xxxiv Conformance to EC Directives 6...
Страница 70: ...36 Function Blocks Section 1 5...
Страница 584: ...550 Trouble Shooting Section 8 7...
Страница 627: ...593 Sample Application Section 9 12 Network Settings Network Tab Network Settings Driver Tab...
Страница 630: ...596 Sample Application Section 9 12...
Страница 654: ...620 Troubleshooting Unit Errors Section 11 4...
Страница 662: ...628 Replacing User serviceable Parts Section 12 2...
Страница 668: ...634 Standard Models Appendix A...
Страница 698: ...664 Auxiliary Area Allocations by Function Appendix C...
Страница 746: ...712 Auxiliary Area Allocations by Address Appendix D...
Страница 773: ...739 Connections to Serial Communications Option Boards Appendix F Connecting to Unit...
Страница 774: ...740 Connections to Serial Communications Option Boards Appendix F...
Страница 806: ...772 Index...
Страница 808: ...774 Revision History...