Code:
#include <16F877A.h>
#include <def_877A.h>
#fuses NOWDT, HS, NOPUT, NOPROTECT, NOLVP
#use delay(clock=20000000)
void main()
{ set_tris_b(0x00);
While(1)
{
portb = 0x00;
delay_ms(1000);
portb = 0xff;
delay_ms(1000);
} ;
}
đúng là bạn viết code phức tạp wa ! cái nào ko dùng thì viết vào làm gì cho rắc rối !
bạn delay 250ms thì đố ai thấy đc nó nháy !