CHAPTER 9 TIMER/COUNTER FUNCTION (REAL-TIME PULSE UNIT)
246
User’s Manual U14492EJ3V0UD
Data setting to timer output mode registers 0, 1 (TOMR0, TOMR1) is done in the following sequence.
<1> Prepare the data to be set to timer output mode registers 0, 1 (TOMR0, TOMR1) in a general-purpose
register.
<2> Write data to the TOMR write enable registers 0, 1 (SEPC0, SPEC1).
<3> Set timer output mode registers 0, 1 (TOMR0, TOMR1) (performed with the following instructions).
•
Store instruction (ST/SST instructions)
•
Bit manipulation instruction (SET1/CLR1/NOT1 instructions)
[Description example]
<1>
MOV
0x04, r10
<2>
ST.B
r10, SPECn [r0]
<3>
ST.B
r10, TOMRn [r0]
Remark
n = 0, 1
To read the TOMRn register, no special sequence is required.
Cautions 1. Disable interrupts between SPECn issue (<2>) and TOMRn register write that immediately
follows (<3>).
2. The data written to the SPECn register is dummy data; use the same register as the general-
purpose register used to set the TOMRn register (<3> in the above example) for SPECn
register write (<2> in the above example). The same applies when using a general-purpose
register for addressing.
3. Do not write to the SPECn register or TOMRn register via DMA transfer.
Содержание V850E/IA1 mPD703116
Страница 2: ...2 User s Manual U14492EJ3V0UD MEMO...