Compact Type Tm - Ctm; Compact Tm Ope�Ation; Compact T�Pe Tm Registe� Desc�Iption - Holtek BS83B24C Manual

Touch flash mcu
Table of Contents

Advertisement

BS83B24C/BS83C40C
Touch Flash MCU
Compact Type TM – CTM
Although the simplest form of the three TM types, the Compact TM type still contains three
operating modes, which are Compare Match Output, Timer/Event Counter and PWM Output modes.
The Compact Type TM can also be controlled with an external input pin and can drive two external
output pins.
f
/4
000
SYS
f
001
SYS
f
/16
010
H
f
/64
011
H
10-�it Co�nt-�p Co�nte�
f
100
SUB
f
101
SUB
CTON
110
CTPAU
CTCK
111
CTCK�~CTCK0
Note: The CTPB is the inverted output of the CTP pin.
Compact TM Operation
At its core is a 10-bit count-up counter which is driven by a user selectable internal or external clock
source. There are also two internal comparators with the names, Comparator A and Comparator
P. These comparators will compare the value in the counter with CCRP and CCRA registers. The
CCRP is three bits wide whose value is compared with the highest three bits in the counter while the
CCRA is the ten bits and therefore compares with all counter bits.
The only way of changing the value of the 10-bit counter using the application program, is to
clear the counter by changing the CTON bit from low to high. The counter will also be cleared
automatically by a counter overflow or a compare match with one of its associated comparators.
When these conditions occur, a CTM interrupt signal will also usually be generated. The Compact
Type TM can operate in a number of different operational modes, can be driven by different clock
sources including an input pin and can also control two output pins. All operating setup conditions
are selected using relevant internal registers.
Compact Type TM Register Description
Overall operation of the Compact Type TM is controlled using several registers. A read only register
pair exists to store the internal counter 10-bit value, while a read/write register pair exists to store
the internal 10-bit CCRA value. The remaining two registers are control registers which setup the
different operating and control modes as well as the three CCRP bits.
Register
Name
7
CTMC0
CTPAU
CTMC1
CTM1
CTMDL
D�
CTMDH
CTMAL
D�
CTMAH
Rev. 1.00
CCRP
Compa�ato� P Match
3-�it Compa�ato� P
��~�9
Co�nte� Clea�
CTCCLR
�0~�9
Compa�ato� A Match
10-�it Compa�ato� A
CCRA
10-bit Compact Type TM Block Diagram
6
5
CTCK�
CTCK1
CTCK0
CTM0
CTIO1
CTIO0
D6
D5
D6
D5
10-bit Compact Type TM Register List
�9
CTMP� Inte���pt
CTOC
O�tp�t
Pola�it�
0
1
Cont�ol
Cont�ol
CTM1~CTM0
CTPOL
CTIO1~CTIO0
CTMA� Inte���pt
Bit
4
3
2
CTON
CTRP�
CTOC
CTPOL
D4
D3
D�
D4
D3
D�
CTP
Pin Cont�ol
CTPB
PxSn
1
0
CTRP1
CTRP0
CTDPX
CTCCLR
D1
D0
D9
D�
D1
D0
D9
D�
�e���a�� 0�� �01�

Advertisement

Table of Contents
loading
Need help?

Need help?

Do you have a question about the BS83B24C and is the answer not in the manual?

Subscribe to Our Youtube Channel

This manual is also suitable for:

Bs83c40c

Table of Contents