Transcription

1 IJSRD - International Journal for Scientific Research & Development Vol. 3, Issue 06, 2015 ISSN (online): Speed and Position Control of Stepper Motor using 8051 Microcontroller Amit Kumar 1 Ramjee Prasad Gupta 2 1 PG Scholar 2 Assistant Professor 1,2 Department of Electrical Engineering 1,2 BIT Sindri, Jharkhand, India Abstract Speed control of machine is the most vital and important part in any industrial organization. This research work focuses on speed and position control of stepper motor using 8051 microcontroller. The speed of stepper motor has been controlled by the delay between consecutive pulses of stepper motor phases provided by microcontroller. Actually speed is inversely proportional to delay between pulses of consecutive phases and Position of stepper motor has been controlled by the number of revolutions. In this project work step angle of 15 degree per step has been taken when motor is moving in clockwise direction and 7.5 degree per step when moving in anticlockwise direction. The direction of movement of stepper motor depends on opening and closing of switch. When switch is closed, motor moves in clockwise direction and when switch is opened, motor moves in anticlockwise direction. Furthermore, variable resistor connected to pin no. 6 of ADC has been varied in clockwise direction due to which speed increases and when varied in anticlockwise direction speed decreases. In this project work infrared sensor has been used to detect speed of stepper motor in rpm. Speed in rpm & step angle in degree has been displayed on LCD screen and output pulses can be observed on CRO. The control program has been written in assembly language and Kiel compiler has been used to convert this control program into executable file or in a HEX code. This hex code has been burnt into microcontroller by Flash Magic software. Key words: P89C51RD2 Microcontroller, Darlington pair driver for stepper motor, ADC0804, LCD, LED, Switch I. INTRODUCTION Stepper motors with microcontrollers are used in numerous applications where there is need of controlling the motion. This is due to robust structure of stepper motor, absence of brushes and better control capability when they are used with microcontrollers. These motors have excellent response to starting, stopping and reversing. The microcontroller is used for sending pulses to the stepper motor drive. Since microcontroller is not able to provide sufficient current to drive stepper motor so stepper motor driver is used. The microcontroller is used both to control the speed as well as position of stepper motor. The speed of stepper motor is directly proportional to the frequency of drive input pulses which is controllable with the help of microcontrollers and the rotation is proportional to the no of output pulses. In this project we are controlling speed by providing delay by analog to digital converter and direction is controlled by a switch. The system is designed using Philips (P89C51RD2) 8-bit microcontroller. In this system a bipolar stepper motor having 6-wires arrangement has been used as shown in fig.1 with following specification: Maximum voltage 12v Dc, Step angle: 7.5 degree, Steps per revolution: 48. Here centre tap arrangement has been taken into consideration. In this type of arrangement common wires are connected to 12v supply and the two ends of each winding are alternatively grounded to reverse the direction of the field provided by that winding. Fig. 1 Bipolar stepper motor Crystal oscillator of frequency MHZ has been used to produce clock frequency for microcontroller. Since microcontroller is unable to provide sufficient current to stepper motor hence L293D driver has been used in software implementation. However in hardware model darlington pair driver has been used [4]. The 8-pin (pin no. 11 to 18) of ADC0804 has been connected to port 0 of microcontroller and a variable resistor is connected to pin no. 6 of ADC to provide pulse delay stepper motor [3]. II. METHODOLOGY The project work has been divided into two parts. In the first part simulation is done using proteus simulation software and in second part waveform of input pulse is verified by hardware. Fig. 2: Microcontroller based stepper motor hardware model All rights reserved by 267

