I have been playing around with the PIC16F628 for a while, and now I want to transfer to something that has more pins. Specifically the PIC16F876, but I can't get it working. I just want to turn an LED on/off and nothing ever happens. This is my circuit:
I program my PICs in the mikroC editor and these are the settings:
- OSCILLATOR: HS
- WATCHDOG: Disabled
- POWER-UP TIMER: Disabled
- FLASH code protection: Disabled
- Brown-out reset: Enabled
- Low voltage programming: Disabled
- Flash program memory write: Enabled
- In-circuit debug: Disabled
And this is my code:
void main(){
TRISB = 0x00;
while(1){
PORTB = 0b11111111;
delay_ms(500);
PORTB = 0b00000000;
delay_ms(500);
}
}
And nothing works. I tried with 4.10 and 11 MHz oscillator values and nothing. What did I do wrong?