I have a project that requires a function to be placed at a particular location in flash (0x15555 to be precise). The issue is that my code is larger than this. When I build now, I get the following error:
ERROR: section NV_CONFIG2 loaded at [00015555,0001558b] overlaps section .text loaded at [00000000,0004a7f3]
Can we modify the linker such that the function is placed first and the code is placed in the remaining region? I am flash-limited in my project so I would not prefer to place the entire code after the said location. Also, manually arranging each file in sections would not be feasible as the code is in development.
You can do nearly everything with LD. But it does not autofill sections, so you need to place some code before and some after your NV_CONFIG2.