doubt | Microcontroller › 8051 › doubt This topic has 0 replies, 1 voice, and was last updated 11 years, 5 months ago by saavanan. Viewing 1 post (of 1 total) Author Posts September 3, 2013 at 4:14 am #2618 saavananParticipant guys please help me.i want proteses simulation for this code #include <REGX51.H> sbit LED1=P1^0; sbit LED2=P1^1; sbit LED3=P1^2; sbit LED4=P1^3; void call_blink(unsigned char dat); void delay(void); void main() { TMOD=0x05; TH0=0xff; //for 12MHz (12/12MHZ)=1u>per cycle operation TL0=0xf0; TR0=1; while(TF0==0) { call_blink(TL0&0x0f); } if(TF0==1) { TF0=0; call_blink(0xff); } } void call_blink(unsigned char dat) { if(dat==0xff) { while(1) { LED1=0;delay(); LED1=1;delay(); } } if(dat==0x01) LED2=0; if(dat==0x04) LED3=0; if(dat==0x08) LED4=0; } /******************delay**********************/ void delay(void) { unsigned char i; for(i=0;i<255;i++) { for(i=0;i<255;i++); } } Author Posts Viewing 1 post (of 1 total) You must be logged in to reply to this topic. Log In Username: Password: Keep me signed in Log In