Program PIC with Pickit 3

Program PIC with Pickit 3
  1. PIC16F84A
#include <xc.h> #define _XTAL_FREQ 4000000 #pragma config FOSC = HS // Oscillator Selection bits (HS oscillator) #pragma config WDTE = OFF // Watchdog Timer (WDT disabled) #pragma config PWRTE = ON // Power-up Timer Enable bit (Power-up Timer is enabled) #pragma config CP = OFF // Code Protection bit (Code protection disabled) int main(void) { TRISBbits.TRISB0 = 0; PORTBbits.RB0 = 0; while (1) { PORTBbits.RB0 = 0; __delay_ms(100); PORTBbits.RB0 = 1; __delay_ms(100); } return 0; }