If I wish to declare an absolute variable using _at_, and I wish to declare it in a header file so that it is available to more than one module, I keep getting the SPACE OVERLAP message. How can I solve this?
In other modules, simply declare it as extern - for example: In the main definition module: xdata unsigned char IOPORT _at_ 0x7FF0; and in all other modules: extern xdata unsigned char IOPORT; regards Dejan
Thank you guys - that has fixed it...
and in all other modules: extern xdata unsigned char IOPORT; Or rather, put that line into the header file, to be #included by the other modules. That's what I was trying to tell you to do when I wrote "change the header to a declaration" --- I had assumed it goes without telling that the relevant other modules would all be #including that header file.
extern xdata unsigned char IOPORT;
Even better... Thanks. I migrated my code from another Compiler recently, which somehow preempted this issue, but I'm happy to have added another little skill to my coding.