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

Porting source code from C51 to ARMC

I have a program in C51 that I waned to port to ARMC specifically the Cortex_M3 namely LPC17xx micros, however the locating of the variables is not happening correctly, namely:

In C51, the memory areas; bdata, idata, xdata, code.

Attempting to use "const" for lookup tables that were in ROM does NOT place the variables in ROM (as expected) but in RAM.

Likewise the use of "static" for variables in RAM does work (the indirectly addressed area or XRAM areas are non existant in the ARM architecture so that's fine).

For bit variables I have typedef'ed a structure and added the "__attribute__((bitband))" to use bit banding (that is one way).

I have searched here at "Keil" and the "ARM infocenter" considerably for a guide or tutorial for all like myself that are attempting to transition to ARM but have not found this information in specific form.

So how are variables located in different memory areas in the ARM processors, any help will be appreciated.