摘 要:随着数控机床技术的发展,如何对机床进行更加高效和精确的控制成为机床控制领域的重点研究方向,各种类型的控制器层出不穷。此次设计利用单片微型机、电机驱动芯片以及其他相应的硬件资源,通过将程序输入单片机,由单片机控制电机的正转、反转、停止,以此来实现对机床运动的精确控制。文中介绍了步进电机的结构和工作原理,步进电机和单片机在自动控制系统的设计中的应用。并根据单片机和步进电机的工作原理设计了系统的硬件电路和软件功能,设计完成后对软、硬件进行了调试。经过调试,硬件电路设计没有大的问题,但电机控制程序在调试时无法使电机反转。通过仿真发现,该设计能够达到要求的功能。38923 毕业论文关键词:步进电机;脉宽调制技术;驱动系统;单片机
The System for Motion Control of Machine Based on Microcontroller
Abstract: With the development of nc machine tool technology, how to more efficient and precise control the machine has become one of key research direction in the field of machine tool control, various types of controllers emerge in endlessly. This design using the single chip micro computer, motor driver chips, and other corresponding hardware resources, through the input program to MCU, the forward and reverse by single chip microcomputer control motor, acceleration, deceleration and stop, in order to realize the precise control of the machine tool movement. This paper introduces the structure and working principle of stepper motor, step motor and single chip microcomputer application in the design of the automatic control system. And according to the working principle of single chip microcomputer and stepping motor design the hardware circuit and software of the system function, after the completion of the design of hardware and software debugging, actively explore possible problems and also give their views on how to solve the problem. Through simulation, the design can meet the requirements of function.
Key Words: Stepper motor; PWM (Pulse Width Modulation); Drive mechanism system; SCM
目 录
摘 要 1
1. 绪论 2
1.1 课题研究的目的和意义 2
1.2 国内外研究概况 3
1.3 论文的主要研究内容 3
2. 步进电机与单片机简介 3
2.1 步进电机简介 3
2.2 步进电机的工作原理 4
2.3 步进电机分类与选择 5
2.4 步进电机驱动系统介绍 6
2.5 单片机简介 9
3. 系统硬件设计 11
3.1 系统硬件总体结构图 11
3.2 电源电路 11
3.3 按键电路 12
3.4 驱动电路 13
3.5 电机状态指示电路 13
3.6 时钟电路 14
4. 系统软件设计 15
4.1 系统主程序 15
4.2 查键功能的实现 15
4.3 电机正转功能的实现 16