gehan_s
Member level 3
- Joined
- Aug 31, 2012
- Messages
- 62
- Helped
- 3
- Reputation
- 6
- Reaction score
- 3
- Trophy points
- 1,288
- Location
- Sri Lanka
- Activity points
- 1,799
Hi all,
Please help me set the configuration bits for my pic18F2550 microcontroller. I am using mikroc v8.2 with an external quartz crystal. I tried the default settings with the following code and the timing was way off. BTW the circuit works even without the oscillator (I think this has to do with the default bit setting).
This is the code that I tried.
Thanks in advance !!!!!!!!!!!!!!!
void main(){
TRISA=0;
while(1){
PORTA=1;
delay_ms(1000);
PORTA=0;
delay_ms(1000);
}
}
Please help me set the configuration bits for my pic18F2550 microcontroller. I am using mikroc v8.2 with an external quartz crystal. I tried the default settings with the following code and the timing was way off. BTW the circuit works even without the oscillator (I think this has to do with the default bit setting).
This is the code that I tried.
Thanks in advance !!!!!!!!!!!!!!!
void main(){
TRISA=0;
while(1){
PORTA=1;
delay_ms(1000);
PORTA=0;
delay_ms(1000);
}
}