;--------------------------------------------------------------------------
; File:   Main.c
; Author: topicchi
;
; Created on 12 ottobre 2013, 21.00
;--------------------------------------------------------------------------


    INCLUDE "P16F84.INC"    ; include le definizioni standard
    list	p=pic16f84      ; Processoer utilizzato
    errorlevel -302         ;suppress message "Bank Switch Check"
    __config _CP_OFF & _PWRTE_OFF & _WDT_OFF & _HS_OSC

; - - - - -

    org 0x00
    goto Start

    org 0x04
    goto Irq

Start
    bsf STATUS,RP0
    movlw b'00000000'		;set PortB all outputs
    movwf TRISB
    movlw b'00000000'		;set PortA all outputs
    movwf TRISA
    bcf STATUS,RP0

Main
    movlw 0xFF
    movwf PORTA
    movwf PORTB
    incf PORTB,f
    nop
    goto Main

Irq
    retfie
    end


