微机原理课程设计报告
电子与控制工程学院
计算机原理与接口技术
课 程 设 计
姓 名 高强强 学 号 3206100232 专 业 建筑设施智能技术 设计题目 可任意启动停止的电子秒表 指导老师 傅攀峰
目录
微机原理课程设计报告
1电子秒表课程设计要求·············································1 2关键字································································1 3摘要···································································1 4综合实验目的························································1 5引言···································································1
5.1.1使用各个芯片的作用及工作原理···································2 5.1.2 8253可编程外围芯片介绍··········································3 5.1.3锁存器74ls273·····················································4 5.1.4译码器74154························································7 5.1.5七段数码管显示······················································8
6程序流程图····························································10 7程序源程序····························································11 8程序及硬件调试图····················································15 9设计心得·······························································17 10参考文献····························································18
可任意启动/停止的电子秒表
一、电子秒表课程设计要求
6位LED数码显示,计时单位为1/100秒。利用功能键进行启/停控制。其功能为:上电后计时器清0,当第一次(或奇数次)按下启/停键时开始计数。第2次(或偶数次)按下该键时停止计时,再一次按启/停键时清零后重新开始计时。
二、关键字
8086 8255 8253 控制字 三、摘要
用汇编语言设计数字秒表,用PROTUES仿真软件搭建的硬件电路上正确显示,并且
具有开始停止清零功能。用8086作为处理器,8253做定时功能产生0.01S的脉冲,8255具备锁存和并行输出功能,驱动7段数码管正确显示,并且具有足够高的精度。。
微机原理课程设计报告
四、综合实验目的:
通常,学习知识是由浅入深、由此及彼,一点点的学习和积累的,而应用知识则
是综合运用所积累的知识来分析和解决实际问题、从知识的系统性来检验对各层次知识的掌握程度。
综合实验的目的是让学生把理论学习和实验教学阶段所掌握的知识通过一个设计实例,经历一次理论和实践结合、软件和硬件结合的综合训练,也是一次工程实践能力的检验。这次综合实验大家应当把它作为毕业设计的预演。 锻炼通过各种媒体和途径主动获取知识的能力。
五、引言
使用8253的通道0 工作在方式0计数,,并选用二进制技术,控制字36H,计数初值500,对1MHZ的CLK计数产生2000HZ的输出脉冲给1,2通道的CLK,通道一选用二进制计数即计数结束中断方式0,初值20产生非屏蔽中断0.01S非屏蔽中断送给8086的NMI产生中断的脉冲,8086开始计数即毫秒位计数并显示,并与10比较,等于给分秒位加一, 毫秒位置清零,分秒位与6比较若相等清零秒各位加一,秒个位与10比较若等于清零秒十位加一,秒十位与6比较若等于清零分个位加1,分个位与10比较若等于清零分十位加一,分十位与6比较若等于全部清零。
1、使用各芯片的作用及工作原理 1)定时器/计数器8253
用系统8253定时器提供的1MHZ定时单位,设计秒表定时程序。
有关系统定时方法:PC机系统中的8253定时器0工作于方式3,外部提供一个时钟作为CLK信号, 频率:f=1MHz。
定时器0输出方波的频率:2000 Hz。
定时器1输出方波100HZ,输出方波周期Tout=1/100=1ms。8253A每隔1ms引起一次中断,作为定时信号。可用1ms作基本计时单位。 253的引脚图及硬件连接图如下图示: