1、 本 科 毕 业 设本 科 毕 业 设 计(计(论论 文)文) 题目题目 基于单片机的步进电机控制及基于单片机的步进电机控制及 驱动系统设计驱动系统设计 学生姓名学生姓名 学学 号号 教学院系教学院系 电气信息学院电气信息学院 专业年级专业年级 电气工程及其自动化电气工程及其自动化 20092009 级级 指导教师指导教师 职职 称称 单单 位位 辅导教师辅导教师 职职 称称 单单 位位 完成日期完成日期 20132013 年年 0 06 6 月月 0 06 6 日日 2 Southwest Petroleum University Graduation Thesis Control of s
2、tepping motor based on single chip and system design Grade: 2009 Name: Speciality: Instructor: I 摘摘 要要 步进电机是数字控制系统中的一种执行元件,它能按照控制脉冲的要求,迅速 起动,制动,正反转和调速。具有步距角精度高,停止时能自锁等特点,因此步进 电机在自动控制系统中,特别是在开环的控制系统中得到了日益广泛的应用。 本文以单片机为核心设计的步进电机控制系统,通过软硬件的设计调试,实现 步进电机加、减速控制,正反转控制、步数控制,系统以最短的时间到达控制终点, 而又不发生失步的现象;硬件是以 A
3、T89C52 单片机为核心的控制电路,主要包括: 键盘电路、步进电机的驱动电路等。本文用 Keil 软件编写 C 语言程序,与汇编语 言相比,C 语言在功能上、结构上、可维护性上有明显的优势。Keil 提供了包括 C 编译器、宏汇编、连接器、库管理和功能强大的仿真调试器在内的完整开发方案, 通一个集成开发环境将这些部分组合在一起。并用 Proteus 软件仿真单片机及外围 器件。 关键词关键词:步进电机控制系统;调速;单片机 II AbstractAbstract Stepping motor is a kind of digital control system components. It
4、 can achieve quick start-up, positive inversion, stopping and speed control, according to the control pulse. It has high precision step angle, and can be self-locking when it keeps still. As these characteristics, stepping motor in automatic control system, especially in the open loop control system
5、 has been widely applied. This article mainly focuses on taking Single-chip Computer and cycle pulse distributor as the core, and designing the stepping motor control system. Through the design of the software and hardware debugging, it realizes controlling the step motors acceleration and decelerat
6、ion automatically, according to parameter setting. Making the system arrive the end point with the shortest time, but not occur outing of step. Besides it can accurately achieve start-up, positive inversion and shutdown. Hardware takes AT89C52 as the core of control circuit, mainly including: cycle pulse distributor, keyboard and display circuit, stepping motor driving circuit, etc. This software is written using Keil with C language program . Compared with assembly language , C