The ARM M0 processor needs the lower addresses when started. They are containing a few bytes system relevant informations.
There are other possibilities:
You can always put a variable into flash memory using the "const" specifier and an initialization.
With the help of the linker you can assign a fixed address (preferrably at the end of flash) to a variable.
There is some supervisor flash in the PSoC BLE chip (not PRoC)
This might help -
I would have liked to see a different solution like a "flash" qualifier, but GCC developers have choosen a different solution. Now the "const" qualifier has two different meanings depending on the context it appears.
Used in a parameter-list the consequences are: the parameter will not be modified by a direct assignment.
Used in a variable declaration and followed by an initialization the variable will be put into the code area which will be flash memory in all embeddeds.
This improvement is not ARM specific but works in GCC generally.
Thanks Bob and Dana for your inputs.
Just to share the my test results. So the objective I have now is to skip the assignment of the Start and End address of the ROM (refer to my earlier post), and to use the CyFlashWriteRow() function to write to the flash in PRoC. To read, I simply use the pointer and to avoid the 'integer to pointer error', I choose to increment the address value in the pointer instead of direct assignment.
I'm sharing my code here for any future references or anyone who has a simliar problem as I did.
main17.c.zip 773 bytes
thank you for sharing your experiences with us!