main.c uchar xdata g_uhour,g_uminute,g_usecond; void TimeDisp(uchar h,uchar m,uchar s) { ... } void main(void) { ... while(1) { if (page==0) { ... TimeDisp(g_uhour,g_uminute,g_usecond);//a } else if (page ==1) { ... TimeDisp(g_uhour,g_uminute,g_usecond);//b } else if (page==2) { } ... } }
Have you configured the start address and size of your xdata space in the project options? Does the derivative you use need any special configuration to access all or part of its xdata space?