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 access, how ?

Dear sir, i am is a student in physic department,i use uVision IDE for 8051 ver 6.20c, build a single board computer, with core is AT89S52,one Dallas RTC 12C887,and an 8255 PPI, both (RTC & PPI) connected to external ram addres (0x0000),selection which chip activated is done by connecting RTC cs pin to P2.7 micro by an inverter,beside it cs pin on PPI is direct connected to P2.7,i use PPI for driving LCD, and other stepper.i write code like this:

#include <REG52.H>                             /* define 8051 registers */
#include <stdio.h>                             /* define I/O functions */
#include <stdlib.h>
#include <intrins.h>
#include <string.h>
#include <absacc.h>

sbit chip_slct	=	P2^7;

void initializePPI()
{
unsigned char xdata PPI_dt _at_ 0x0000; /* int at xdata 0x0*/
//unsigned char ppi_dat;

//ppi_dat = XBYTE [0x0002];// = 57;

chip_slct = 0;		//activated PPI chip
PPI_dat   = 0x80;
}
.
.
.
.

->>>>>> resulting error message C274 when compiling

..my question is why, or what happen with my source,there is some initialization of my project (for memory model,xram start address) which is miss or forget?.i wish you can assist me to resolve my problem.

Parents Reply Children
  • First, you need to read the uVision Getting Started guide, and work through the example projects in it.

    This will give you a proper introductions to the tools, how they work, and how to use them - rather than just jumping-in blindly at the deep-end!

  • First, you need to read the uVision Getting Started guide, and work through the example projects in it.

    This will give you a proper introductions to the tools, how they work, and how to use them - rather than just jumping-in blindly at the deep-end!


    Andy, How right you are, but what is the hope of someone actually realizing that if you do not know how to boil water, you have but little chance making a cordon bleu?

    Erik