文件名称:include
- 所属分类:
- 单片机(51,AVR,MSP430等)
- 资源属性:
- [WORD]
- 上传时间:
- 2014-07-10
- 文件大小:
- 3kb
- 下载次数:
- 0次
- 提 供 者:
- 杨**
- 相关连接:
- 无
- 下载说明:
- 别用迅雷下载,失败请重下,重下不扣分!
介绍说明--下载内容均来自于网络,请自行研究使用
1)设置3个变量,假如A,B,C,其中A在主程序里循环计数,计数间隔为1秒左右(不需要很精确),从0-9循环计数;B在外部中断0程序中计数,计数间隔为1秒左右(不需要很精确),从0计数到9,中断退出;C在外部中断2程序中计数,计数间隔为1秒左右(不需要很精确),从0计数到9,中断退出;外部中断0,1采用下降沿触发,通过按键触发。为了便于观察,P1连接到数码管,P2.0-P2.2对应A,B,C计数选通,每计数一次,将变量输出到数码管上,即在主程序里显示数码管4,在中断0里显示数码管5,在中断1里显示数码管6。设置外部中断0为高级中断,外部中断1为低级中断。改变按键顺序观察LED显示。-1) Set three variables, if A, B, C, where A in the main program loop count, the count interval of 1 second or so (need not be very precise), cycle count from 0-9 B program in the external interrupt 0 counting, counting interval is 1 second or so (need not be very precise), counts from 0 to 9, interrupt exit C program in the external interrupt 2 count, the count interval is 1 second or so (need not be very precise), counts from 0 to 9, interrupt exit 0,1 using falling edge triggered external interrupt, triggered by the button. In order to facilitate the observation, P1 is connected to the digital control, P2.0-P2.2 corresponds to A, B, C count strobe, each counted once, the variable output to digital, is displayed in the main program of digital tube 4, Interrupt 0 5 in the digital display, digital display interrupt an inside tube 6. Set External Interrupt 0 is a senior interrupt, external interrupt 1 is lower interrupt. LED display keys change the order observed.
(系统自动生成,下载前可以参看下载内容)
下载文件列表
include.doc