 | Discussion Forum |  |
|
|
How to combine CODE and XDATA class segments?Next Thread | Thread List | Previous Thread Start a Thread | Settings | Details | Message |
|---|
Read-Only Author Kirill Katsnelson Posted 29-Aug-2003 17:41 GMT Toolset C51 |  How to combine CODE and XDATA class segments? Kirill Katsnelson I am writing in C51 for Cypress EZ-USB device, that has 8KB of flat memory - that is, data and code fetches read the same memory. How can I specify this in complier or linker options? Currently, when I write
xdata BYTE something[42];
then something is placed into the memory already occupied by some CODE memory.
How can I support flat memory organization? I hope I am not supposed to deprive the linker of its job an write CODE(0x80) XDATA(0x1A44), no? :) | | Read-Only Author Drew Davis Posted 29-Aug-2003 18:29 GMT Toolset C51 |  RE: How to combine CODE and XDATA class segments? Drew Davis In the 8051 world, people usually call this sort of architecture "von Neumann" memory. You might want to search the Knowledgebase and forums with that phrase. Here's a start:
http://www.keil.com/support/docs/856.htm
That method just divides up your memory for the linker. If you want the boundary between code and xdata to float along with changing code sizes, you'll have to dig a little deeper. | | Read-Only Author Kirill Katsnelson Posted 30-Aug-2003 04:08 GMT Toolset C51 |  RE: How to combine CODE and XDATA class segments? Kirill Katsnelson Drat! So I do take linker's job... If linkers had unions, they might have been worried! | |
Next Thread | Thread List | Previous Thread Start a Thread | Settings |
|