2017-02-01 07:15 AM
In the last CubeMX version (4.19) the USE_TICKLESS_IDLE option is missing. This disables the configUSE_TICKLESS_IDLE flag and the low power configuration.
Is it a bug? Is any workaround available?
PS: I've checked the 4.17 version and it has this option available. I don't have the 4.18, so I can't check it.
#cubemx #freertos #cubemx-4.19Solved! Go to Solution.
2017-02-02 05:40 AM
Hi,
It's a bug introduced with the support of FreeRTOS v9, to be fixed in the next version (sorry for that mistake).
As a temporary workaround (for 4.19), in the FREERTOS-v8.0.0_Cube_Modes.xml file (part of your CubeMx installation), you can modify the configUSE_TICKLESS_IDLE section (starting around line 814) as follows:
<RefParameter Name='configUSE_TICKLESS_IDLE' Comment='USE_TICKLESS_IDLE' DefaultValue='0' Type='list' Group='Kernel settings' TabName='Config parameters' Visible='true'><Condition Diagnostic='' Expression='(S_VERSION_8_2_1|S_VERSION_9_0_0) & INCLUDE_vTaskSuspend=1'/>
<PossibleValue Comment='Disabled' Value='0'/>
<PossibleValue Comment='Enabled' Value='1'/>
<Description>By setting the configUSE_TICKLESS_IDLE, the idle task suppresses ticks and the processor stays in a low power mode for as long as possible.<br>
When set to 1 (Enabled), two macros, configPRE_SLEEP_PROCESSING and configPOST_SLEEP_PROCESSING are generated in FreeRTOSConfig.h, and two empty functions, PreSleepProcessing and PostSleepProcessing generated in freertos.c (to be completed with user code).</Description>
</RefParameter>
<RefParameter Name='configUSE_TICKLESS_IDLE' Comment='USE_TICKLESS_IDLE' DefaultValue='0' Type='list' Group='Kernel settings' TabName='Config parameters' Visible='true'>
<Condition Diagnostic='Forced to 0 (Disabled) : cannot be enabled when INCLUDE_vTaskSuspend = 0 (Disabled)' Expression='(S_VERSION_8_2_1|S_VERSION_9_0_0) & INCLUDE_vTaskSuspend=0'/>
<PossibleValue Comment='Disabled' Value='0'/>
<Description>By setting the configUSE_TICKLESS_IDLE, the idle task suppresses ticks and the processor stays in a low power mode for as long as possible.</Description>
</RefParameter>
<RefParameter Name='configUSE_TICKLESS_IDLE' Comment='configUSE_TICKLESS_IDLE' DefaultValue='0' Type='integer' Group='Kernel settings' TabName='Config parameters' Visible='false'>
<Description>By setting the configUSE_TICKLESS_IDLE, the idle task suppresses ticks and the processor stays in a low power mode for as long as possible.</Description>
</RefParameter>
Should solve the issue in 4.19 (the parameter is available in both versions, v8 and v9, of FreeRTOS).As a reminder / for information, in CubeMx 4.19, FreeRTOS v9 is available on F3,F7,L0 series (porting on other series is on-going).
RegardsFred2017-02-01 08:52 AM
Hi
Pica.Aaron
,I will check this case and come back to you as soon as possible.
Regards
Imen
2017-02-02 03:55 AM
Dear User,
Please go the Config parameters tab.
In the Search field enter TICKLESS, you will be directly pointed to the USE_TICKLESS_IDLE parameter.
See attached snapshot.
________________ Attachments : FreeRTOS_UseTickless.png : https://st--c.eu10.content.force.com/sfc/dist/version/download/?oid=00Db0000000YtG6&ids=0680X000006Hyxm&d=%2Fa%2F0X0000000bET%2Faw2LTXhjjnIzs.32Xbwp82T55vKoaNxkMo3r9e98Bfc&asPdf=false2017-02-02 05:08 AM
Hi
Mondoloni.Pascal
,I'm sorry, but this is not true in the last version (4.19).
Are you using the last CubeMx version?
Thank you
2017-02-02 05:40 AM
Hi,
It's a bug introduced with the support of FreeRTOS v9, to be fixed in the next version (sorry for that mistake).
As a temporary workaround (for 4.19), in the FREERTOS-v8.0.0_Cube_Modes.xml file (part of your CubeMx installation), you can modify the configUSE_TICKLESS_IDLE section (starting around line 814) as follows:
<RefParameter Name='configUSE_TICKLESS_IDLE' Comment='USE_TICKLESS_IDLE' DefaultValue='0' Type='list' Group='Kernel settings' TabName='Config parameters' Visible='true'><Condition Diagnostic='' Expression='(S_VERSION_8_2_1|S_VERSION_9_0_0) & INCLUDE_vTaskSuspend=1'/>
<PossibleValue Comment='Disabled' Value='0'/>
<PossibleValue Comment='Enabled' Value='1'/>
<Description>By setting the configUSE_TICKLESS_IDLE, the idle task suppresses ticks and the processor stays in a low power mode for as long as possible.<br>
When set to 1 (Enabled), two macros, configPRE_SLEEP_PROCESSING and configPOST_SLEEP_PROCESSING are generated in FreeRTOSConfig.h, and two empty functions, PreSleepProcessing and PostSleepProcessing generated in freertos.c (to be completed with user code).</Description>
</RefParameter>
<RefParameter Name='configUSE_TICKLESS_IDLE' Comment='USE_TICKLESS_IDLE' DefaultValue='0' Type='list' Group='Kernel settings' TabName='Config parameters' Visible='true'>
<Condition Diagnostic='Forced to 0 (Disabled) : cannot be enabled when INCLUDE_vTaskSuspend = 0 (Disabled)' Expression='(S_VERSION_8_2_1|S_VERSION_9_0_0) & INCLUDE_vTaskSuspend=0'/>
<PossibleValue Comment='Disabled' Value='0'/>
<Description>By setting the configUSE_TICKLESS_IDLE, the idle task suppresses ticks and the processor stays in a low power mode for as long as possible.</Description>
</RefParameter>
<RefParameter Name='configUSE_TICKLESS_IDLE' Comment='configUSE_TICKLESS_IDLE' DefaultValue='0' Type='integer' Group='Kernel settings' TabName='Config parameters' Visible='false'>
<Description>By setting the configUSE_TICKLESS_IDLE, the idle task suppresses ticks and the processor stays in a low power mode for as long as possible.</Description>
</RefParameter>
Should solve the issue in 4.19 (the parameter is available in both versions, v8 and v9, of FreeRTOS).As a reminder / for information, in CubeMx 4.19, FreeRTOS v9 is available on F3,F7,L0 series (porting on other series is on-going).
RegardsFred2017-02-02 05:57 AM
Hi pica.aaron,
This is depends on FreeRTOS version and not CubeMx version:
USE_TICKLESS_IDLE flag is
available with FreeRTOS version 8.2.3, but not in FreeRTOS 9.0.0
2017-02-02 06:15 AM
Thank you
CRAISSON.FREDERIC
. I've edited the file (located on ...\STMicroelectronics\STM32Cube\STM32CubeMX\db\mcu\IP\ FREERTOS-v8.0.0_Cube_Modes.xml) as you explain and it worked well. I'm using a STM32F7 MCU.DAHMEN.IMEN
, please ensure of the reply before posting. Any misinterpretation can lead to big repercussions.2017-02-02 10:26 AM
Thank you
CRAISSON.FREDERIC
for your prompt answer/confirmation.Pica.Aaron
, sorry for thismisunderstanding. what I meant to say isthatthe bug
just appears withthe
version ofFreeRTOS v9.
Regards
Imen