K60学习NVIC

NVIC是K60的内核外设,类似于Systick。
一些总要的寄存器如下:

__IO uint32_t ISER[8];    /* Interrupt Set Enable Register           */
       uint32_t RESERVED0[24];
  __IO uint32_t ICER[8];  /*  Interrupt Clear Enable Register         */
       uint32_t RSERVED1[24];
  __IO uint32_t ISPR[8];  /*  Interrupt Set Pending Register          */
       uint32_t RESERVED2[24];
  __IO uint32_t ICPR[8];  /*  Interrupt Clear Pending Register        */
       uint32_t RESERVED3[24];
  __IO uint32_t IABR[8];   /*  Interrupt Active bit Register           */
       uint32_t RESERVED4[56];
  __IO uint8_t  IP[240];  /* Interrupt Priority Register (8Bit wide) */
       uint32_t RESERVED5[644];
  __O  uint32_t STIR; /*  Software Trigger Interrupt Register     */

各个寄存器的描述
中断向量号的查询在MK60D10.h中完成,NVIC的中断号是负数。
ISER 设置使能中断。
ICER 清除中断

你可能感兴趣的:(K60学习NVIC)