arduino-esp32 icon indicating copy to clipboard operation
arduino-esp32 copied to clipboard

Support for vTaskList() in Arduino core so we can monitor task status

Open osamahnini opened this issue 2 years ago • 14 comments

Related area

FreeRTOS

Hardware specification

All esp32 devices

Is your feature request related to a problem?

No

Describe the solution you'd like

Current when you use vTaskList() FreeRTOS API and try to compile, you get this error: "undefined reference". The runtime stats must be enabled in FreeRTOS so you can use this API. I think the solution is to enable runtime stats by default.

Describe alternatives you've considered

No response

Additional context

No response

I have checked existing list of Feature requests and the Contribution Guide

  • [X] I confirm I have checked existing list of Feature requests and Contribution Guide.

osamahnini avatar Aug 24 '22 17:08 osamahnini

We need to check if this will cause any performance/memory degradation first.

me-no-dev avatar Aug 25 '22 09:08 me-no-dev

If can view the cpu usage, is very useful for debugging, hope to support this function. But performance degradation also needs attention,hopefully as an option that can be on/off at compile time.

qnxsgwy avatar Sep 08 '22 10:09 qnxsgwy

Well, I'm no stranger to squeezing performance out of the ESP32 and I use it by default on my projects. 48kHz stereo realtime MP3 encoder: https://www.esp32.com/viewtopic.php?f=2&t=9186 Using it to gauge performance really didn't notice any issues at all. I think there is certainly more benefit than potential issues. Also Arduino being something that is also used as a learning tool, it would be extremely beneficial to allow users to see tasks usage and CPU affinity. Happy to add an example if it's added. This applies to vTaskList & vTaskGetRunTimeStats(). This keeps coming up here as a feature request by different people, it's probably not going away...

fknrdcls avatar Sep 09 '22 20:09 fknrdcls

I too would very much appreciate this support in the Arudino variant... just hit this omission myself!

davepl avatar Sep 16 '22 16:09 davepl

+1

zekageri avatar Sep 20 '22 07:09 zekageri

+1, I would also need that feature in my project

szerwi avatar Nov 01 '22 10:11 szerwi

me 2

everslick avatar Nov 23 '22 11:11 everslick

also need this feature and vTaskGetRunTimeStats() :-)

yekomS avatar Dec 04 '22 21:12 yekomS

so any new info on this? I would need it too, or maybe some way to recompile the lib ourself with the feature enabled?

marnov999 avatar Dec 31 '22 15:12 marnov999

I wound up making my own idle threads that whack the watchdog and track whatever idle cycles they can burn, and that gives me overall CPU, but not per-task…

From: marnov999 @.> Sent: Saturday, December 31, 2022 7:13 AM To: espressif/arduino-esp32 @.> Cc: David W Plummer @.>; Comment @.> Subject: Re: [espressif/arduino-esp32] Support for vTaskList() in Arduino core so we can monitor task status (Issue #7179)

so any new info on this? I would need it too, or maybe some way to recompile the lib ourself with the feature enabled?

— Reply to this email directly, view it on GitHub https://github.com/espressif/arduino-esp32/issues/7179#issuecomment-1368239968 , or unsubscribe https://github.com/notifications/unsubscribe-auth/AA4HCFY4I4WS5YEWSOCXQWLWQBERLANCNFSM57QGGJKQ . You are receiving this because you commented. https://github.com/notifications/beacon/AA4HCF25GZ4NDDG2NGLBPX3WQBERLA5CNFSM57QGGJK2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOKGG26YA.gif Message ID: @.*** @.***> >

davepl avatar Dec 31 '22 19:12 davepl

Yeah defo missing this too, just started using RTOS tasks, and need a way to list and monitor them. This looks like just the ticket.

bobemoe avatar Feb 22 '23 19:02 bobemoe

All, this has been discussed all over the internet for quite a while now, we should get it :)

synologic avatar Jun 24 '23 08:06 synologic

Hello all, changing this to 3.1.0 milestone, we are starting investigating if this is doable and let you know.

@lucasssvaz will do the research and share the updates later here.

VojtechBartoska avatar Feb 07 '24 13:02 VojtechBartoska

We'll first need to implement some way to easily reconfigure and recompile the libs for the users. Currently working on that. https://github.com/espressif/esp32-arduino-lib-builder/pull/158

lucasssvaz avatar Feb 20 '24 13:02 lucasssvaz