2 To display direction of movement, step angle and total no. of step moved by motor a 16*2 character LCD has been used. The 8-pin (pin no. 7 to 14) of LCD has been connected to port 1 and pin no. 4,5& 6 of LCD are connected to P3.4, P3.6 & P3.7 of microcontroller. To control direction of movement of motor a switch has been connected to p3.2 of microcontroller. P2.0 to P2.3 of microcontroller has been used to send control signal to stepper motor. Fig. 2 shows hardware of microcontroller based stepper motor [2]. III. STEPPING SEQUENCE Stepper motors can be driven in two different pattern: Full step sequence Half step sequence A. Full step In this type of sequence two coils are energized at the same time and motor shaft rotates accordingly. The stepping sequence for clockwise and is given in table 1. B. Stepper Motor Without Switch Fig. 3: Circuit diagram of microcontroller based stepper motor 1) Simulation Result using Proteus B. Half Step Table 1: Full Step It is the combination of full drive and half drive. In this mode one coil and two coils are energized at a time alternatively [1][5]. Stepping sequence for clockwise and is given in table 2. Fig. 3: waveform of input pulse given to stepper motor for Table 2: Half Step A. Introduction: IV. SIMULATION USING SOFTWARE To implement this project work three software have been used. These are: Kiel Proteus Flash Magic 1) Kiel Kiel compiler has been used to convert high level language into Hex code. 2) Proteus It has been used to simulate the result in software. 3) Flash Magic It has been used to burn Hex code into microcontroller. Fig. 4: waveform of input pulse given to stepper motor for Observation: The on-time pulse width of fig. 3 is more than fig. 4, hence speed of stepper motor is higher for fig. 4. All rights reserved by 268

3 C. Stepper Motor with Switch Fig. 8: waveform of input pulse given to stepper motor for Fig. 5: Circuit diagram of stepper motor with switch 1) Simulation result using proteus Fig. 9: waveform of input pulse given to stepper motor for Observation: From fig. 6 and fig. 8, it has been observed that on time Pulse width of fig. 6 is more than that of fig. 8, hence speed of motor will be less for fig. 6. D. Stepper motor with switch and LCD display Fig. 6: waveform of input pulse given to stepper motor for Fig. 7: waveform of input pulse given to stepper motor for Observation: In fig. 6 Input has been given as 1100, 1001, 0011 and 0110 to Phase A, B, C and D of stepper motor respectively, hence movement of motor is anticlockwise. On other hand, in fig. 7 input has been given as 1100, 0110, 0011 and 1001 to Phase A, B, C and D respectively, hence movement of motor is clockwise. Fig. 10: Circuit diagram of stepper motor with switch and LCD display All rights reserved by 269

4 Fig. 11: waveform of input pulse given to stepper motor for High voltage 2.20 V Low Voltage 0.00 V Amplitude 2.20 V Average Voltage (On time) 1.00 V RMS Voltage (Off time) 1.40 V Period Ms Frequency 4.43 Hz Cycle Average Voltage 1.20 V Cycle RMS Voltage 1.40 V Duty cycle (On time) Percent Duty Cycle (Off time) Percent On time Pulse Width Ms Table 3: Measurement data for Phase A B. Clockwise movement of stepper motor (Speed=100 rpm) Fig. 12: waveform of input pulse given to stepper motor for Observation: From fig. 11 and fig. 12 it has been observed that duty cycle for on time for fig. 11 and fig. 12 is not same, this is due to different step angles in two cases. For of stepper motor steep angle is 15 degree and that of for step angle is 7.5 degree. V. EXPERIMENTAL RESULT A. Anticlockwise Movement of Stepper Motor (Speed=50 rpm) Fig. 13: Waveform of input pulse given to phase A of stepper motor Parameter Value Unit Maximum Voltage 2.20 V Minimum Voltage 0.00 V Peak to Peak Voltage 2.20 V Fig. 14: Waveform of input pulse given to phase A of stepper motor Parameter Value Unit Maximum Voltage 2.20 V Minimum Voltage 0.00 V Peak to Peak Voltage 2.20 V High voltage 2.20 V Low Voltage 0.00 V Amplitude 2.20 V Average Voltage (On time).600 V RMS Voltage (Off time) 1.00 V Period Ms Frequency 4.43 Hz Cycle Average Voltage.600 V Cycle RMS Voltage 1.00 V Duty cycle (On time) Percent Duty Cycle (Off time) Percent On time Pulse Width Ms Table 4: Measurement data for Phase A Observation: From fig. 13 and fig.14 it has been observed that pulse widths for anticlockwise and are not same. This is due to fact that step angle for movement in both directions is not same. Here 15 degree is taken as step angle for and that of for anticlockwise is 7.5 degree. The time to move one step in anticlockwise direction is same as the time to 2 step in clockwise direction, hence speed in case of clockwise movement is more. C. Comparison between Simulated System and Prototype Development Model All rights reserved by 270

