How to set a different address other than @00010074

I want to create compiled code in a different address other than the default 00010074.
How can I do that?

You can adjust the linker script, but I’m not quite sure what you are asking. What platform are you trying to compile for? Are you using the Freedom E SDK, or Freedom Studio?

I am using Freedom Studio. I am compiling C code to RISC-V and the default value of the instruction address is 00010074.
I would like the compiled code to use a different address.
This means that branches, saved values etc will also change according to the instruction address that I will assign.

Basically i would like to know, how can i add a linker script (because i currently don’t have one in my project) in order to modify it and choose the address accordingly.

Hi Michalis,

Freedom Studio uses standard GCC linker files. An example of one can be found here:

To add a linker file to a Freedom Studio Project, (optionally) copy the file into the project directory, then inform the linker about the file by selecting the Project and clicking Project – Properties – C/C++ Build – Settings – Linker – General

You can then add the file to the Script Files dialog by clicking the + button. An example is shown in the picture below:

1 Like

IT WORKS!! Thank you very much!

1 Like

By using linker file …
look into this one