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

🪲[BUG] pico_multicore always linked in Pico-PIO-USB library even when multicore functionality isn’t needed #146

Open
abv opened this issue Oct 11, 2024 · 1 comment
Labels
bug Something isn't working

Comments

@abv
Copy link

abv commented Oct 11, 2024

Describe the bug you encountered:

The pico_multicore library is always linked to the Pico-PIO-USB library in CMakeLists.txt, even if multicore functionality is not required by the project. This causes unnecessary complications, especially in projects where flash operations require the system to avoid the complexities of multicore execution. As far as I can tell, while pico_multicore is used in some of the examples, it is not needed for the library to build, and can be left out of CMakeLists.txt. If I'm wrong and it is needed, I'd love to know why. I'm new to the pico and microcontrollers in general and am trying to learn as much as possible by understanding the code of my project's dependencies.

What did you expect to happen instead?

In my case, I ran into an issue where pico_flash_bank_write() from the pico-sdk failed simply from the inclusion of pico_multicore. I expected this write operation to work.

What actually happened in your case?

Flash operations did not work until I either commented out pico_multicore or added PICO_FLASH_ASSUME_CORE1_SAFE=1

Additional information

Environment details:

•	Platform: Raspberry Pi Pico W
•	SDK: Pico SDK 2.0
•	Libraries used: Pico-PIO-USB 0.6.1, TinyUSB, BTstack, etc.

@abv abv added the bug Something isn't working label Oct 11, 2024
@kbladewht
Copy link

I meet similar issue with you ,but I do need mul-core, but I don't understand why using core1 but flash didn't work to me.
I used qmk environment, is there a way to allow flash write ? btw, in qmk library there is not [PICO_FLASH_ASSUME_CORE1_SAFE=1 found here

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants