CHAPTER 22 INTERRUPT FUNCTIONS
430
User’s Manual U12697EJ3V0UM
(2) Configuration of macro service channel
The macro service channel consists of only a 16-bit macro service counter (MSC). The lower 8 bits of the address
of the MSC are written to the channel pointer.
Figure 22-41. Counter Mode
Macro service channel
Macro service
counter (MSC)
Higher 8 bytes
Lower 8 bytes
Higher addresses
Lower addresses
Channel pointer
Mode register
7
0
(3) Example of using counter mode
Here is an example of counting the number of edges input to external interrupt pin INTP5.
Figure 22-42. Counting Number of Edges
Remark
The internal RAM address in the figure above is the value when the LOCATION 0H instruction is
executed.
When the LOCATION 0FH instruction is executed, add 0F0000H to this value.
(Internal RAM)
INTP5 macro service request
MSC 0EH
Higher 8 bytes
Lower 8 bytes
Channel pointer 7EH
Mode register 00H
Counter mode
Interrupt request is generated when MSC = 0.
Internal bus
0FE7EH
–1
INTP5/P05