Hola compañeros, soy nuevo en esto y me acabo de introducir en este mundo de los PIC hace tan solo una semana. He intentado hacer mi primer programa haciendo que se encienda y se apague un led. He utilizado para ello el PIC16F84A, con el MPLAB 8.50. Pero al hacer el "Build all", me aparece un mensaje que os paso a mostrar:
----------------------------------------------------------------------
Debug build of project `C:\PRACTICAS MPLAB\led1a0.mcp' started.
Language tool versions: MPASMWIN.exe v5.35, mplink.exe v4.35
Preprocessor symbol `__DEBUG' is defined.
Sun Jul 08 19:41:39 2012
----------------------------------------------------------------------
Clean: Deleting intermediary and output files.
Clean: Deleted file "C:\PRACTICAS MPLAB\Ledexperimental.o".
Clean: Deleted file "C:\PRACTICAS MPLAB\Ledexperimental.err".
Clean: Deleted file "C:\PRACTICAS MPLAB\Ledexperimental.hex".
Clean: Deleted file "C:\PRACTICAS MPLAB\Ledexperimental.lst".
Clean: Deleted file "C:\PRACTICAS MPLAB\Ledexperimental.cof".
Clean: Deleted file "C:\PRACTICAS MPLAB\led1a0.mcs".
Clean: Done.
Executing: "C:\Archivos de programa\Microchip\MPASM Suite\MPASMWIN.exe" /q /p16F84A "Ledexperimental.asm" /l"Ledexperimental.lst" /e"Ledexperimental.err" /d__DEBUG=1
Message[302] C:\PRACTICAS MPLAB\LEDEXPERIMENTAL.ASM 23 : Register in operand not in bank 0. Ensure that bank bits are correct.
Executing: "C:\Archivos de programa\Microchip\MPASM Suite\mplink.exe" /p16F84A "Ledexperimental.o" /u_DEBUG /z__MPLAB_BUILD=1 /z__MPLAB_DEBUG=1 /o"Ledexperimental.cof" /M"Ledexperimental.map" /W /x
MPLINK 4.35, Linker
Copyright (c) 1998-2010 Microchip Technology Inc.
Errors : 0
Loaded C:\PRACTICAS MPLAB\Ledexperimental.cof.
----------------------------------------------------------------------
Debug build of project `C:\PRACTICAS MPLAB\led1a0.mcp' succeeded.
Language tool versions: MPASMWIN.exe v5.35, mplink.exe v4.35
Preprocessor symbol `__DEBUG' is defined.
Sun Jul 08 19:41:41 2012
----------------------------------------------------------------------
BUILD SUCCEEDED
Aunque me deja hacer la compilación me dice que hay problemas para volver al banco 0, y aquí es cuando pido ayuda, porque he consultado los manuales que tengo y creo estar haciendolo bien. Os dejo el programa para que le echéis un vistazo y si sois tan amables me pudierais decir que (*/&$*%$%*/) estoy haciendo mal. Muchas gracias de ante mano.
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
; ;
; Programa de led apagado ;
; encendido ;
; ;
; ;
; ;
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;********Estableciendo constantes**********
STATUS equ 03h
TRISA equ 85h
PORTA equ 05h
CONTADOR1 equ 08h
CONTADOR2 equ 09h
;********Configuracion de puertos***********
bsf STATUS,5
movlw 00h
movwf TRISA
bcf STATUS,5
;********Encendido del led******************
Inicio movlw 02h
movwf PORTA
;********Añado retardo**********************
Bucle1 decfsz CONTADOR1,1
goto Bucle1
decfsz CONTADOR2,1
goto Bucle1
;********Apagar led*************************
movlw 00h
movwf PORTA
;********Inicio del Retardo*****************
Bucle2 decfsz CONTADOR1,1
goto Bucle2
decfsz CONTADOR2,1
goto Bucle2
;*********Volver al Inicio******************
goto Inicio
end