EasyManua.ls Logo

Hitachi SH7032 - Notes on Register Access

Hitachi SH7032
690 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Loading...
123
8.2.11 Notes on Register Access
RCR, RTCSR, RTCNT, and RTCOR differ from other registers in being more difficult to write.
Data requires a password when it is written. This prevents data from being mistakenly overwritten
by program overruns and so on.
Writing to RCR, RTCSR, RTCNT, and RTCOR: Use only word transfer instructions. It is not
possible to write with byte transfer instructions. As figure 8.2 shows, when writing to RCR, place
H'5A in the upper byte and the write data in the lower byte. When writing to RTCSR, place H'A5
in the upper byte and the write data in the lower byte. When writing to RTCNT, place H'69 in the
upper byte and the write data in the lower byte. When writing to RTCOR, place H'96 in the upper
byte and the write data in the lower byte. These transfers write data in the lower byte of the
respective registers. If the upper byte differs from the above passwords, no writing occurs.
H'5A Write dataRCR
15 087
H'A5 Write dataRTCSR
15 087
H'69 Write dataRTCNT
15 087
H'96 Write dataRTCOR
15 087
Figure 8.2 Writing to RCR, RTCSR, RTCNT, and RTCOR
Reading from RCR, RTCSR, RTCNT, and RTCOR: These registers are read like other
registers. They can be read by byte and word transfer instructions. If read by word transfer, the
value of the upper eight bits is H'00.

Table of Contents

Related product manuals