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 combine CODE and XDATA class segments?

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? :)