mirror of
https://github.com/espressif/esp-idf.git
synced 2025-11-27 04:55:53 +00:00
docs: update application examples related to system
This commit is contained in:
@@ -192,6 +192,12 @@ Standard I/O streams (``stdin``, ``stdout``, ``stderr``) are mapped to file desc
|
||||
|
||||
Note that creating an eventfd with ``EFD_SUPPORT_ISR`` will cause interrupts to be temporarily disabled when reading, writing the file and during the beginning and the ending of the ``select()`` when this file is set.
|
||||
|
||||
Application Examples
|
||||
--------------------
|
||||
|
||||
- :example:`system/eventfd` demonstrates how to use ``eventfd()`` to collect events from tasks and ISRs in a ``select()`` based main loop, using two tasks and a timer ISR (interrupt service routine) callback.
|
||||
|
||||
- :example:`system/select` demonstrates how to use synchronous I/O multiplexing with the ``select()`` function, using UART and socket file descriptors, and configuring both to act as loopbacks to receive messages sent from other tasks.
|
||||
|
||||
API Reference
|
||||
-------------
|
||||
|
||||
@@ -14,6 +14,13 @@ Developers can use this library to send application specific state of execution
|
||||
2. Lightweight logging to the host, see :ref:`app_trace-logging-to-host`.
|
||||
3. System behaviour analysis, see :ref:`app_trace-system-behaviour-analysis-with-segger-systemview`.
|
||||
|
||||
Application Examples
|
||||
--------------------
|
||||
|
||||
- :example:`system/app_trace_to_plot` demonstrates how to use the Application Level Tracing Library to send and plot dummy sensor data to a host via JTAG, providing a faster alternative to logging via UART.
|
||||
|
||||
- :example:`system/app_trace_basic` demonstrates how to use the Application Level Tracing Library to log messages to a host via JTAG, providing a faster alternative to UART logs.
|
||||
|
||||
API Reference
|
||||
-------------
|
||||
|
||||
|
||||
@@ -566,5 +566,13 @@ Part of the functionality of this tool is also provided directly by ``idf.py`` c
|
||||
|
||||
.. include:: inc/espefuse_summary_{IDF_TARGET_NAME}.rst
|
||||
|
||||
Application Examples
|
||||
--------------------
|
||||
|
||||
- :example:`system/efuse` demonstrates how to use the eFuse API on {IDF_TARGET_NAME}, showing read and write operations with fields from the common and custom eFuse tables, and explaining the use of virtual eFuses for debugging purposes.
|
||||
|
||||
API Reference
|
||||
-------------
|
||||
|
||||
.. include-build-file:: inc/esp_efuse_chip.inc
|
||||
.. include-build-file:: inc/esp_efuse.inc
|
||||
|
||||
@@ -8,9 +8,6 @@ Overview
|
||||
|
||||
``esp_https_ota`` provides simplified APIs to perform firmware upgrades over HTTPS. It is an abstraction layer over the existing OTA APIs.
|
||||
|
||||
Application Example
|
||||
-------------------
|
||||
|
||||
.. code-block:: c
|
||||
|
||||
esp_err_t do_firmware_upgrade()
|
||||
@@ -56,15 +53,6 @@ Signature Verification
|
||||
|
||||
For additional security, signature of OTA firmware images can be verified. For more information, please refer to :ref:`secure-ota-updates`.
|
||||
|
||||
|
||||
Advanced APIs
|
||||
-------------
|
||||
|
||||
``esp_https_ota`` also provides advanced APIs which can be used if more information and control is needed during the OTA process.
|
||||
|
||||
Example that uses advanced ESP_HTTPS_OTA APIs: :example:`system/ota/advanced_https_ota`.
|
||||
|
||||
|
||||
.. _ota_updates_pre-encrypted-firmware:
|
||||
|
||||
OTA Upgrades with Pre-Encrypted Firmware
|
||||
@@ -94,14 +82,6 @@ This whole workflow is managed by an external component `esp_encrypted_image <ht
|
||||
.. note::
|
||||
The supported scheme is based on RSA-3072 and the private key on device side must be protected using platform security features.
|
||||
|
||||
Example
|
||||
^^^^^^^
|
||||
|
||||
To perform OTA upgrades with pre-encrypted firmware, please enable :ref:`CONFIG_ESP_HTTPS_OTA_DECRYPT_CB` in component menuconfig.
|
||||
|
||||
For detailed workflow and setup instructions, please refer to this example: :example:`system/ota/pre_encrypted_ota`.
|
||||
|
||||
|
||||
OTA System Events
|
||||
-----------------
|
||||
|
||||
@@ -163,6 +143,14 @@ Expected data type for different ESP HTTPS OTA events in the system event loop:
|
||||
- ESP_HTTPS_OTA_FINISH : ``NULL``
|
||||
- ESP_HTTPS_OTA_ABORT : ``NULL``
|
||||
|
||||
Application Examples
|
||||
--------------------
|
||||
|
||||
- :example:`system/ota/pre_encrypted_ota` demonstrates how to perform OTA updates with pre-encrypted binary using the `esp_encrypted_img` component's APIs and tool, ensuring the confidentiality of the firmware on the network channel, but not its authenticity. To perform OTA upgrades with pre-encrypted firmware, please enable :ref:`CONFIG_ESP_HTTPS_OTA_DECRYPT_CB` in component `menuconfig`.
|
||||
|
||||
- :example:`system/ota/advanced_https_ota` demonstrates how to use the Advanced HTTPS OTA update functionality on {IDF_TARGET_NAME} using the `esp_https_ota` component's APIs. For the applicable SoCs, please refer to :example_file:`system/ota/advanced_https_ota/README.md`.
|
||||
|
||||
- :example:`system/ota/simple_ota_example` demonstrates how to use the `esp_https_ota` component's APIs to support firmware upgrades through specific networking interfaces such as Ethernet or Wi-Fi Station on {IDF_TARGET_NAME}. For the applicable SoCs, please refer to :example_file:`system/ota/simple_ota_example/README.md`.
|
||||
|
||||
API Reference
|
||||
-------------
|
||||
|
||||
@@ -224,6 +224,11 @@ To set the version in your project manually, you need to set the ``PROJECT_VER``
|
||||
|
||||
If the :ref:`CONFIG_APP_PROJECT_VER_FROM_CONFIG` option is set, the value of :ref:`CONFIG_APP_PROJECT_VER` will be used. Otherwise, if the ``PROJECT_VER`` variable is not set in the project, it will be retrieved either from the ``$(PROJECT_PATH)/version.txt`` file (if present) or using git command ``git describe``. If neither is available, ``PROJECT_VER`` will be set to "1". Application can make use of this by calling :cpp:func:`esp_app_get_description` or :cpp:func:`esp_ota_get_partition_description` functions.
|
||||
|
||||
Application Examples
|
||||
--------------------
|
||||
|
||||
- :example:`system/base_mac_address` demonstrates how to retrieve, set, and derive the base MAC address for each network interface on {IDF_TARGET_NAME} from non-volatile memory, using either the eFuse blocks or external storage.
|
||||
|
||||
API Reference
|
||||
-------------
|
||||
|
||||
|
||||
@@ -341,10 +341,12 @@ See Also
|
||||
* :doc:`../peripherals/spi_flash/index`
|
||||
* :doc:`esp_https_ota`
|
||||
|
||||
Application Example
|
||||
-------------------
|
||||
Application Examples
|
||||
--------------------
|
||||
|
||||
End-to-end example of OTA firmware update workflow: :example:`system/ota`.
|
||||
- :example:`system/ota/native_ota_example` demonstrates how to use the `app_update` component's APIs for native Over-the-Air (OTA) updates on {IDF_TARGET_NAME}. For the applicable SoCs, please refer to :example_file:`system/ota/native_ota_example/README.md`.
|
||||
|
||||
- :example:`system/ota/otatool` demonstrates how to use the OTA tool to perform operations such as reading, writing, and erasing OTA partitions, switching boot partitions, and switching to factory partition. For more information, please refer to :example_file:`system/ota/otatool/README.md`.
|
||||
|
||||
API Reference
|
||||
-------------
|
||||
|
||||
Reference in New Issue
Block a user