使用vtaskList&带有ESP32,Platformio和Arduino框架的VtaskGetruntMeStats()

发布于 2025-01-27 19:49:34 字数 263 浏览 7 评论 0原文

我想使用 vtaskList & vtaskgetruntimestats()在带有Platformio和Arduino框架的ESP-32上,但会获得“未定义的参考”错误。

如果您使用Google,您会发现许多提示是(或未实现),即您应该更改Espressif IDE(我不使用)中的某些设置,并链接到无处可寻的重新编译指令。

最近有任何解决方案或说明吗? 另外,是否还有其他解决方案可以列出所有任务及其处理器使用情况(尤其是空闲任务)?

I`d like to use vTaskList & vTaskGetRunTimeStats() on an ESP-32 with PlatformIO and Arduino framework, but get an "undefined reference" error.

If you use google, you will find many hints that it is, or is not (yet) implemented, that you should change some settings in the Espressif IDE (which I don't use) and links to recompile instructions that lead nowhere.

Are there any recent solutions or instructions for this?
Alternatively, are there other solutions to list all tasks and their processor usage (especially IDLE tasks)?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

怎言笑 2025-02-03 19:49:34

您想发布代码和特定错误消息,以获得任何有意义的帮助。

在这种情况下,当您在 functions 您会发现
在此API可用之前,必须在Freertos中明确启用运行时统计数据。

使用Espressif ESP-IDF构建配置(通过调用命令idf.py menuconfig或通过手动编辑文件sdkconfig)由config option option option copear> config> config_freertos_generate_generate_run_run_time_stats_stats_stats_stats_stats_stats _。因此,sdkconfig中会有类似的东西

#
# FreeRTOS
#

...

CONFIG_FREERTOS_GENERATE_RUN_TIME_STATS=y
CONFIG_FREERTOS_RUN_TIME_STATS_USING_ESP_TIMER=y

...

You want to post your code and specific error messages to get any meaningful help.

In this case when you read the documentation on both functions you will discover that
runtime stats must be explicitly enabled in FreeRTOS before this API becomes available.

When using the Espressif ESP-IDF build configuration (either by invoking the command idf.py menuconfig or by manually editing file sdkconfig) this is set by config option CONFIG_FREERTOS_GENERATE_RUN_TIME_STATS. So there would be something like this in sdkconfig

#
# FreeRTOS
#

...

CONFIG_FREERTOS_GENERATE_RUN_TIME_STATS=y
CONFIG_FREERTOS_RUN_TIME_STATS_USING_ESP_TIMER=y

...

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文