cllunlu
Member level 4
Hi Friends,
I am trying to programming pic18f66j60. I have problem that when I wrote blinky example, this run but not properly.
my code is
My Project settings:
For example;
LATE.B2= ~LATE.B2;
Delay_ms(500);
When I run it with above codes, led blinky in 500 second, not 500 milisecond.
when I have noticed that, I changed Delay_us(500) instead of Delay_ms(500). That was true.
As a result, I dont know how to solve this problem. I think osillator settings may be wrong.
Anyone help me?
I am trying to programming pic18f66j60. I have problem that when I wrote blinky example, this run but not properly.
my code is
Code:
void main()
{
TRISE = 0x00;
PORTE = 0x00;
while(1)
{
LATE.B2=~LATE.B2;
LATE.B3=~LATE.B3;
Delay_us(500);
}
}
My Project settings:
For example;
LATE.B2= ~LATE.B2;
Delay_ms(500);
When I run it with above codes, led blinky in 500 second, not 500 milisecond.
when I have noticed that, I changed Delay_us(500) instead of Delay_ms(500). That was true.
As a result, I dont know how to solve this problem. I think osillator settings may be wrong.
Anyone help me?