Stepper motor using at89c51 microcontroller












Try New Document

#include

void delay(unsigned int t)
{
while(t--);
}

void main()
{
P2=0x00;
while(1)
{
P2=0x01;
delay(10000);
P2=0x02;
delay(10000);
P2=0x04;
delay(10000);
P2=0x08;
delay(10000);
}
}

Ask me freely if any query.

Comments