Page 1 of 1

Include and List Commands?

Posted: Tue Mar 24, 2009 3:38 am
by econnections
In Assembly for PICMicro v2 the INCLUDE command is extensively used to save having to keep adding a list of the registry file names. In v4 this has been omitted.

Q1 Is there a reason for not using it in v4? I note the P16F88.inc file is not inclused on the disk. If I can use INCLUDE where can I get the file from?

Q2 In v4 I noticed a new statement: LIST P=16F88. Please can you explain its purpose?

Q3 Is there a source for any of the 16F*.inc files on the web? I couldn't find one at Microchip

Many Thanks

Re: Include and List Commands?

Posted: Tue Mar 24, 2009 8:41 am
by Steve
econnections wrote:In Assembly for PICMicro v2 the INCLUDE command is extensively used to save having to add the registry file files. In v4 this has been omitted.

Q1 Is there a reason for not using it in v4? I note there is not P16F88.inc file. If I can use INCLUDE where can I get the file from?
I don't remember changing the way things were done with the INC files, but I cannot find a v2 installation so I can't verify this. I think the reason that the INC file is not used is because explicitly defining the registers used within the program each time adds to the learning because it relates back to the hardware in the chip, rather than having a "black-box" include. Of course, using the INC file in a proper development environment is better and once you understand assembly and the internals of a PICmicro, you will probably use.
econnections wrote:Q2 In v4 I noticed a new statement: LIST P=16F88. Please can you explain its purpose?
This tells the assembler which chip to target. In older versions of the software, this info was passed as a command line parameter to MPASMWIN.
econnections wrote:Q3 Is there a source for any of the 16F*.inc files on the web? I couldn't find one at Microchip
These will be in your MPLAB folder. You can do a search on your hard drives for *.inc if you do not know where this is.