13.2.13 Notes on Accessing Refresh Control Registers
When the refresh timer control/status register (RTCSR), refresh timer counter (RTCNT), refresh
time constant register (RTCOR), and refresh count register (RFCR) are written to, a special code
is added to the data to prevent inadvertent rewriting in the event of program runaway, etc. The
following procedures should be used for read/write operations.
Writing to RTCSR, RTCNT, RTCOR, and RFCR: A word transfer instruction must always be
used when writing to RTCSR, RTCNT, RTCOR, or RFCR. A write cannot be performed with a
byte transfer instruction.
When writing to RTCSR, RTCNT, or RTCOR, set B'10100101 in the upper byte and the write
data in the lower byte, as shown in figure 13.4. When writing to RFCR, set B'101001 in the 6 bits
starting from the MSB in the upper byte, and the write data in the remaining bits.
15
14
RTCSR,
RTCNT,
1
0
RTCOR
15
14
1
0
RFCR
Figure 13.4 Writing to RTCSR, RTCNT, RTCOR, and RFCR
Reading RTCSR, RTCNT, RTCOR, and RFCR: A 16-bit access must always be used when
reading RTCSR, RTCNT, RTCOR, or RFCR. Undefined bits are read as 0.
Rev. 4.0, 04/00, page 308 of 850
13
12
11
10
1
0
0
1
13
12
11
10
1
0
0
1
9
8
7
6
0
1
9
8
7
6
Write data
5
4
3
2
Write data
5
4
3
2
1
0
1
0