NUC970 Technical Reference Manual
Publication Release Date: Dec. 15, 2015
- 1238 -
Revision V1.30
NUC97
0
T
E
CHNIC
A
L
RE
F
E
RE
N
CE
MA
NUA
L
[20]
Reserved
Reserved.
[19:16]
DBCLKSEL
Scan in De-bounce Sampling Cycle Selection
0000 = Sample interrupt input once per 1 clocks.
0001 = Sample interrupt input once per 2 clocks.
0010 = Sample interrupt input once per 4 clocks.
0011 = Sample interrupt input once per 8 clocks.
0100 = Sample interrupt input once per 16 clocks.
0101 = Sample interrupt input once per 32 clocks.
0110 = Sample interrupt input once per 64 clocks.
0111 = Sample interrupt input once per 128 clocks.
1000 = Sample interrupt input once per 256 clocks.
1001 = Sample interrupt input once per 2*256 clocks.
1010 = Sample interrupt input once per 4*256 clocks.
1011 = Sample interrupt input once per 8*256 clocks.
1100 = Sample interrupt input once per 16*256 clocks.
1101 = Sample interrupt input once per 32*256 clocks.
1110 = Reserved.
1111 = Reserved.
Note:
row scan time > 2 * debounce sampling cycle.
row scan time = prescale * 32 (xclock).
xCLOCK = 1MHz ~32KHz.
bouncing time last for 1ms, for example,if xCLOCK = 1MHz.
debounce sampling cycle should choose 1024 xclock .
row scan time should chose 2048 xCLOCK,suppose PrescaleDivider = 0x1F,then.
prescale =2048/32 = 64.
[15:8]
PRESCALE
Row Scan Cycle Pre-scale Value
This value is used to pre-scale row scan cycle.
The pre-scale counter is clocked by the divided crystal clock, xCLOCK.
The PRESCALE (KPICONF[15:8]) value is from 1 to 256.
Eg.If the crystal clock is 1Mhz then the xCLOCK period is 1us.
If the keypad matric is 3x3 then each row scan time = xCLOCK x PRESCALE x
PrescaleDivider.
Key array scan time = Each row scan time x ROWS.
Example scan time for PRESCALE = 0x41,and PrescaleDivider = 0x1F.
Each row scan time = 1us x 65 x 32 = 2.08ms.
Scan time = 2.08 x 3 = 6.24ms.
Notes:
When PRESCALE (KPICONF[15:8]) is determined, De-bounce sampling cycle should
not exceed the half of (PRESCALE x PrescaleDivider ),in the above example maximum
DBCLKSEL (KPICONF[19:16]) should be 4*256 xCLOCK ,bouncing time is 1ms
[7:6]
Reserved
Reserved.
[5]
WAKEUP
Lower Power Wakeup Enable
Setting this bit enables low power wakeup.
0 = Not enable.
1 = Wakeup enable.