/* 
 * File:   Main.c
 * Author: topicchi
 *
 * Created on 8 maggio 2013, 21.12
 */

#include <stdio.h>
#include <stdlib.h>
#include <xc.h>

#ifndef _XTAL_FREQ
#define _XTAL_FREQ 4000000
#endif

#define LED_0 PORTAbits.RA2
#define LED_1 PORTAbits.RA3

//#pragma config FOSC =  EXTRC, WDTE = OFF, PWRTE = ON//, CP = OFF
#pragma config FOSC =  XT, WDTE = OFF, PWRTE = ON//, CP = OFF
#define FOSC _XTAL_FREQ

/*
 * 
 */
int main(int argc, char** argv) {
    TRISA=0x00;
    PORTA=0x00;
    while(1) // Run Forever
    {
      LED_0=1;
      //LED_1=0;
      __delay_ms(500);
      LED_0=0;
      //LED_1=1;
      __delay_ms(250);
    }


    return (EXIT_SUCCESS);
}

