篮球计时计分系统
学生姓名: 学生学号:
院 (系): 电信学院 年级专业: 指导教师: 助理指导教师:
二〇一五年五月
摘要
摘 要
当今世界,喜欢篮球运动的人越来越多,篮球运动不仅能增强人们体质,还能增加人与人之间的友谊。篮球运动也是本着公平、公开、公正的原则而开展的,这是对每个运动员的尊重,也能提高人们参与比赛的积极性。篮球比赛通过比赛时间和分数来决定胜负,所以在篮球比赛中对时间和分数的准确记录与合理计算十分重要,因此,篮球计时计分系统的研究对于提高篮球比赛的质量至关重要。
此次设计是通过51单片机系统对篮球比赛的时间和分数进行记录和处理,利用数码管进行分数的显示和更新,通过设定一系列的按键对单片机传递控制信息,同时还加入蜂鸣器作为比赛开始结束的提醒工具。这套装备主要兼顾到成本与性能两大方面,单片机价格低廉、普及广、操作简单同时也具备着较高的稳定性和准确性,外围器件也都经过多次考虑计划后选取的。整个系统主要具备着生产成本低、材料广泛、操作简单、功能强大、稳定性好的特点,具有很大研究意义。
关键词 计时计分系统,51单片机,性能,设计
I
ABSTRACT
ABSTRACT
In today's world , more and more people like to play basketball . Basketball can not only enhance the people’s physique , but also increase the friendship between people . Basketball is also carried out in line with the principle of fairness , openness and justice . This is for each athlete’s respect , at the same timeimprove the enthusiasm of people to participate in the competitI/On . The basketball game by game time and scores to determine the outcome , so in the basketball match on time and accurately record the scores and reasonable calculatI/On is very important . Therefore , study on basketball timing and scoring system is very important to improve the quality of the game of basketball .
This design is recorded and processed the basketball game time and scores by 51 single chip microcomputer system, by using digital tube to display concentratI/On and update the scores.by setting a series of key control informatI/On tranfer to single chip microcomputer,at the same time as the start and end of a match with a buzzer reminder tool . This set of equipment is mainly to take into account the cost and performance aspects . Single chip is cheap , popularzatI/On , simple operatI/On , but also has a high accuracy and stability . Peripheral devices are also selected after several considered . The whole system has a low productI/On cost , wide range of materials , simple operatI/On , strong functI/On and good stability . This design has great significance .
Key words Timing scoring system , 51 single chip , performance , design
II
目录
目 录
摘 要 .............................................................................................................................................. I ABSTRACT ....................................................................................................................................... II 1 绪论 .......................................................................................................................................... 3
1.1 课题研究背景及意义....................................................................................................... 3
1.2 篮球计时计分系统的发展历史 ....................................................................................... 3 1.3 单片机的发展 ................................................................................................................... 4 1.4 单片机的应用 ................................................................................................................... 5 1.5 本课题的发展的趋势 ....................................................................................................... 5
2 方案论证与选择 .................................................................................................................... 7
2.1 系统设计方案 ................................................................................................................... 7 2.2 系统方案抉择 ................................................................................................................... 7 2.3 本设计主要特点 ............................................................................................................... 8
3 设计原理 ................................................................................................................................. 9
3.1 单片机控制原理 ............................................................................................................... 9
3.1.1 单片机储存器介绍 ............................................................................................... 9 3.1.2 单片机引脚介绍 ................................................................................................... 9 3.1.3 单片机计时原理 ................................................................................................. 10 3.2 数码管显示原理 ............................................................................................................. 11 3.3 按键控制原理 ................................................................................................................. 12 3.4 篮球比赛计分计时规则说明 ......................................................................................... 12
4 系统硬件设计 ...................................................................................................................... 14
4.1 系统整体设计 ................................................................................................................. 14 4.2 单片机最小系统 ............................................................................................................. 14 4.3 按键部分......................................................................................................................... 15 4.4 显示部分......................................................................................................................... 15 4.5 蜂鸣器............................................................................................................................. 15
5 系统软件设计 ...................................................................................................................... 17
5.1 实现数码管动态显示程序 ............................................................................................. 17 5.2 按键程序......................................................................................................................... 17 5.3 单片机复位程序 ............................................................................................................. 17 5.4 蜂鸣器程序 ..................................................................................................................... 18 5.5系统计时计分程序 .......................................................................................................... 18
6 系统仿真及安装调试 ........................................................................................................... 19 7 计时计分器改进的设想 .................................................................................................... 21 总结 ............................................................................................................................................... 22
1
目录
参 考 文 献 ............................................................................................................................... 23 附录A:C语言程序 .................................................................................................................. 25 附录B:proteus仿真图......................................................................................................... 33 附录C: 实物图 .......................................................................................................................... 34 附录D: PCB图 ........................................................................................................................... 36 致 谢 ........................................................................................................... 错误!未定义书签。
2