feat(efuse): Support efuse token dump

- efuse token dump is compatible with espefuse tool
- EFSW dump can be burned on chip with esp_efuse_token_burn()
This commit is contained in:
Konstantin Kondrashov
2026-06-03 13:19:59 +03:00
parent d4c8d211e1
commit 885097762f
31 changed files with 1844 additions and 65 deletions
@@ -361,6 +361,46 @@ GDBStub 支持在运行时进行调试。GDBStub 在目标上运行,并通过
有关配置文件的更多详细信息,请参阅 `IDF 监视器文档`_。
主机侧命令标记
==============
当设备日志行以支持的标记开头时,IDF 监视器可以执行主机侧辅助命令。
对于 eFuse token 解码,可在固件日志中输出以下任一格式:
* ``IDF_MONITOR_EXECUTE_ESPEFUSE_SUMMARY <TOKEN> [附加参数]``
* ``IDF_MONITOR_EXECUTE_ESPEFUSE_DUMP <TOKEN>``
检测到标记后,监视器会在主机侧调用 ``espefuse``,并以内联方式打印解码结果。
示例 1(带自定义表的 summary):
.. code-block:: text
I (441) app: IDF_MONITOR_EXECUTE_ESPEFUSE_SUMMARY EFSR:esp32c3:100:... --extend-efuse-table main/esp_efuse_custom_table.csv
该日志行会触发等价于以下命令的主机侧执行:
.. code-block:: text
espefuse --token EFSR:esp32c3:100:... --extend-efuse-table main/esp_efuse_custom_table.csv summary --active
示例 2(原始转储):
.. code-block:: text
I (442) app: IDF_MONITOR_EXECUTE_ESPEFUSE_DUMP EFSR:esp32c3:100:...
该日志行会触发等价于以下命令的主机侧执行:
.. code-block:: text
espefuse --token EFSR:esp32c3:100:... dump
.. important::
请将 token 参数视为敏感数据(尤其是 ``EFSW``/``EFSRW``),因为它们可能在这些值仍处于暂存状态、尚未烧写、也尚未受读保护时,以明文暴露密钥值。关于 token 格式和生成 API,请参见 :doc:`eFuse 管理器 <../../api-reference/system/efuse>`。
IDF 监视器已知问题
=================================