This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

xdata on MSC1200Y3

From the TI MSC1200Y3 documentation there is supposed to be 1024 bytes of xdata (0-0x400) available on the device. The following simple program compiles and links with no errors, but when it runs the output value shows 0xFFFF as though there is no RAM there. It runs as expected in the simulator. It runs as expected if XDATA is defined to idata, so it is probably not a logic or compiler issue.

I've tried setting the Target Options "Off chip Xdata Memory" to :
Start = 0
Size = 0x400
and I've tried modifying the Startup.A51 values:
XDATASTART EQU 0H ; the absolute start-address of XDATA memory
XDATALEN EQU 0400H ; the length of XDATA memory in bytes.

But neither of these have helped, I still get 0xFFFF when reading xdata memory.
I dont see any SFR for memory control that would limit this access.

Do I need to set the xdata memory range through the GUI or in Startup.a51 or both?

Is there some other tool setting that I'm missing?

Any help would be appreciated...
==============
#define XDATA xdata
// #include <REG1200.H>
sfr TCON = 0x88;
sfr CKCON = 0x8E;
sfr MWS = 0x8F;

#include <stdio.h>

extern void autobaud(void);

#define ARRAY_SIZE 10

void main(void)
{
unsigned int idata i;
int XDATA dd[ARRAY_SIZE];

CKCON = 0x10;
TCON = 0;
autobaud();

for (i=0; i < ARRAY_SIZE; i++) dd[i] = i;
printf("dd[8] = %x\n", dd[8]); /* = 0xFFFF = wrong! */

}

0