We are running a survey to help us improve the experience for all of our members. If you see the survey appear, please take the time to tell us about your experience if you can.
We are using the P87C51MC2 in extended memory. We are currently up to 512K bytes of code (ECODE). For test reasons I would like to locate code at a specific address. If I have main.obj, A.obj, B.obj and C.obj I would like to locate A.obj at 0x2000, B.obj at 0x3000 and C.obj at 0x4000. How do you do this with the linker?
I am interested in using the command line. I looked up CODE and I don't think it applies. CODE is only good from 0x0000 to 0xFFFF. We have ECODE.
I did find a way using SEGMENTS
SEGMENTS(?PR?_func_a?file_a(0x810000), ?PR?_func_b?file_b(0x820000) )
This locates two separate functions in different files at 0x810000 and 0x820000. Note the first underscore on the function name. The compiler gives it that.