Renesas F-ZTAT H8 Series Hardware Manual page 94

8-bit single-chip microcomputer
Hide thumbs Also See for F-ZTAT H8 Series:
Table of Contents

Advertisement

2. CPU
As a result of this operation, bit 0 in PCR3 becomes 0, making P3
and 6 in PCR3 change to 1, so that P3
To avoid this problem, store a copy of the PCR3 data in a work area in memory. Perform the bit
manipulation on the data in the work area, then write this data to PCR3.
[A: Prior to executing BCLR]
MOV. B
#3F,
MOV. B
R0L,
MOV. B
R0L,
P3
7
Input/output
Input
Pin state
Low
level
PCR3
0
PDR3
1
RAM0
0
[B: BCLR instruction executed]
BCLR
#0
,
[C: After executing BCLR]
MOV. B
@RAM0, R0L
MOV. B
R0L,
P3
7
Input/output
Input
Pin state
Low
level
PCR3
0
PDR3
1
RAM0
0
Rev.3.00 Jul. 19, 2007 page 68 of 532
REJ09B0397-0300
and P3
7
R0L
The PCR3 value (H'3F) is written to a work area in memory
(RAM0) as well as to PCR3.
@RAM0
@PCR3
P3
P3
6
5
Input
Output
High
Low
level
level
0
1
0
0
0
1
@RAM0
The BCLR instruction is executed designating the PCR3
work area (RAM0).
The work area (RAM0) value is written to PCR3.
@PCR3
P3
P3
6
5
Input
Output
High
Low
level
level
0
1
0
0
0
1
0
change from input pins to output pins.
6
P3
P3
4
3
Output
Output
Low
Low
level
level
1
1
0
0
1
1
P3
P3
4
3
Output
Output
Low
Low
level
level
1
1
0
0
1
1
an input port. However, bits 7
P3
P3
2
1
Output
Output
Low
Low
level
level
1
1
0
0
1
1
P3
P3
2
1
Output
Output
Low
Low
level
level
1
1
0
0
1
1
P3
0
Output
Low
level
1
0
1
P3
0
Output
High
level
0
0
0

Advertisement

Table of Contents
loading

Table of Contents