I define an area of memory that in 'non-volatile' so it doesn't get cleared on powerup. I do this is a module called memmap.asm like this: MyData DS 512 ;Located at 0x801C In another module, I want to declare an array of structures starting at the address of MyData. I tried this: struct tagData { BYTE Num1[32]; BYTE Num2[32]; }; struct tagData xdata MyArray[8] _at_ 0x801C But this doesn't complile. What's wrong? Thanks for any suggestions, RickL
The reason for this is that the members of a structure must reside in a single contiguous block of memory. If you were to declare a structure with one member residing in CODE, and another member residing in, for example, XDATA, then each instance of the structure would have to be split between the two memory spaces.