没有合适的资源?快使用搜索试试~ 我知道了~
资源推荐
资源详情
资源评论
题 目:基于串口通信的步进电机
调速系统设计
内蒙古科技大学毕业设计说明书(毕业论文)
I
基于串口通信的步进电机调速系统设计
摘 要
本设计方案中采用基于串口通信的 AT89C51 型单片机内部的定时器改变 CP 脉冲的
频率从而实现对步进电机的转速进行控制,实现电机调速与正反转的功能。
在实验室和工业应用中,串口是计算机与外部串行设备之间的数据传输通道,由于
串行通信方便易行,所以应用广泛。
在 VC++6.0 的环境下,编写使用 C 语言,串口通信程序,由单片机控制的步进电
动机的转速。当由单片机控制的步进电动机的转速的工作数据由串口传到计算机时,操
作人员能够实时监控其工作状态,工作数据,根据情况,并能更改其工作参数。这样,
就使得控制步进电机的转速。而电机的转速取决于脉冲信号的频率和脉冲数,而不受负
载变化的影响,即给电机加一个脉冲信号,电机则转过一个步距角,所以步进电机每给
一个脉冲就转动一个固定的角度,这样就可以通过控制步进电机的一个脉冲到下一个脉
冲的时间间隔来改变脉冲的频率,延时的长短来具体控制步进角来改变电机的转速,从
而实现步进电机的调速。
关键词:步进电机调速;单片机;串口通信;VC++
内蒙古科技大学毕业设计说明书(毕业论文)
II
The stepper motor speed control system based on
serial communication
Abstract
The design of serial communication based on AT89C51 single-chip microcomputer-based
timer to change the internal pulse frequency of CP in order to achieve the speed of stepper
motor control with the positive realization of motor function.
In the laboratory and industry field, the computer serial port and external serial device
data transmission between the channels, as a result of user-friendly serial communication lines,
so a wide range of applications.
In VC + +6.0 environment, prepared using the C language, serial communication
procedures by the single-chip microcomputer to control the speed of the stepper motor.
When controlled by the single-chip stepper motor speed the work of the serial data
transmitted by the computer, the operator can work in real-time monitoring of its status, the
work of data, depending on the circumstances and can change its operating parameters. This
allows control of stepper motor speed. Depends on the speed of the electrical pulse frequency
and pulse number, and not subject to the impact of changes in load, that is, to add an electrical
pulse signal, a step motor is turned away from the angle, the stepper motor is a pulse on each
rotation of a fixed point of view so that you can control the stepper motor through a pulse to
pulse the next time interval to change the pulse frequency, the length of delay to a specific
angle in order to change control of stepper motor speed, the stepper motor in order to achieve
Speed.
Keywords: Stepper motor; Singlechip; Serial communication; Visual C++
内蒙古科技大学毕业设计说明书(毕业论文)
III
目 录
摘 要 .........................................................................................................................................I
Abstract ......................................................................................................................................II
目 录.......................................................................................................................................III
第一章 概述...............................................................................................................................1
1.1 开发背景及发展趋势..................................................................................................1
1.2 功能要求及功能实现概述..........................................................................................2
第二章 系统结构的实现与步进电机的驱动...........................................................................3
2.1 整体硬件结构...............................................................................................................3
2.2 系统硬件电路设计.......................................................................................................3
2.2.1 硬件的基本组成................................................................................................3
2.2.2 电路图................................................................................................................3
2.2.2.1 晶振电路.................................................................................................4
2.2.2.2 光电隔离器.............................................................................................5
2.2.2.3 MAX232 的介绍 ....................................................................................6
2.2.3 PCB 板的生成...................................................................................................6
2.3 步进电机的结构特点...................................................................................................7
2.3.1 反应式步进电机的结构....................................................................................7
2.3.2 反应式步进电机的工作原理...........................................................................8
2.3.3 反应式步进电机的步进方式...........................................................................9
2.3.4 步进电动机的主要性能指标.........................................................................10
2.3.5 步进电动机的运行特性..................................................................................11
2.3.6 步进电机的选型..............................................................................................13
2.4 步进电机驱动电路.....................................................................................................14
2.4.1 单电压驱动......................................................................................................14
2.4.2 双电压驱动.....................................................................................................15
2.4.3 斩波驱动.........................................................................................................16
2.4.4 细分驱动.........................................................................................................17
2.4.5 集成电路驱动.................................................................................................17
内蒙古科技大学毕业设计说明书(毕业论文)
IV
2.5 基于单片机的步进电机调速....................................................................................18
2.5.1 AT89C51 单片机简介.....................................................................................18
2.5.2 步进电机调速..................................................................................................22
2.5.2.1 步进电机的正反转...............................................................................23
2.5.2.2 步进电机的加减速...............................................................................25
第三章 GUI 设计 ....................................................................................................................26
3.1Visual C++..................................................................................................................26
3.2 步进电机速度控制界面设计.....................................................................................27
第四章 通信模式.....................................................................................................................31
4.1 基本原理.....................................................................................................................31
4.2 单片机的串行通信.....................................................................................................31
4.2.1 串口接收数据..................................................................................................34
4.2.2 通信协议..........................................................................................................36
第五章 结束语.........................................................................................................................37
附录 A.......................................................................................................................................39
附录 B.......................................................................................................................................40
附录 C.......................................................................................................................................41
剩余49页未读,继续阅读
资源评论
Mmnnnbb123
- 粉丝: 751
- 资源: 8万+
上传资源 快速赚钱
- 我的内容管理 展开
- 我的资源 快来上传第一个资源
- 我的收益 登录查看自己的收益
- 我的积分 登录查看自己的积分
- 我的C币 登录后查看C币余额
- 我的收藏
- 我的下载
- 下载帮助
安全验证
文档复制为VIP权益,开通VIP直接复制
信息提交成功