完善资料让更多小伙伴认识你,还能领取20积分哦, 立即完善>
电子发烧友论坛|
在5509A的中断实验例程中,采用的是硬件中断
其程序为 /* This is an example for EMIF of C5509 */ /*----------------------------------------------------------------------------*/ #include #include #include #include #include #include CSLBool b; Uint16 eventid0; int old_intm; interrupt void int1(void); //---------Function prototypes--------- /* Reference start of interrupt vector table */ /* This symbol is defined in file, vectors_IP.s55 */ extern void VECSTART(void); /*锁相环的设置*/ PLL_Config myConfig = [ 0, //IAI: the PLL locks using the same process that was underway //before the idle mode was entered 1, //IOB: If the PLL indicates a break in the phase lock, //it switches to its bypass mode and restarts the PLL phase-locking //sequence 12, //PLL multiply value; multiply 12 times 1 //Divide by 2 PLL divide value; it can be either PLL divide value //(when PLL is enabled), or Bypass-mode divide value //(PLL in bypass mode, if PLL multiply value is set to 1) ]; /***************5509A中断设置,使能INT1中断***********************/ /*参考资料: TMS320C55x Chip Support Library API Reference Guide (Rev. J) TMS320VC5509A Data Sheet */ void INTconfig() [ /* Temporarily disable all maskable interrupts */ IRQ_setVecs((Uint32)(&VECSTART)); /* Temporarily disable all maskable interrupts */ old_intm = IRQ_globalDisable(); /* Get Event Id associated with External INT0(8019), for use with */ eventId0 = IRQ_EVT_INT0; /* Clear any pending INT0 interrupts */ IRQ_clear(eventId0); /* Place interrupt service routine address at */ /* associated vector location */ IRQ_plug(eventId0,&int1); /* Enable INT0(8019) interrupt */ IRQ_enable(eventId0); /* Enable all maskable interrupts */ IRQ_globalEnable(); ] main() [ /*初始化CSL库*/ CSL_init(); /*EMIF为全EMIF接口*/ CHIP_RSET(XBSR,0x0a01); /*设置系统的运行速度为144MHz*/ PLL_config(&myConfig); //设置并使能5509A芯片的INT0中断(EXINT中断) INTconfig(); while(1); ] //External INT0(EXINT)中断处理函数 interrupt void int1() [ printf("EXINT ouccersn"); ] /****************************************************************************** * End of pll2.c ******************************************************************************/ 在开发板上,按下EXINT键,表明有一个硬件中断发生,并且EXINT与INT0引脚也没有连接,那程序中为什么采用的是INT0中断,它与EXINT中断有何关系? |
|
相关推荐
6 个讨论
|
|
只有小组成员才能发言,加入小组>>
545 浏览 0 评论
1609 浏览 0 评论
2045 浏览 0 评论
为啥BQ7693003DBTR芯片在和BQ769X0盒子通讯时收不到信号?
1507 浏览 0 评论
DSP 28027F 开发板 XDS100v2调试探针诊断日志显示了 Error -150 (SC_ERR_FTDI_FAIL)如何解决
1331 浏览 0 评论
AT32F407在USART2 DMA发送数据时,接包接到了要发送的数据,程序还是处于等待传输完成的标识判断中,为什么?
1756浏览 29评论
2781浏览 23评论
请问下tpa3220实际测试引脚功能和官方资料不符,哪位大佬可以帮忙解答下
1723浏览 20评论
请教下关于TAS5825PEVM评估模块原理图中不太明白的地方,寻求答疑
1634浏览 14评论
两个TMP117传感器一个可以正常读取温度值,一个读取的值一直是0,为什么?
1645浏览 13评论
/9
小黑屋| 手机版| Archiver| 电子发烧友 ( 湘ICP备2023018690号 )
GMT+8, 2025-12-1 18:36 , Processed in 1.057250 second(s), Total 54, Slave 44 queries .
Powered by 电子发烧友网
© 2015 bbs.elecfans.com
关注我们的微信
下载发烧友APP
电子发烧友观察
版权所有 © 湖南华秋数字科技有限公司
电子发烧友 (电路图) 湘公网安备 43011202000918 号 电信与信息服务业务经营许可证:合字B2-20210191

淘帖
2017