rej05b0620_m16cap| Application Note

rej05b0620_m16cap PDF

rej05b0620_m16cap| Application Note


APPLICATION NOTE

M16C/Tiny Series
Operation of Timer B (Event Counter Mode)
1. Abstract

In event counter mode, choose functions from those listed in Table 1. Operations of the checked items are described below. Table 1. Choosed Functions
Item Count source Yes Set-up Input signal to TBiIN (counting falling edges) Input signal to TBiIN (counting rising edges) Input signal to TBiIN (counting rising and falling edges) Timer overflow (TB2 overflow /TBj overflow) Note: j = i 1, but j = 2 when i = 0.

2.

Introduction

The explanation of this issue is applied to the following condition: Applicable MCU: M16C/26, M16C/26A, M16C/28, M16C/29 Group This program can also be used when operating other microcomputers within the M16C family, provided they have the same SFR (Special Function Registers) as the M16C/26, M16C/26A, M16C/28, M16C/29 microcomputers. However, some functions may have been modified. Refer to the User's Manual for details. Use functions covered in this Application Note only after careful evaluation.

3.
(1) (2) (3)

Operation of Timer A
Setting the count start flag to "1" causes the counter to count the falling edges of the TBiIN. If an underflow occurs, the content of the reload register is reloaded, and the count continues. At this time, the timer Bi interrupt request bit goes to "1". Setting the count start flag to "0" causes the counter to hold its value and to stop.

Figure 1 shows the operation timing of event counter mode.

REJ05B0620-0100/Rev.1.00

May 2005

Page 1 of 7


rej05b0620_m16cap Application Note renesas Download PDF

Add this permalink to your bookmarks for future download of rej05b0620_m16cap ApplicationNote

Permalink: http://application.emcelettronica.com/renesas/rej05b0620_m16cap

PDF rej05b0620_m16cap APPLICATION NOTE