beautypg.com

Q & a, 2 what is the count clock of the timebase counter, 3 how to operate the timebase timer – FUJITSU MB91460 SERIES FR60 User Manual

Page 285: 6 how about the interrupt-associated registers

background image

269

Chapter 19 Timebase Timer

7.Q & A

7. Q & A

7.1 What are the types of interval time used in the timebase timer (and the timebase

counter used by the timebase timer) and how to select them?

There are eight types of interval time, and they are set using the interval selection bit (TBCR.TBC[2:0]).

F: This is the base clock. (Refer to “

Chapter 13 Clock Control (Page No.189)

”.)

7.2 What Is the count clock of the timebase counter?

The count clock is a base clock. Refer to “

Chapter 13 Clock Control (Page No.189)

”.

7.3 How to operate the timebase timer?

The timebase timer is always operating. (Setting is unnecessary.)

However, to use interval interrupt, interrupt setting is required.

7.4 How is the timebase timer (=timebase counter) operation stopped?

It cannot be stopped.

7.5 How is the timebase counter (=timebase timer) cleared?

If you write {A5

H

} and {5A

H

} successively in the timebase counter clear register CTBR, the timebase counter

is cleared immediately after {5A

H

}. (All bits are “0”.)

However, if the timebase counter is cleared, the watchdog timer is affected. (Refer to

8.

Caution (Page

No.271)

”)

7.6 How about the interrupt-associated registers?

Setting timebase timer’s interrupt vector and interrupt level

The relationship between the interrupt level and vector is shown in the following table.

Refer to “

Chapter 24 Interrupt Control (Page No.311)

” for more information on the interrupt level and interrupt

vector.

The interrupt request flag (TBCR.TBIF) cannot automatically be cleared. As a result, clear it by the software
before returning from an interrupt service. (Write “0” in the interrupt request flag (TBIF).)

Timebase timer

Interval time

Interval selection bit

(TBC[2:0])

Example Interval time

F

Φ

=2MHz

F

Φ

= 32MHz

F

Φ

=

32.768kHz

How to select

Φ × 2

11

?

Set the value to “000”

1.024ms

64

µ

s

62.5ms

How to select

Φ × 2

12

?

Set the value to “001”

2.048ms

128

µ

s

125ms

How to select

Φ × 2

13

?

Set the value to “010”

4.096ms

256

µ

s

256ms

How to select

Φ × 2

22

?

Set the value to “011”

2.097s

131ms

128s

How to select

Φ × 2

23

?

Set the value to “100”

4.194s

262ms

256s

How to select

Φ × 2

24

?

Set the value to “101”

8.388s

524ms

512s

How to select

Φ × 2

25

?

Set the value to “110”

16.77s

1.04s

1024s

How to select

Φ × 2

26

?

Set the value to “111”

33.55s

2.09s

2048s

Interrupt vector (default)

Interrupt level setting bit (ICR[4:0])

#140

Address: 0FFDCCh

Interrupt level register (ICR62)

Address: 047Eh