[SOLVED] JLinkGDBServer FreeRTOS ThreadAwareness and configMAX_PRIORITIES

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

  • [SOLVED] JLinkGDBServer FreeRTOS ThreadAwareness and configMAX_PRIORITIES

    Hi,

    I am wondering what the limit is in the FreeRTOS plugin relating to the number of thread priorities. This is set by configMAX_PRIORITIES in FreeRTOS.

    I am experiencing the limit and was not able to debug using this plugin until I reduced the max priorities to 17.

    Thanks
    Alex.
  • Hi Alex,

    the plugin has an internal limit of a maximum of 63 priorities.

    Defines cannot be read by the GDB server, so it needs to rely on symbol base addresses. At first, it tries to read the symbol uxTopUsedPriority. As this symbol no longer exists in recent versions of FreeRTOS, it tries to use uxTopReadyPriority instead. Unfortunately this variable is treated in a different way, if configUSE_PORT_OPTIMISED_TASK_SELECTION is set to 1, so it does not work in this case and we cannot provide a plugin which runs out of the box with any configuration.

    We recommend to reintroduce the symbol uxTopUsedPriority:
    github.com/gnuarmeclipse/openo…elpers/FreeRTOS-openocd.c

    Regards
    Arne
    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.