Skip to content

ESP32-S3: Move PSRAM functions to RAM #546

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

Merged
merged 2 commits into from
May 17, 2023

Conversation

bjoernQ
Copy link
Contributor

@bjoernQ bjoernQ commented May 17, 2023

This moves functions dealing with PSRAM into RAM

@MabezDev
Copy link
Member

Is there a reason why this is needed?

@bjoernQ
Copy link
Contributor Author

bjoernQ commented May 17, 2023

It fixes one of the problems Juraj M. ran into with the spooky-maze example.
I think what happened there was that while we reconfigure SPI1 and SPI0 the code we called was not in the current cache-page but reading from flash wasn't possible in that moment (because we are reconfiguring the SPIs). I haven't checked my theory but it explains why the example works while in Juraj's code it crashed. At least moving one of the functions to RAM fixed that and just to be on the safe side I decided to put everything up the call-tree to RAM. Then there wasn't much left so I also moved the remaining functions to RAM

Copy link
Member

@MabezDev MabezDev left a comment

Choose a reason for hiding this comment

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

I see, that makes sense! LGTM!

@bjoernQ bjoernQ merged commit 3be64df into esp-rs:main May 17, 2023
@bjoernQ bjoernQ deleted the esp32s3-move-psram-functions-to-ram branch May 17, 2023 13:37
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