Experiment - 9 - Stepper Motor
Experiment - 9 - Stepper Motor
Experiment - 9 - Stepper Motor
Tech (EE)
Trimester: VII Subject:
Name: Class:
Roll No: Batch:
Experiment No: 09
Name of the Experiment: Interfacing of Stepper motor with C8051F340.
Submitted on:
Aim: Write C program for interfacing of Stepper motor with C8051F340 to rotate in clockwise
and anticlockwise direction.
Theory:
A stepper motor is known by its important property to convert a train of pulses into a
precisely defined increment in the shaft position. A stepper motor is a widely used a device that
translates electrical pulses into mechanical movement. In applications such as disk drivers, dot
matrix printers, and robotics, the stepper motor is used for position control. Every stepper motor
has a permanent magnet rotor ( also called as shaft ) surrounded by a stator the most common
stator motors have four stator windings that are paired with a centre-tapped common as shown in
the figure. This type of stator motor is commonly referred to as four phase stepper motor. The
centre tap allows a change of current direction in each of two coils, when a winding is grounded,
thereby resulting in polarity change of the stator. Notice that while a conventional motor shaft
runs freely, the stepper motor shaft moves in a fixed repeatable increment which allows one to
move it to a precise position.
www.mitwpu.edu.in
Figure 8.1 Stepper motor windings
This repeatable fixed movement is possible as a result of basic magnetic theory where
poles of same polarity repel and opposite attract. The direction of rotation is indicated by the
stator poles. The stator poles are determined by the current sent through the wire coils A, B,C
and D as shown in Figure 8.1. As the direction of current is changed, the polarity is also changed
causing the reverse motion of the rotor. The stepper motor discussed here has a total of six leads:
four leads representing the four stator windings and two commons for the centre tapped leads. As
the sequence of power is applied to each stator winding, the rotor will rotate. There are several
widely used sequences where each has a different degree of precision. The stepping sequence of
excitations is as shown in Table 8.1.
Table 8.1 The stepping sequence
Windings D C B A
Sequence in hex on P4.7 P4.6 P4.5 P4.4 P4.3 P4.2 P4.1 P4.0
Port 4
0A 0 0 0 0 1 0 1 0
88 1 0 0 0 1 0 0 0
A0 1 0 1 0 0 0 0 0
22 0 0 1 0 0 0 1 0
www.mitwpu.edu.in
Types of Stepper Motor:
Permanent Magnet Stepper Motor: Permanent magnet motors use a permanent magnet (PM)
in the rotor and operate on the attraction or repulsion between the rotor PM and the stator
electromagnets.
Variable Reluctance Stepper Motor: Variable reluctance (VR) motors have a plain iron rotor
and operate based on the principle that minimum reluctance occurs with minimum gap, hence the
rotor points are attracted toward the stator magnet poles.
Hybrid Synchronous Stepper Motor: Hybrid stepper motors are named because they use a
combination of permanent magnet (PM) and variable reluctance (VR) techniques to achieve
maximum power in a small package size.
Applications:
1. Industrial Machines – Stepper motors are used in automotive gauges and machine
tooling automated production equipment.
2. Security – new surveillance products for the security industry.
www.mitwpu.edu.in
3. Medical – Stepper motors are used inside medical scanners, samplers, and also found
inside digital dental photography, fluid pumps, respirators and blood analysis machinery.
4. Consumer Electronics – Stepper motors in cameras for automatic digital camera focus
and zoom functions.
Interfacing Diagram:
Hardware Connections:
Connect flat cable between PL3 connector of ASK25 and PL6 connector of EPBF340 board.
Connect stepper motor at PL4 connector of ASK25. Connect 9V power supply at PL9 connector
of ASK25 before connecting the stepper motor. Press DIP switch SW9 on ASK25 to run the
motor.
Pin PL3 Connector PL6 Connector of
Connection of ASK25 EPBF340
11 Input 1 (A) P4.1
13 Input 2 (B) P4.3
15 Input 3 (C) P4.5
17 Input 4 (D) P4.7
www.mitwpu.edu.in
19 5V 5.0 V
20 GROUND GND
Additional Links:
https://nptel.ac.in/courses/112103174/16
www.mitwpu.edu.in