From 1d40eb8ce3d73a9650121c0815184fbb26afcd13 Mon Sep 17 00:00:00 2001 From: Fu Hanxi Date: Thu, 1 Aug 2024 13:29:09 +0200 Subject: [PATCH] docs: fix found warnings and errors by rstfmt --- docs/en/api-guides/flash_psram_config.rst | 2 +- docs/en/api-reference/system/pthread.rst | 1 + docs/zh_CN/api-guides/flash_psram_config.rst | 2 +- docs/zh_CN/api-reference/system/pthread.rst | 1 + 4 files changed, 4 insertions(+), 2 deletions(-) diff --git a/docs/en/api-guides/flash_psram_config.rst b/docs/en/api-guides/flash_psram_config.rst index 77f801113b..bc4103cd93 100644 --- a/docs/en/api-guides/flash_psram_config.rst +++ b/docs/en/api-guides/flash_psram_config.rst @@ -259,7 +259,7 @@ Error Handling Here is a method to burn the eFuse bit: -.. code-block:: python +.. code-block:: shell idf.py -p PORT efuse-burn --do-not-confirm FLASH_TYPE 1 diff --git a/docs/en/api-reference/system/pthread.rst b/docs/en/api-reference/system/pthread.rst index 9073b93e5b..f78a8fbe6e 100644 --- a/docs/en/api-reference/system/pthread.rst +++ b/docs/en/api-reference/system/pthread.rst @@ -244,6 +244,7 @@ ESP-IDF Extensions The API :cpp:func:`esp_pthread_set_cfg` defined in the ``esp_pthreads.h`` header offers custom extensions to control how subsequent calls to ``pthread_create()`` behaves. Currently, the following configuration can be set: .. list:: + - Default stack size of new threads, if not specified when calling ``pthread_create()`` (overrides :ref:`CONFIG_PTHREAD_TASK_STACK_SIZE_DEFAULT`). - Stack memory capabilities determine which kind of memory is used for allocating pthread stacks. The field takes ESP-IDF heap capability flags, as defined in :component_file:`heap/include/esp_heap_caps.h`. The memory must be 8-bit accessible (MALLOC_CAP_8BIT), besides other custom flags the user can choose from. The user is responsible for ensuring the correctness of the stack memory capabilities. For more information about memory locations, refer to the documentation of :ref:`memory_capabilities`. - RTOS priority of new threads (overrides :ref:`CONFIG_PTHREAD_TASK_PRIO_DEFAULT`). diff --git a/docs/zh_CN/api-guides/flash_psram_config.rst b/docs/zh_CN/api-guides/flash_psram_config.rst index 358e16e111..d121056091 100644 --- a/docs/zh_CN/api-guides/flash_psram_config.rst +++ b/docs/zh_CN/api-guides/flash_psram_config.rst @@ -259,7 +259,7 @@ F4R4 硬件 以下是烧录 eFuse 位的方法: -.. code-block:: python +.. code-block:: shell idf.py -p PORT efuse-burn --do-not-confirm FLASH_TYPE 1 diff --git a/docs/zh_CN/api-reference/system/pthread.rst b/docs/zh_CN/api-reference/system/pthread.rst index 0f39db1b30..218c647ec2 100644 --- a/docs/zh_CN/api-reference/system/pthread.rst +++ b/docs/zh_CN/api-reference/system/pthread.rst @@ -187,6 +187,7 @@ ESP-IDF 扩展 在 ``esp_pthreads.h`` 头文件中定义的 API :cpp:func:`esp_pthread_set_cfg` 提供了自定义扩展,能够对后续 ``pthread_create()`` 的调用行为进行控制。目前提供以下配置: .. list:: + - 如果调用 ``pthread_create()`` 时未指定默认堆栈大小,可设置新线程的默认堆栈大小(覆盖 :ref:`CONFIG_PTHREAD_TASK_STACK_SIZE_DEFAULT`)。 - 堆栈内存属性决定用于分配 pthread 堆栈的内存类型。该字段使用 ESP-IDF 堆属性标志,这一标志在 :component_file:`heap/include/esp_heap_caps.h` 文件中定义。为了确保分配的内存能够通过 8 位地址访问 (MALLOC_CAP_8BIT),用户必须设置相应的标志,此外也可添加其他自定义标志。用户应当确保选择了正确的堆栈内存属性。了解内存位置的更多信息,请参考 :ref:`memory_capabilities` 文档。 - 新线程的 RTOS 优先级(覆盖 :ref:`CONFIG_PTHREAD_TASK_PRIO_DEFAULT`)。