Hello,
I am currently on idf v5.4.1. As I was browsing the official FreeRTOS reference, I found 2 very similar functions that I need for my project:
1. ulTaskGetRunTimeCounter(xTasjk)
2. ulTaskGetIdleRunTimeCounter()
It appear they are doing the same thing: getting the cpu ticks utilized by a task : in case /1/ xTask is passed, ther task handle of the task we need to measure, and /2/ the 2 IDLE tasks are qquried , summed and returned.
For a reason that I can't understand, it appeard that /1/ is only available with SMP enabled (feat FREERTOS_SMP), but /2/ is available in all cases.
Am I missing something? Is there a reason for this?
Regards,
Alex
API issue : ulTaskGetRunTimeCounter scope
-
Alekos2313
- Posts: 14
- Joined: Sat Mar 03, 2018 12:33 pm
-
MicroController
- Posts: 2705
- Joined: Mon Oct 17, 2022 7:38 pm
- Location: Europe, Germany
Re: API issue : ulTaskGetRunTimeCounter scope
"SMP" FreeRTOS is actually a different variant of FreeRTOS than the IDF FreeRTOS (which is also SMP-capable). IDF FreeRTOS and Amazon "SMP" FreeRTOS may differ in API and functionality.For a reason that I can't understand, it appeard that /1/ is only available with SMP enabled (feat FREERTOS_SMP), but /2/ is available in all cases.
Am I missing something? Is there a reason for this?
-
Alekos2313
- Posts: 14
- Joined: Sat Mar 03, 2018 12:33 pm
Re: API issue : ulTaskGetRunTimeCounter scope
Hi, thanks!
I know all that, but my question still stands : Is there a reason for these functions to be only available in builds where "SMP / Amazon" feature is enabled ?
Regards
Alex
I know all that, but my question still stands : Is there a reason for these functions to be only available in builds where "SMP / Amazon" feature is enabled ?
Regards
Alex
-
MicroController
- Posts: 2705
- Joined: Mon Oct 17, 2022 7:38 pm
- Location: Europe, Germany
Re: API issue : ulTaskGetRunTimeCounter scope
The reason is that the Amazon FreeRTOS is a different OS and has different functionality/features than the IDF FreeRTOS, and
So the API is likely not yet stable, which implies it's likely that there are functions which are only present, i.e. new, in Amazon FreeRTOS, which may change before becoming part of the final Amazon FreeRTOS API, and may or may not be 'back-ported' to mainline/IDF FreeRTOS.The Amazon SMP FreeRTOS implementation (and its port in ESP-IDF) are currently in experimental/beta state.
Who is online
Users browsing this forum: Baidu [Spider], Bing [Bot], Google [Bot], Qwantbot and 2 guests