Continue to Site

Welcome to our site!

Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

  • Welcome to our site! Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

newbie error

Status
Not open for further replies.

gastonanthony

New Member
hey, can anyone help a beginner? :? its a blinking led program. i just copied this code from mikroelectronika and it doesn't build and produces an error. here's the code and corresponding error:
Code:
			PROCESSOR 16F84
			#include"p16f84.inc"

		__CONFIG _CP_OFF & _WDT_OFF & _PWRTE_ON &_XT_OSC

	Cblock 0x0C
	endc

	ORG		0X00
	goto 	Main
	ORG		0X04
	goto    Main

Main
	banksel	TRISB
	clrf	TRISB
	banksel	PORTB
	movlw	0Xff
	movlw	PORTB

Loop	goto Loop

	End

Clean: Deleting intermediary and output files.
Clean: Done.
Executing: "C:\Program Files\Microchip\MPASM Suite\MPAsmWin.exe" /q /p16F84A "blink182.asm" /l"blink182.lst" /e"blink182.err"
Message[301] C:\PROGRAM FILES\MICROCHIP\MPASM SUITE\P16F84.INC 37 : MESSAGE: (Processor-header file mismatch.  Verify selected processor.)
Message[302] C:\DOCUMENTS AND SETTINGS\FOR TAIPANS\MY DOCUMENTS\GAS\EXPERIMENT PIC FILES\BLINK182.ASM 17 : Register in operand not in bank 0.  Ensure that bank bits are correct.
Error[173]   C:\DOCUMENTS AND SETTINGS\FOR TAIPANS\MY DOCUMENTS\GAS\EXPERIMENT PIC FILES\BLINK182.ASM 25 : Source file path exceeds 62 characters (C:\DOCUMENTS AND SETTINGS\FOR TAIPANS\MY DOCUMENTS\GAS\EXPERIMENT PIC FILES\BLINK182.ASM)
Halting build on first failure as requested.
BUILD FAILED: Sat Apr 09 18:16:21 2005

thanks
 
gastonanthony said:
hey, can anyone help a beginner? :? its a blinking led program. i just copied this code from mikroelectronika and it doesn't build and produces an error. here's the code and corresponding error:
Code:
			PROCESSOR 16F84
			#include"p16f84.inc"

		__CONFIG _CP_OFF & _WDT_OFF & _PWRTE_ON &_XT_OSC

	Cblock 0x0C
	endc

	ORG		0X00
	goto 	Main
	ORG		0X04
	goto    Main

Main
	banksel	TRISB
	clrf	TRISB
	banksel	PORTB
	movlw	0Xff
	movlw	PORTB

Loop	goto Loop

	End

Clean: Deleting intermediary and output files.
Clean: Done.
Executing: "C:\Program Files\Microchip\MPASM Suite\MPAsmWin.exe" /q /p16F84A "blink182.asm" /l"blink182.lst" /e"blink182.err"
Message[301] C:\PROGRAM FILES\MICROCHIP\MPASM SUITE\P16F84.INC 37 : MESSAGE: (Processor-header file mismatch.  Verify selected processor.)
Message[302] C:\DOCUMENTS AND SETTINGS\FOR TAIPANS\MY DOCUMENTS\GAS\EXPERIMENT PIC FILES\BLINK182.ASM 17 : Register in operand not in bank 0.  Ensure that bank bits are correct.
Error[173]   C:\DOCUMENTS AND SETTINGS\FOR TAIPANS\MY DOCUMENTS\GAS\EXPERIMENT PIC FILES\BLINK182.ASM 25 : Source file path exceeds 62 characters (C:\DOCUMENTS AND SETTINGS\FOR TAIPANS\MY DOCUMENTS\GAS\EXPERIMENT PIC FILES\BLINK182.ASM)
Halting build on first failure as requested.
BUILD FAILED: Sat Apr 09 18:16:21 2005

thanks
The error has to do with COD file type limitation. The easyest way how to correct this is to put your folder into root folder od your HDD. Then it should work. Other solution is to use COFF files instead, but it's harder to setup, for beginner.
 
The MicroChip assembler MPASM is only a 16 bit application, so you should only use short file and directory names - preferably without any spaces!. It does work to some extent with long filenames, but it often causes problems! - it's what comes of Windows having a 'bodged' filename system, rather than a proper long filename system.
 
Status
Not open for further replies.

Latest threads

Back
Top