[SOLVED] SES Initializing QSPI on STM32F7

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

  • [SOLVED] SES Initializing QSPI on STM32F7

    Hello there,

    Let suggest that we have QSPI on an STM32F7 disco board and the code is developed in SES. If we initialize the QSPI as memory mapped and we use:

    C Source Code

    1. __attribute__ ((section (".textqspi")));


    to store an array in the QSPI, is there a way with SES to automatically download the data from the elf file to QSPI when running the build? I assume that there is correct flash placement XML file with

    Source Code

    1. <ProgramSection alignment="4" load="Yes" name=".textqspi" />


    To be more clear, is there a way to configure SES to do that or I have to use J-Flash with the loader program and data for QSPI?

    Thank you in advance,
    Victor
  • Hello Victor,

    The whole programming aspect of ES is handled by the J-Link DLL.
    Currently you will need to use a flash loader to program the QSPI on the discovery board.
    For that you can use our open flash loader interface.
    A example project can be found here: wiki.segger.com/STM32F746_Discovery

    But we are planning to release out-of-the-box QPSI support for the STM32F7 discovery board so you don't need to write any additional flash loaders.
    It will be released in the next couple of weeks.
    Keep in mind that only the "default" QSPI Flash that is on the discovery board will be supported out of the box.

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

    Thank you for the information above. I think I understand the aspect of ES interfacing the J-Link DLL. Is there a way if the flash loader is configured with the J-link and JLinkDevices.xml, to configure SES to execute this flash loader for QSPI when downloading the code to the target (together with the internal flash)? Furthermore, the data for the QSPI, for example, is stored inside the C code in .textqspi section instead of hex or other formats.

    I don't know if I explained myself very well. Please, let me know if something is unclear.

    Thank you.
    Victor
  • Hello Victor,

    Is there a way if the flash loader is configured with the J-link and JLinkDevices.xml, to configure SES to execute this flash loader for QSPI when downloading the code to the target (together with the internal flash)? Furthermore, the data for the QSPI, for example, is stored inside the C code in .textqspi section instead of hex or other formats.


    This is possible. A in depth tutorial can be found here.
    You have basically two options here. Either add the QSPI support yourself as described in the Wiki articles or wait for us to implement it in the next couple of releases.
    Either way to make sure ES is using the DLL with the flash loader you will need to rename (or remove) the J-Link DLL in the ES installation directory.
    It can be found under the following path: $(ESInstallPath)\bin
    Depending on the OS you are using (32- bit or 64- bit) the DLL is called "JLinkARM.dll" or "JLink_x64.dll". Simply rename that file to e.g. "JLink_x64.dll.bak".
    Then ES will use the latest J-Link Software Package that is installed on your computer instead. If you have added the QSPI flash loader to that package you can now program the QPSI Flash with Embedded Studio as you described.


    EDIT: Pardon, the crossed out information is not 100% correct/necessary. To be able to use the latest added devices (including QSPI support) all you need to do download the latest J-Link Software and Documentation Pack and let the J-Link DLL updater update the DLL in the ES installation folder.

    Best regards,
    Nino
    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 Victor,

    You are welcome.
    I will consider this thread as solved now.

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