Configure J-Flash Project

  • Configure J-Flash Project

    Hi there,

    At our company we use J-Flash projects to program certain products with the STM32 chip on it. We've created for each product a separate project file and a hex file. The problem I stumble upon is that when I double-click a project it opens J-Flash ARM. I would expect that J-Flash ARM opens the selected project but it will not. It opens the last project I've opened in J-Flash ARM. If I open the J-Flash project in a text editor like Notepad it does show a value 'CurrentFile' and it is set to the correct hex file.

    My question is:

    Can i set up J-Flash ARM that it will open the project I double-click. And if it does so, also open the correct hex file (CurrentFile).

    Robert Veringa
  • Hi Robert,

    When opening a project in J-Flash, the file indicated by "CurrentFile" in the project, will be opened.
    When double-clicking a project file, it should open in J-Flash and the same operation should be performed.
    We will check this and provide feedback.


    Best regards
    Alex
    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.
  • Hello Robert,

    We had a look into it and can confirm the behavior you are seeing.

    Double-clicking a J-Flash project to open it is the same as calling J-Flash with the command line option "-openprj".
    In both cases only the project file, but not the data file will be opened.
    The data file which might be open after the start of J-Flash comes from the last opened project,
    which gets loaded before opening the project file passed via command line option.

    We will discuss internally if we change the behavior for the case of directly opening a J-Flash project to also open the data file assigned to it.

    As a workaround you could use the command line options for J-Flash and create a batch file for the project and the data file like this:

    Source Code

    1. @ECHO OFF
    2. ECHO Start J-Flash and open a project and data file
    3. start "J-Flash" "JFlashARM.exe" -openprjC:\Projects\Project.jflash -openC:\Data\data.bin,0x100000
    4. IF ERRORLEVEL 1 pause



    Best regards
    Johannes
    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.
  • We had a second look and opening a J-Flash project via double-click,
    as well as command line option "-openprj",
    behave as you were expecting with the current version of J-Flash.
    The project and the data file will be opened.

    What might cause the problem
    is a wrong shell open command in the registry, referring to an older version of J-Flash,
    which will unfortunately not be overridden, when selecting the newest version of J-Flash in the "Open with..." dialog.

    To verify this, could you please double-click on a J-Flash project and check which version of J-Flash will be opened?
    (Written in the title bar or at Help->About...)


    Best regards,
    Johannes
    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.
  • We have different versions installed on several computers. This is the behaviour for the specific versions:

    v4.14b/v4.52a:
    - Open Project a by double-click.
    - Project will be opened with .hex file last opened in J-Flash ARM.
    - Close J-Flash ARM.
    - Open Project b by double-click.
    - Project will be opened with .hex file of project a.
    - Close J-Flash ARM.
    - Open Project b again by double-click.
    - Project will be opened with .hex file of project b.

    v4.74a:

    - Open Project a by double-click.
    - Project will be opened with .hex file last opened in J-Flash ARM.
    - On top of the last opened .hex file it will load the .hex file of project a.
    - Close J-Flash ARM.
    - Open Project b by double-click.
    - Project will be opened with .hex file of project a.
    - On top of the last opened .hex file it will load the .hex file of project b.

    - Close J-Flash ARM.
    - Open Project b again by double-click.
    - Project will be opened with .hex file of project b.
    - On top of the last opened .hex file it will load the .hex file of project b again. So now the .hex file is opened twice in the project.


    Thanks for taking time to give support.

    Regards,

    Robert Veringa
  • Hello Robert,

    We always recommend to use the newest version.
    It shows the behavior you wish to have. Or did I get your initial question wrong?

    In J-Flash you can be sure the top-most hex file is the active one,
    so no need to worry about the ones below it, they were opened with the projects loaded before the active one.
    Anyhow, we might change J-Flash to also close the data files when a project is closed.

    Best regards,
    Johannes
    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.
  • Johannes,

    Yes, this was the answer on my initial question. However it would be nice if the last loaded file will also close.
    How will I know if this is changed in a future J-Flash version? Is there a way you might send me a private message or another comment on this post?

    Best regards,

    Robert Veringa
  • We can add you to the J-Link software notification list.
    Shall we add the e-mail address from your forum profile
    or would you like to be added with another one?

    Best regards,
    Johannes
    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.