We are running a survey to help us improve the experience for all of our members. If you see the survey appear, please take the time to tell us about your experience if you can.
We have a library called 834keil.lib. This library seems to like being linked under the small memory model. There is an associated header file containing two globals with the data attribute. Removing the data attribute yields an error. We are compiling under the small memory model now and giving our globals an xdata attribute as a work-around.
"In the small memory model, the default memory location for globals is in the 'data' space" To be more precise, the Memory Model defines the default memory space for everything - locals, globals, parameters, etc... If you mix memory models, the different parts of your code will be making different assumptions about the locations of all these things - that way lies disaster!! It's like the two old ladies shouting across the street - they could never reach an agreement, because they were arguing from different premises! ;-)