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

How to define a variable at external RAM?

if the CARM compiler have the key word define the external data just like "xdata" in 51?

Parents
  • Well, so thanks for you reply. But when I use the keyword "__ram", the error come. My code is "__ram uint32 k1[1000];" or "uint32 k1[1000] __ram;" but always get the error "SOURCE\MAIN.C(32): error C25: syntax error near '__ram'" or "SOURCE\CIS_MAIN.C(32): error C25: syntax error near ';'". In the LA Locate -> User class, I enter "ERAM (0x80000000-0x80001000)", but the error still come. what's wrong with my code and my operation and how should I do?

Reply
  • Well, so thanks for you reply. But when I use the keyword "__ram", the error come. My code is "__ram uint32 k1[1000];" or "uint32 k1[1000] __ram;" but always get the error "SOURCE\MAIN.C(32): error C25: syntax error near '__ram'" or "SOURCE\CIS_MAIN.C(32): error C25: syntax error near ';'". In the LA Locate -> User class, I enter "ERAM (0x80000000-0x80001000)", but the error still come. what's wrong with my code and my operation and how should I do?

Children