Erasing A Sector That Isn't In .bin File Via Command-Line

This site uses cookies. By continuing to browse this site, you are agreeing to our Cookie Policy.

  • Erasing A Sector That Isn't In .bin File Via Command-Line

    Chip: STM32H753VI
    Flasher hardware: JLink Plus
    JFlash version: v6.54 (for compatibility reasons)

    .bin file writes from 0x08000000 to 0x0806C580

    I can flash the chip successfully by calling J-Flash from the command line.

    However, I need to wipe the sector at 0x080E0000 - 0x080FFFFF which is above the last address in the .bin file.

    I have tried using -delrange0x080E0000,0x080FFFFF both by itself and with the project and bin files specified.
    The command seems to be ignored by JFlash.

    I did also try -erasechip, which would work, except that it takes too long to be done with each device we program in production.

    My question is this: does -delrange only work for ranges specified in the data (.bin, .hex, etc.) file? If this is the case, should I have
    my engineers create a data file that covers the appropriate range I need to delete? Is there another way to accomplish this besides
    -erasechip?
  • Hello,

    The -delrange command only affects the data file and not the chip itself.

    To delete only a specific sector via the J-Flash command line application, follow these steps:
    1. Select the sectors in the J-Flash GUI application (currently not possible via commands). J-Flash Flash Settings
    2. Save the project.
    3. Open the project via the J-Flash command line application with -openprj <FILENAME>.
    4. Use the -erasesectors command.Only the previously selected sectors are erased.
    For more details, please refer to the J-Flash Command Line Options.

    Best regards,
    Simon
    Please read the forum rules before posting.

    Keep in mind, this is *not* a support forum.
    Our engineers will try to answer your questions between their projects if possible but this can be delayed by longer periods of time.
    Should you be entitled to support you can contact us via our support system: segger.com/ticket/

    Or you can contact us via e-mail.