基于鼠标的随动系统设计摘 要单片机现在的应范围越来越广泛,单片机能够使用的液晶显示器也是越来越多。我们在单片机系统中引入鼠标,通过单片机将鼠标移动行程的二位编码进行采集和显示,然后通过单片机的输出控制步进电机的位置移动,形成一个位置随动系统。位置随动系统又称伺服系统,主要用于解决位置跟随的控制问题。 该课题要讨论的是对鼠标的二维编码用单片机采集并显示出来,同时发送给两个步进电机驱动器使之移动,完成 X-Y 坐标的随动定位。该设计的优点是首先基于单片机的应用系统,具有体积小、重量轻、性价比高以及可靠性较高;然后在单片机系统中引入鼠标可以提高工作效率,方便用户;最后将可编程控制的单片机应用于步进电机随动系统,可使其具有较大程度的可改变性。关键词:PS2 鼠标接口 1602 显示 步进电机驱动 8051 单片机ABSTRACT The first SCM was invented in 1980th,after that ,the SCM is gradual widely used in many places,such as the aircraft instrumentation,the time control and data processing of industrial automation system,camera,robot,integrated circuit and so on. The main content of this paper is that we link the PS2 mouse and the SCM together,so that the 1602LCD can show the place and button states on the screen,and then pass the number of the x,y coordinate to the drive of the step motor,the step motor will move and stop in the place you want.Keywords:the interface of PS2mouse and SCM,1602LCD,the drive of step motor目 录第 一 章 绪 论 .........................................................1 1.1 课题讨论的目的和意义 .........................................1 1.1.1 单片机系统设计背景 ........................................1 1.1.2 单片机的基本知识 ..........................................1 1.2 MCS-51 系 列 单 片 机 介 绍 .........................................2 1.2.1 基本特性 ..................................................2 1.2.2 MCS-51 单片机的硬件组成结构................................2 1.2.3 MCS-51 的引脚功能..........................................