need help translating this code and

Thread Starter

terramir

Joined Feb 7, 2013
2
Need help fixing this code if it needs fixing, I dunno I have a 16F877a laying around and a programmer one of those olimex serial port deals pic-PG2C.
and I would like to make the capacitance meter described in the source file the only thing I edited so far is the micro controllers name.

Warning is is long code (801 lines plus warnings) so I linked it from here http://pastie.org/private/ps6ncobussoabwgajjrura the warnings are all on the bottom but I'm putting one here to show what I'm dealing with.

Message[302] /Users/terramir/MPLABXProjects/capacitormeter.X/piccap.asm 95 : Register in operand not in bank 0. Ensure that bank bits are correct
this is for a capacitor meter an autoranging one I found on the web but that seems to be not maintained I had to get the source from the way back machine (dead page geocities)
help
terramir
 

absf

Joined Dec 29, 2010
1,949
just remove the semi-colon on this line

; ERRORLEVEL -302
and it would assemble without any banksel error message. Or you can ignore the messages. They are just warning. The hex code would work just fine.

Allen
 
Last edited:

absf

Joined Dec 29, 2010
1,949
The software was written for the 16F873 (28 pin PIC). If you want to use 16F877A (40 pin PIC), it should work too. Just keep the pin name the same, the pin numbers might be different. IIRC, the 877A has extra pins for port D.

Also don't forget to change the selected PIC from 16F873 to 16F877 & the INC file as well before assembling.

Rich (BB code):
		LIST P=16F877A
		INCLUDE "p16f877a.inc"
Allen
 
Top