We are running a survey to help us improve the experience for all of our members. If you see the survey appear, please take the time to tell us about your experience if you can.
#include<AT89X51.h> void delay(unsigned int); void main(void)
{ P1_1=0; /* unset pin # 1*/
P1_2=0; /* unset pin # 2*/
/* bring delay*/
delay(300); P1_1=1; /* set pin # 1*/ P1_2=1; /* set pin # 2*/ /*bring delay*/ delay(300) }
/* define delay function*/ void delay(unsigned int itime) { int i,j; for (i=0;i<itime;i++); for (j=0;j<5000;j++); }