Change application start address in PSoC4

Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob
MaPi_3879856
Level 1
Level 1

I'm using a PSoC 4 and I want change the default place of my application in the microcontroller memory: I want to set the application at memory address 0x00001000.

I read I have to change the .ld file, by setting CY_APPL_ORIGIN to 0x00001000.

The firmware is correctly built but I Always have an error whenever I try to program the PSoC. I get this error:

Error: dbg.M0023: There was an error while programming the device: PSoC Programmer reported error (100 - FAILED! Hex File parsing failure. Checksum of Main Flash does not match Hex Checksum record)

It seems like I have to change something in the Hex file but I don't know how. Can anyone help please?

Thanks

0 Likes
1 Solution

If you create a project, and change the ld file through "CY_APPL_ORIGIN".

Even through it can be programmed successfully, the core still can't be boot. It is the ARM spec requirement.

But if you want to change the bootloadable(application) address, you can modify, because when you want to use the bootloadable, it means the ARM cortex has boot.

In your previous response, you want to achieve a function that the code can be set at the start of any address, after my review of many materials, it belongs to an illegal operation.

In addition, the report mismatch error can't be correct by any ways.

View solution in original post

0 Likes
4 Replies
LinglingG_46
Moderator
Moderator
Moderator
500 solutions authored 1000 replies posted 10 questions asked

I am so sorry to make a mistake about the understanding about the ".ld file CY_APPL_ORIGIN to 0x00001000",

CY_APPL_ORIGIN means which flash line the APPL load, not the address.

So if you set the 0x00001000, it is out of the range.

0 Likes

Are you saying that CY_APPL_ORIGIN is the number of the memory line and not the address?

If this is the case, supposing I want my app to start at address 256, I should put CY_APPL_ORIGIN equal to 2, if each line is 128 bytes, correct?

0 Likes

If you create a project, and change the ld file through "CY_APPL_ORIGIN".

Even through it can be programmed successfully, the core still can't be boot. It is the ARM spec requirement.

But if you want to change the bootloadable(application) address, you can modify, because when you want to use the bootloadable, it means the ARM cortex has boot.

In your previous response, you want to achieve a function that the code can be set at the start of any address, after my review of many materials, it belongs to an illegal operation.

In addition, the report mismatch error can't be correct by any ways.

0 Likes

The below response is wrong, please ignore it if someone want to refer to this forum.

// wrong response//

I am so sorry to make a mistake about the understanding about the ".ld file CY_APPL_ORIGIN to 0x00001000",

CY_APPL_ORIGIN means which flash line the APPL load, not the address.

So if you set the 0x00001000, it is out of the range.

0 Likes