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

nrf5340 support #1656

Open
wants to merge 2 commits into
base: main
Choose a base branch
from
Open

nrf5340 support #1656

wants to merge 2 commits into from

Conversation

maxd-nordic
Copy link
Contributor

Adds support for the nrf5340


def __init__(self, session):
super(NRF53XX, self).__init__(session, self.MEMORY_MAP)
self._svd_location = SVDFile.from_builtin("nrf5340_application.svd") # TODO
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ideally, I would load both SVD for the specific cores. But how to do this? (seems not that important though)

@maxd-nordic
Copy link
Contributor Author

Still got a problem to solve here: Flashing works after a mass-erase. If there is already a program on the chip, it fails on the network core with a hard fault or something similar:
0008375 C target was not halted as expected after calling flash algorithm routine (IPSR=3) [__main__]

@maxd-nordic
Copy link
Contributor Author

@flit Could you take a look? I'll try to understand the flash algo code (they are from the pack), maybe I can find something.

@mrenner42
Copy link

Hi @maxd-nordic
I tried your PR and flashing after an mass-erase works almost as expected.
Unfortunately, I get the following error when flashing the appcore:

0012682 C flash program page failure (address 0x00ff8000; result code 0x68) [__main__]

Seems like flashing UICR fails with decimal value of 104 in register r0. Any idea what causes this result code?

@maxd-nordic
Copy link
Contributor Author

Hi @mrenner42! Cool, that you're interested in this! Unfortunately, I've run into similar issues and couldn't figure out how to fix them yet. Maybe, I'll try building a simpler flash algo and see if that does the trick. IIRC, I had one version that only worked on a freshly erase chip and another that only worked on an already programmed one.

Signed-off-by: Maximilian Deubel <maximilian.deubel@nordicsemi.no>
Signed-off-by: Maximilian Deubel <maximilian.deubel@nordicsemi.no>
@maxd-nordic maxd-nordic changed the base branch from develop to main November 19, 2024 14:43
@maxd-nordic maxd-nordic marked this pull request as ready for review November 19, 2024 14:43
@maxd-nordic maxd-nordic changed the title WIP: nrf5340 support nrf5340 support Nov 19, 2024
@maxd-nordic
Copy link
Contributor Author

@mrenner42 Would you like to try the latest version? It seems promising to me!

@mrenner42
Copy link

@maxd-nordic Very cool, thanks a lot. I'll give it a go this week and report back!

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.

2 participants