0% found this document useful (0 votes)
136 views12 pages

Stepper Motor With 8051 Microcontroller.: By: Prof. Amit N Kshirsagar

This document discusses interfacing a stepper motor with an 8051 microcontroller. It describes stepper motors and their operation in full and half stepping modes. It provides code to continuously rotate the stepper motor in clockwise direction using an 8051 microcontroller. The code defines a delay subroutine and stores the step sequence values in a table in RAM memory. It outputs the step signals to port 1 to drive the motor in sequential steps for continuous rotation.

Uploaded by

Amit Kshirsagar
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
136 views12 pages

Stepper Motor With 8051 Microcontroller.: By: Prof. Amit N Kshirsagar

This document discusses interfacing a stepper motor with an 8051 microcontroller. It describes stepper motors and their operation in full and half stepping modes. It provides code to continuously rotate the stepper motor in clockwise direction using an 8051 microcontroller. The code defines a delay subroutine and stores the step sequence values in a table in RAM memory. It outputs the step signals to port 1 to drive the motor in sequential steps for continuous rotation.

Uploaded by

Amit Kshirsagar
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
You are on page 1/ 12

Stepper Motor with 8051 Microcontroller.

BY: PROF. AMIT N KSHIRSAGAR


Contents
 Stepper Motor: Introduction, Types

 Why stepper Motor??

 Full stepping mode, Half stepping mode

 Interfacing of Stepper motor with 8051 Microcontroller

 Program to rotate stepper motor continuously in clockwise


direction
Stepper Motor: Introduction
 A stepper motor is a brushless, synchronous electric motor that converts digital
pulses into mechanical shaft rotation.
 Every revolution of the stepper motor is divided into a discrete number of
steps.
 In many cases 200 steps, and the motor must be sent a separate pulse for each
step.
 The stepper motor can only take one step at a time and each step is the same
size.
 Each pulse causes the motor to rotate a precise angle, typically 1.8°, therefore
motor's position can be controlled without any feedback mechanism.
Stepper Motor: Introduction
 As the digital pulses increase in frequency, the step movement changes into
continuous rotation, with the speed of rotation directly proportional to the
frequency of the pulses.
 Step motors are used every day in both industrial and commercial applications
because of their low cost, high reliability, high torque at low speeds and a
simple, rugged construction that operates in almost any environment.
Construction of stepper Motor
4-Step Sequence: Full stepping Mode Sequence
8-Step Sequence: Half stepping Mode Sequence
Interfacing of Stepper motor with 8051 Microcontroller
Program to rotate stepper motor continuously

 ORG 0000h
 SJMP 0030H
  
 ORG 0030H
 MOV P1, #80H ; Initialise port 1 // 1000 0000
 ACALL DELAY ; Delay
 START: MOV DPTR,#FORWARD ; Load forward
direction table Address
 MOV R7, #08H ; Steps
 NEXT: CLR A
 MOVC A,@A+DPTR ; Initialise A for signal.
 INC DPTR
 MOV P1,A ; Out stepper signal to p1
 ACALL DELAY
 DEC R7
 CJNE R7,#00,NEXT ; keep in step loop
 SJMP START ; keep in continuous loop
Code: Delay Subroutine

 DELAY: MOV R1,#0F2H ;delay as per user


 MOV R2,#0F2H ;motor speed is depend on delay
 MOV R3,#010H ; if you want slow speed increase delay
 D1: DJNZ R1,D1
 MOV R1,#010H
 DJNZ R2,D1
 MOV R2, #010H
 DJNZ R3,D1
 RET
Code: Storing Step value table in RAM Memory

 /* hex code values for clockwise rotation */


 FORWARD: DB 01H,03H,02H,06H,04H,0CH,08H,09H

 /* hex code values for anti-clockwise rotation */


 REVERSE: DB 09H,08H,0CH,04H,06H,02H,03H,01H
 END

You might also like