5 Microcontroller 80C51 P89C51RD2 P89C51Rd2 belongs to 80C51 microcontroller family. Stepper motor 4-wire 6-wire Two extra wire of 6-wire stepper motor have been connected to 5v. Stepper motor Darlington pair L293D driver Transistor L293D driver supply current upto 500mA while darlington pair upto 1A. LCD 16*2 Used to display direction of movement, step angle and no. of steps 16*2 character character moved by stepper motor. LED Not used Used Showing bit patterns of 4-phases. ADC Not used ADC0804 The set voltage is converted into corresponding 8-bit digital output. Variable resister Not used Used To control the speed of stepper motor. Serial Interface unit Not used Max232 To establish communication between Microcontroller & PC. IR sensor Not used Used To sense rpm of stepper motor. Switch 1 Not used SPDT In programming mode Hex code is burnt into microcontroller IC and in normal mode circuit works according to hex code burnt into microcontroller. Switch 2 On/off SPDT SPDT switch is more reliable. Table 5: Comparison between Simulated System and Prototype Development Model VI. CONCLUSION This research work focuses on the speed control of stepper motor using 8051 microcontroller which has been simulated using proteus software and later its performance has been investigated using hardware model. On the basis of REFERENCES [1] Mazidi Muhammad Ali The 8051 Microcontroller and Embedded Systems, Prentice Hall of India, New Delhi, India, pp , [2] Khalaf Azzeddine Ferrah and Jehad AL Bani Younes Sensorless speed and position estimation in a stepper motor. IEEE transaction on industrial electronics, pp , March [3] Chin Ming Hsu and Hui Mei Chao Constructing microcontroller teaching tool with the integration of hardware and software technology. International conference on new trends in information and service science, pp , [4] Peter Crnosija Microcontroller implement of optional algorithms for closed loop control of hybrid stepper motor driver. IEEE transaction on industrial electronics, Vol. 47, No. 6, pp , [5] Rass Bannatyne Introduction to microcontrollers. IEEE transaction on education, pp , Fab experimental result it has been concluded that more precise and accurate speed control has been achieved by stepper motor which is most important for industrial applications. The speed of the motor is inversely proportional to the pulse delay given to the four phases of stepper motor. All rights reserved by 271

Available Online at www.ijcsmc.com International Journal of Computer Science and Mobile Computing A Monthly Journal of Computer Science and Information Technology IJCSMC, Vol. 2, Issue. 11, November 2013,

Innovative Practices in Optimal Utilization of Solar Energy (Solar Tracking System) Dr. G. Suresh Babu EEE Dept., C.B.I.T Abstract: As the demand is ahead of the supply there is a dire need for efficient

Servo Drive Current Loop Tuning Procedure (intended for Analog input PWM output servo drives) The standard tuning values used in ADVANCED Motion Controls drives are conservative and work well in over 90%

Transmitter Interface Program Operational Manual Version 3.0.4 1 Overview The transmitter interface software allows you to adjust configuration settings of your Max solid state transmitters. The following

INTRODUCTION TO SERIAL ARM A robot manipulator consists of links connected by joints. The links of the manipulator can be considered to form a kinematic chain. The business end of the kinematic chain of

