Showing posts with label Full Stepper Motor. Show all posts
Program for full stepper motor
full stepper motor:
ORG 0000H
MOV P2,#00H ;initialize as op port
/*
////////////////////////////////////////METHOD-2 HALF STEPPING//////////////////////////////////////////
exit:
mov dptr,#msg
rpt:clr a
movc a,@a+dptr
jz exit
inc dptr
mov p2,a
acall delay
sjmp rpt */
/////////////////////////////////////////////////////////////////////////////////////////////
////////////////////////////////////////METHOD-1//////////////////////////////////////////
MOV A,#66H
AGAIN:MOV P2,A
JNB P1.0,NXT ;check status of switch
RR A
ACALL DELAY
SJMP AGAIN
NXT:RL A
ACALL DELAY
SJMP AGAIN
/////////////////////////////////////////////////////////////////////////////////////////////
DELAY:
MOV R1,#01H
H3:MOV R2,#0FFH
H2:MOV R3,#0FFH
H1:DJNZ R3,H1
DJNZ R2,H2
DJNZ R1,H3
RET
msg:
db 08h,04h,02h,01h,0
END
CLICK HERE TO SEE CIRCUIT DIAGRAM
ORG 0000H
MOV P2,#00H ;initialize as op port
/*
////////////////////////////////////////METHOD-2 HALF STEPPING//////////////////////////////////////////
exit:
mov dptr,#msg
rpt:clr a
movc a,@a+dptr
jz exit
inc dptr
mov p2,a
acall delay
sjmp rpt */
/////////////////////////////////////////////////////////////////////////////////////////////
////////////////////////////////////////METHOD-1//////////////////////////////////////////
MOV A,#66H
AGAIN:MOV P2,A
JNB P1.0,NXT ;check status of switch
RR A
ACALL DELAY
SJMP AGAIN
NXT:RL A
ACALL DELAY
SJMP AGAIN
/////////////////////////////////////////////////////////////////////////////////////////////
DELAY:
MOV R1,#01H
H3:MOV R2,#0FFH
H2:MOV R3,#0FFH
H1:DJNZ R3,H1
DJNZ R2,H2
DJNZ R1,H3
RET
msg:
db 08h,04h,02h,01h,0
END
CLICK HERE TO SEE CIRCUIT DIAGRAM
full stepper motor using 8051
This is the circuit diagram of interfacing of full stepper motor.

CLICK HERE TO SEE PROGRAM FOR FULL STEPPER MOTOR
Stepper motors consist of a permanent magnet rotating shaft, known as rotor, and electromagnets on the stationary portion that surrounds the motor, known as stator the stator. You can see in the figure given below. At position 1, we see that the rotor is beginning at the upper electromagnet, which is currently active because we have applied voltage. To move the rotor clockwise, the upper electromagnet is deactivated and the right electromagnet is activated, causing the rotor to move 90 degrees clockwise, aligning itself with the active magnet. This process is repeated in the same manner at the south and west electromagnets until we once again reach the starting position.
CLICK HERE TO SEE PROGRAM FOR FULL STEPPER MOTOR