Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

extract SDP_WRITE_ADDR (_fcfb_origin) and SDP_JUMP_ADDR (_ivt_origin) from linker file #174

Merged
merged 1 commit into from
Dec 27, 2021

Conversation

hathach
Copy link
Member

@hathach hathach commented Dec 25, 2021

  • use sed to extract SDP_WRITE_ADDR (_fcfb_origin) and SDP_JUMP_ADDR (_ivt_origin) from linker file.
  • This helps to reduce the amount of manual work and magic number should we make changes to linker file.

@hathach hathach merged commit 1d86a83 into master Dec 27, 2021
@hathach hathach deleted the rt10xx-sdp-addr branch December 27, 2021 06:18
@nxf58843
Copy link
Collaborator

Sorry for the delayed response. There are some issues with this update. The image runs after loaded but does not run from flash (RT1010 EVK). Let me try to clean this up. This PR should probably be reverted.

@nxf58843
Copy link
Collaborator

I think it would also be good to switch to spsdk (https://pypi.org/project/spsdk/) for loading, then we do not need to keep the sdphost binaries. They can load it separately like pyocd.

@hathach
Copy link
Member Author

hathach commented Dec 29, 2021

Sorry for the delayed response. There are some issues with this update. The image runs after loaded but does not run from flash (RT1010 EVK). Let me try to clean this up. This PR should probably be reverted.

Not a problem at all, I tested with rt1010 evk and seems to work well. This PR essentially does not make any changes in the compile binary. It only add the sed script to extract the _fcfb_origin and _ivt_origin from the linker file. Which OS you are using, I haven't tested on windows, maybe adding this line to makefile to check if sed does its work correctly

$(error Write: $(SDP_WRITE_ADDR) Jump: $(SDP_JUMP_ADDR) )

I think it would also be good to switch to spsdk (https://pypi.org/project/spsdk/) for loading, then we do not need to keep the sdphost binaries. They can load it separately like pyocd.

Yeah, I agree, we could switch to spsdk in the future. If possible, please make an PR for it. I could do it as well if you don't have time.

@gsteiert
Copy link
Collaborator

I forgot that the RT1010 does not fit with debug logs enabled. I think that was my problem. It is working for me now. I will submit a pull request with the SPSDK update. It is mostly documentation, let me know if anything is unclear.

@hathach
Copy link
Member Author

hathach commented Dec 30, 2021

thank you for confirmation :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants