• Up to eight keyboard interrupt pins with individual pin enable bits
有八个KBI中断源,就是上面D系引脚的那8个
(二)KBI中断的寄存器
KBI有三个寄存器:
• A pin status and control register, KBIx_SC
• A pin enable register, KBIx_PE
• An edge select register, KBIx_ES
SC:状态寄存器
PE:使能寄存器
ES:边缘触发寄存器
(三)初始化配置
11.5.4节提到:
1. Mask keyboard interrupts by clearing KBIx_SC[KBIE].
2. Enable the KBI polarity by setting the appropriate KBIx_ES[KBEDGn] bits.
3. Before using internal pullup resistors, configure the associated bits in PORT_PTxPE.
4. Enable the KBI pins by setting the appropriate KBIx_PE[KBIPEn] bits.
5. Write to KBIx_SC[KBACK] to clear any false interrupts.
6. Set KBIx_SC[KBIE] to enable interrupts.