For more Project details visit: http://www.projectsof8051.com/android-based-alcohol-detection-system-usingbluetooth-technology/ Code 1435 Project Title Android based Alcohol detection system using Bluetooth

Digital Single Axis Controller The concept of intelligent hydraulic drive a vision? DSAC (Digital Single Axis Controller) Do you need hydraulic servo drive for your machine/system? What would it be like

Special Lecture Basic Stamp 2 Programming (Presented on popular demand) Programming Environment Servo Motor: How It Work? The editor window consists of the main edit pane with an integrated explorer panel

USE OF VIRTUAL INSTRUMENTS IN RADIO AND ATMOSPHERIC EXPERIMENTS P.N. VIJAYAKUMAR, THOMAS JOHN AND S.C. GARG RADIO AND ATMOSPHERIC SCIENCE DIVISION, NATIONAL PHYSICAL LABORATORY, NEW DELHI 110012, INDIA

Intelligent Home Automation and Security System Ms. Radhamani N Department of Electronics and communication, VVIET, Mysore, India ABSTRACT: In todays scenario safer home security is required, As the technology

April 2014 7 Serial Communications Objectives - To be familiar with the USART (RS-232) protocol. - To be able to transfer data from PIC-PC, PC-PIC and PIC-PIC. - To test serial communications with virtual

International Journal of Electronics and Computer Science Engineering 228 Available Online at www.ijecse.org ISSN- 2277-1956 Design and Construction of Variable DC Source for Laboratory Using Solar Energy

IJCAES ISSN: 2231-4946 Volume III, Special Issue, August 2013 International Journal of Computer Applications in Engineering Sciences Special Issue on National Conference on Information and Communication

Application Note AN601 Tire pressure monitoring 1 Purpose This document is intended to give hints on how to use the Intersema pressure sensors in a low cost tire pressure monitoring system (TPMS). 2 Introduction

Solar Energy Conversion using MIAC by Tharowat Mohamed Ali, May 2011 Abstract This work introduces an approach to the design of a boost converter for a photovoltaic (PV) system using the MIAC. The converter

EET272 Worksheet Week 9 answer questions 1-5 in preparation for discussion for the quiz on Monday. Finish the rest of the questions for discussion in class on Wednesday. Question 1 Questions AC s are becoming

Bay Area Rapid Transit District Study Guide for the Electronics Technician Pre-Employment Examination INTRODUCTION The Bay Area Rapid Transit (BART) District makes extensive use of electronics technology

Remote Control Decoder DESCRIPTION PT2272 is a remote control decoder paired with PT2262 utilizing CMOS Technology. It has 12-bit of tri-state address pins providing a maximum of 531,441 (or 312) address

Tutorial Overview: The basic aim of the project is to find an alternative to the usual RF circuits that are seen so frequently and replace them with cell-phone operated module. The advantages of a cell-phone

C8051F020 Utilization in an Embedded Digital Design Project Course Daren R. Wilcox Southern Polytechnic State University Marietta, Georgia Abstract In this paper, the utilization of the C8051F020 in an

HELIANTHUS THE SOLAR TRACKING SYSTEM A PROJECT BY ARINDAM BOSE, ECE, 4TH YEAR OF FUTURE INSTITUTE OF ENGINEERING AND MANAGEMENT DEPT. OF ELECTRONICS AND COMMUNICATION ENGINEERING ACKNOWLEDGEMENTS I wish

International Journal of Electronic and Electrical Engineering. ISSN 0974-2174 Volume 7, Number 9 (2014), pp. 961-970 International Research Publication House http://www.irphouse.com Electronic Eye for

Tarot 2-Axis Brushless Gimbal for Gopro User Manual V1.0 1. Introduction Tarot T-2D gimbal is designed for the Gopro Hero3, which is widely used in film, television productions, advertising aerial photography,

International Journal of Electronics and Computer Science Engineering 1148 Available Online at www.ijecse.org ISSN- 2277-1956 Automatic Docking System with Recharging and Battery Replacement for Surveillance