Disable Sections of Flash Download with Jlink

Sysprogs forums Forums VisualGDB Disable Sections of Flash Download with Jlink

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #32745
    Lucas Rolfes
    Participant

    Hi Forum,

     

    I was hoping to get some information on how to hopefully disable a region of flash download / comparison for my external flash.

    I was able to get a flash loader working for my setup, which happens to be on an STM32H7, with the starting address at 0x90000000, and everytime I now attempt to debug, I get my JLink to attempt to download / validate those addresses. I am hoping to get rid of this step wholesale and am looking for ideas on what to try  as it takes significant amounts of time to do this step.

    Attaching a screenshot of the exact thing I am looking to avoid, as you can see the process was not even 1% in for the comparison, and already taking 3 seconds so it would take a while for the whole external flash.

     

    Thanks,

    Lucas

     

    Attachments:
    You must be logged in to view attached files.
    #32751
    support
    Keymaster

    Hi,

    VisualGDB itself doesn’t have any special GUI for discarding individual sections, however you might be able to get it working as outlined below:

    1. Completely disable FLASH loading on the VisualGDB side.
    2. Use the objcopy tool from your toolchain to discard individual sections from the ELF file (see binutils documentation) and save the result separately.
    3. Manually configure gdb to use one image for debugging, and another image for actually loading into the target . Then manually load the second image into the target. See GDB documentation for the specific commands to use.

    You can configure VisualGDB to run objcopy after the build via VisualGDB Project Properties -> Custom Build Steps, and to issue additional commands to GDB via VisualGDB Project Properties -> Additional GDB commands.

Viewing 2 posts - 1 through 2 (of 2 total)
  • You must be logged in to reply to this topic.