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

RP2350 - Upload to and run from SRAM not working #110

Open
ChristianIvarsson opened this issue Sep 7, 2024 · 3 comments
Open

RP2350 - Upload to and run from SRAM not working #110

ChristianIvarsson opened this issue Sep 7, 2024 · 3 comments

Comments

@ChristianIvarsson
Copy link

Hi!

It has previously been possible to upload to and run from SRAM on the older rp2040 but it seems no longer possible on the new sibling.

Is there any planned support in the pipeline or would it be better if init were performed by the script itself?

Expected working configuration:

<CMakeLists.txt>
add_compile_definitions(PICO_NO_FLASH=1)
.. ..
pico_set_binary_type(${PROJECT_NAME} no_flash)

<ramload.cfg>
source [find interface/cmsis-dap.cfg]
adapter speed 4000
source [find target/rp2350.cfg]

transport select swd
init
reset halt

load_image image.elf
resume 0x20000000
shutdown

~I'm really sorry if this is a PEBCAK

@ChristianIvarsson
Copy link
Author

Did a test on the built elf just to verify and it seems the sdk does what it should
arm-none-eabi-size -A -x yields

section                  size         addr
.text                  0x5338   0x20000000
.rodata                 0x410   0x20005338
.binary_info             0x1c   0x20005748
.data                   0x218   0x20005770
.tdata                    0x0   0x20005988
.uninitialized_data       0x0   0x20005988
.tbss                     0x0   0x20005988
.bss                    0x54c   0x20005988
.heap                 0x3a12c   0x20005ed4
.. ..

Also tried openocd on a pi through its gpio interface and it was the same result there.

@lurch
Copy link

lurch commented Sep 18, 2024

This might be related to raspberrypi/pico-feedback#153 ? 🤷‍♂️

@ChristianIvarsson
Copy link
Author

This might be related to raspberrypi/pico-feedback#153 ? 🤷‍♂️
( I must sort out my mail situation. I'm really sorry for such a late reply )

It's at the very least VERY closely related. Think they only differ in that I want to start and instantly let go of the target instead of attaching a debugger. Everything up to that point ought to have the same requirements.

I'll see if I can create some test cases to verify if it's just me doing something weird (most likely) or if it's currently not possible to debug and/or run from sram.

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

No branches or pull requests

2 participants