Rev. 1.00
64
March 24, 2020
Rev. 1.00
65
March 24, 2020
BS83A04C
4-Key Enhanced Touch I/O Flash MCU
BS83A04C
4-Key Enhanced Touch I/O Flash MCU
Touch Key Function
The device provides multiple touch key functions. The touch key function is fully integrated and
requires no external components, allowing touch key functions to be implemented by the simple
manipulation of internal registers.
Touch Key Structure
The touch keys are pin shared with the I/O pins, with the desired function chosen via the pin-shared
selection register bit. Keys are organised into one group, known as a module. The module is a fully
independent set of four Touch Keys and has its own oscillator. The module contains its own control
logic circuits and register set.
Total Key Number
Touch Key
Shared I/O Pin
4
KEY1~KEY4
PA5, PA1, PA3, PA4
Touch Key Structure
Touch Key Register Definition
The touch key module 0, which contains four touch key functions, is controlled using several
registers. The following table shows the register set for the touch key module 0.
Register Name
Description
TKTMR
Touch key time slot 8-bit counter preload register
TKC0
Touch key function control register 0
TKC1
Touch key function control register 1
TKC2
Touch key function control register 2
TK16DL
Touch key function 16-bit counter low byte
TK16DH
Touch key function 16-bit counter high byte
TKM016DL
Touch key module 0 16-bit C/F counter low byte
TKM016DH
Touch key module 0 16-bit C/F counter high byte
TKM0ROL
Touch key module 0 reference oscillator capacitor selection low byte
TKM0ROH
Touch key module 0 reference oscillator capacitor selection high byte
TKM0C0
Touch key module 0 control register 0
TKM0C1
Touch key module 0 control register 1
TKM0C2
Touch key module 0 control register 2
TKM0TH16L
Touch key module 0 16-bit threshold low byte
TKM0TH16H
Touch key module 0 16-bit threshold high byte
TKM0THS
Touch key module 0 threshold comparison flag
Touch Key Function Register Definition
Register
Name
Bit
7
6
5
4
3
2
1
0
TKTMR
D7
D6
D5
D4
D3
D2
D1
D0
TKC0
TKRAMC
TKRCOV
TKST
TKCFOV
TK16OV
TKMOD1
TKMOD0
TKBUSY
TKC1
D7
D6
D5
—
TK16S1
TK16S0
TKFS1
TKFS0
TKC2
—
—
—
—
—
TSC
ASMP1
ASMP0
TK16DL
D7
D6
D5
D4
D3
D2
D1
D0
TK16DH
D15
D14
D13
D12
D11
D10
D9
D8
TKM016DL
D7
D6
D5
D4
D3
D2
D1
D0
TKM016DH
D15
D14
D13
D12
D11
D10
D9
D8
TKM0ROL
D7
D6
D5
D4
D3
D2
D1
D0
TKM0ROH
—
—
—
—
—
—
D9
D8