Monday 4 March 2013

a program to access a led .and perform on and off operations with some delay in 8051


/*a program to access a led .and perform on and off operations with some delay.*/

#include<reg51.h>
#include"delay.h"
sbit led=P1^0;
//#define led P1
void main()
{
 while(1)
 {
  led=~led;
  delay_ms(50);
 
 }
}

OUTPUT:-

No comments:

Post a Comment