文档详情

基于VC++的伺服电机速度控制系统设计_毕业论文.doc

发布:2019-02-17约5.01万字共70页下载文档
文本预览下载声明
基于VC++的伺服电机速度控制系统设计 摘 要 本设计完成是基于Visual C++6.0软件下实现伺服电机控制界面的编程,并完成PID控制算法。该控制界面不仅简洁实用,而且具有良好的人机交流部分。 上位机控制界面所实现的功能有电机的启动、停止、正传、反转、速度给定、实时曲线显示等,在完成PID算法后同时下发PID调节后的PWM占空比,实现转速控制。在完成串口通讯编程本文采用MSComm控件实现PC机与单片机通讯,数据的发送与接收采用统一通讯协议,这种方法不仅简单,而且实用。本文采用单片机作为下位机来验证上位机控制功能的实现,单片机作为下位机主要负责直流电机的各种参数数据的采集和模数转换,然后通过串行端口把数据发送给上位机,PC机作为上位机主要负责数据的分析处理和显示。 关键词:伺服电机;VC++;串口通讯;PWM调速;PID; The servo motor speed control system design Based on VC++ Abstract This designs core is under the software of Visual C++6.0, realizes the servo motor control contact surface programming, and completes the PID control algorithm. This control interface has not only succinct practical, but also has the good man-machine exchange part. The superior machine control interface realizes the function has the electrical machinerys start, electrical machinerys stop, electrical machinerys main story, electrical machinerys reverse, the speed value assigns, Curve demonstration and so on. After completing the PID algorithm simultaneously after-crops PID the adjustment the PWM current output.In completing serial port communication programming this article to use MSComm to control to realize PC machine and the monolithic integrated circuit communication, the data transmission and the receive uses the unified communication protocol, in this method is not only simple but also practical. In this article uses the monolithic integrated circuit to confirm the superior machine control function as the lower position machine realization, Monolithic integrated circuit as lower position machine primary cognizance direct current machines each kind of parameter data gathering and with A/D conversion. Then through the serial port the data transmission for the superior machine, PC machine takes the superior machine primary cognizance data the analysis processing and the demonstration. Key word: Servo electrical machinery; VC++; Serial port communication; PWM control speed; PID; 目 录 TOC \o 1-3 \h \z \u HYPERLINK \l _Toc2330
显示全部
相似文档