when mpasm compiles my code using PicBasic Pro, does the entire PBPPIC14.lib file get compiled also, or is it only the specific functions that i'm using such as ADCIN, or SEROUT, etc.
when mpasm compiles my code using PicBasic Pro, does the entire PBPPIC14.lib file get compiled also, or is it only the specific functions that i'm using such as ADCIN, or SEROUT, etc.
Only sections of the library that are required get compiled.
I don't know what your needs are, but I have had two instances where I needed to
automatically watch the code size:
1. I use MCLOADER, which occupies some of the chip's upper memory.
I need to make sure my compiled code does not "run into" the bottom of MCLoader.
2. I sometimes want to know if my code is small enough to fit into a smaller, cheaper chip.
The technique I use is to add a few statements at the end of my programs -
ASM
ORG 0x1fcee <=== Put the address you don't want to over-run here.
nop
ENDASM
If the code is too big and over-runs the ORG address, MPASM will flag an error.
Charles Linquist
Bookmarks