|
1、WP_000206-208.jpg为效果图
2、GIOINTERRUPT内包含GIOINTERRUPT.hcg(HCG)和CCS工程文件,
3、对于主函数中语句解释为
void main(void)
{
/* USER CODE BEGIN (3) */
gioInit();//初始化GIO
_enable_interrupts();//开全局中断
gioSetDirection(hetPORT1,0xFFFFFFFF);//设置HET作为io的输出方向,即点亮板子上的led灯
//gioEnableNotification(gioPORTB,7);//使能GIO每个引脚的中断
gioEnableNotification(gioPORTB,6);
gioEnableNotification(gioPORTB,5);
gioEnableNotification(gioPORTB,4);
gioEnableNotification(gioPORTB,0);
gioEnableNotification(gioPORTB,2);
gioEnableNotification(gioPORTB,1);
//gioNotification(gioPORTA,1);
while(1);
/* USER CODE END */
}
4、void gioNotification(gioPORT_t *port, sint32 bit)为中断处理函数
|
|