docs: updated misc docs with H2 specific information.

pull/11637/head
Marius Vikhammer 2023-06-06 09:40:55 +08:00
rodzic f6452f0819
commit aeeee67164
18 zmienionych plików z 150 dodań i 90 usunięć

Wyświetl plik

@ -1,12 +1,3 @@
languages
contribute/esp-idf-tests-with-pytest
contribute/contributor-agreement
contribute/documenting-code
contribute/creating-examples
contribute/style-guide
contribute/copyright-guide
contribute/install-pre-commit-hook
contribute/index
api-guides/RF_calibration
api-guides/coexist
api-guides/wifi
@ -16,18 +7,9 @@ api-guides/dfu
api-guides/wifi-security
api-guides/index
api-guides/openthread
third-party-tools/platformio
COPYRIGHT
libraries-and-frameworks/libs-frameworks
libraries-and-frameworks/index
libraries-and-frameworks/cloud-frameworks
versions
api-reference/peripherals/usb_host
api-reference/peripherals/usb_device
api-reference/peripherals/i2s
api-reference/peripherals/spi_features
api-reference/peripherals/sdio_slave
api-reference/peripherals/spi_flash/xip_from_psram.inc
api-reference/peripherals/adc_calibration
api-reference/peripherals/dedic_gpio
api-reference/peripherals/sd_pullup_requirements
@ -41,9 +23,6 @@ api-reference/network/esp_smartconfig
api-reference/network/esp_wifi
api-reference/network/index
api-reference/system/sleep_modes
api-reference/system/chip_revision
api-reference/system/esp_timer
api-reference/system/system_time
api-reference/system/power_management
api-reference/system/inc/power_management_esp32
api-reference/system/inc/power_management_esp32s2_and_later
@ -52,31 +31,3 @@ api-reference/protocols/esp_sdio_slave_protocol
api-reference/protocols/esp_spi_slave_protocol
api-reference/protocols/modbus
api-reference/protocols/index
about
resources
migration-guides/release-5.x/5.1/index
migration-guides/release-5.x/5.1/peripherals
migration-guides/release-5.x/5.0/gcc
migration-guides/release-5.x/5.0/removed-components
migration-guides/release-5.x/5.0/protocols
migration-guides/release-5.x/5.0/networking
migration-guides/release-5.x/5.0/provisioning
migration-guides/release-5.x/5.0/build-system
migration-guides/release-5.x/5.0/storage
migration-guides/release-5.x/5.0/index
migration-guides/release-5.x/5.0/system
migration-guides/release-5.x/5.0/tools
migration-guides/release-5.x/5.0/peripherals
migration-guides/index
get-started/establish-serial-connection
get-started/linux-macos-setup
get-started/linux-macos-start-project
get-started/windows-setup
get-started/start-project
get-started/flashing-troubleshooting
get-started/windows-start-project
get-started/index
get-started/windows-setup-update
404
index
hw-reference/index

Wyświetl plik

@ -35,6 +35,12 @@ About
The {IDF_TARGET_NAME} is a 2.4 GHz Wi-Fi, Bluetooth Low Energy, and 802.15.4 Thread/Zigbee combo SoC, which integrates a 32-bit RISC-V RV32IMAC single-core processor.
.. only:: esp32h2
This is documentation of `ESP-IDF <https://github.com/espressif/esp-idf>`_, the framework to develop applications for {IDF_TARGET_NAME}.
The {IDF_TARGET_NAME} is a Bluetooth Low Energy and 802.15.4 Thread/Zigbee combo SoC, which integrates a 32-bit RISC-V RV32IMAC single-core processor.
.. figure:: ../_static/about-doc.png
:align: center
:alt: Espressif IoT Integrated Development Framework

Wyświetl plik

@ -5,7 +5,7 @@ High Resolution Timer (ESP Timer)
{IDF_TARGET_HR_TIMER:default = "SYSTIMER", esp32 = "LAC timer"}
{IDF_TARGET_HR_TIMER_Resolution:default = "Not updated", esp32 = "64", esp32s2 = "64", esp32c3 = "52", esp32s3 = "52", esp32c2 = "52", esp32c6 = "52"}
{IDF_TARGET_HR_TIMER_Resolution:default = "Not updated", esp32 = "64", esp32s2 = "64", esp32c3 = "52", esp32s3 = "52", esp32c2 = "52", esp32c6 = "52", esp32h2 = "52"}
Overview
@ -18,7 +18,10 @@ Although FreeRTOS provides software timers, FreeRTOS software timers have a few
Although hardware timers are not subject to the limitations mentioned, they may not be as user-friendly. For instance, application components may require timer events to be triggered at specific future times, but hardware timers typically have only one "compare" value for interrupt generation. This necessitates the creation of an additional system on top of the hardware timer to keep track of pending events and ensure that callbacks are executed when the corresponding hardware interrupts occur.
The hardware timer interrupt's priority is configured via the :ref:`CONFIG_ESP_TIMER_INTERRUPT_LEVEL` option (possible priorities being 1, 2, or 3). Raising the timer interrupt's priority can reduce the timer processing delay caused by interrupt latency.
.. only:: esp32
The hardware timer interrupt's priority is configured via the :ref:`CONFIG_ESP_TIMER_INTERRUPT_LEVEL` option (possible priorities being 1, 2, or 3). Raising the timer interrupt's priority can reduce the timer processing delay caused by interrupt latency.
``esp_timer`` set of APIs provides one-shot and periodic timers, microsecond time resolution, and {IDF_TARGET_HR_TIMER_Resolution}-bit range.

Wyświetl plik

@ -3,12 +3,12 @@ System Time
:link_to_translation:`zh_CN:[中文]`
{IDF_TARGET_RTC_CLK_FRE:default="Not updated", esp32="150 kHz", esp32s2="90 kHz", esp32s3="136 kHz", esp32c3="136 kHz", esp32c2="136 kHz", esp32c6="150 kHz"}
{IDF_TARGET_RTC_CLK_FRE:default="Not updated", esp32="150 kHz", esp32s2="90 kHz", esp32s3="136 kHz", esp32c3="136 kHz", esp32c2="136 kHz", esp32c6="150 kHz", esp32h2="150 kHz"}
{IDF_TARGET_INT_OSC_FRE:default="Not updated", esp32="8.5 MHz", esp32s2="8.5 MHz", esp32s3="17.5 MHz", esp32c3="17.5 MHz", esp32c2="17.5 MHz", esp32c6="20 MHz"}
{IDF_TARGET_INT_OSC_FRE_DIVIDED:default="Not updated", esp32="~33 kHz", esp32s2="~33 kHz", esp32s3="~68 kHz", esp32c3="~68 kHz", esp32c2="~68 kHz"}
{IDF_TARGET_EXT_CRYSTAL_PIN:default="Not updated", esp32="32K_XP and 32K_XN", esp32s2="XTAL_32K_P and XTAL_32K_N", esp32s3="XTAL_32K_P and XTAL_32K_N", esp32c3="XTAL_32K_P and XTAL_32K_N", esp32c6="XTAL_32K_P and XTAL_32K_N"}
{IDF_TARGET_EXT_CRYSTAL_PIN:default="Not updated", esp32="32K_XP and 32K_XN", esp32s2="XTAL_32K_P and XTAL_32K_N", esp32s3="XTAL_32K_P and XTAL_32K_N", esp32c3="XTAL_32K_P and XTAL_32K_N", esp32c6="XTAL_32K_P and XTAL_32K_N", esp32h2="XTAL_32K_P and XTAL_32K_N"}
{IDF_TARGET_EXT_OSC_PIN:default="Not updated", esp32="32K_XN", esp32s2="XTAL_32K_P", esp32s3="XTAL_32K_P", esp32c3="XTAL_32K_P", esp32c2="GPIO0", esp32c6="XTAL_32K_P"}
{IDF_TARGET_HARDWARE_DESIGN_URL:default="Not updated",esp32="`ESP32 Hardware Design Guidelines <https://www.espressif.com/sites/default/files/documentation/esp32_hardware_design_guidelines_en.pdf#page=11>`_", esp32s2="`ESP32-S2 Hardware Design Guidelines <https://www.espressif.com/sites/default/files/documentation/esp32-s2_hardware_design_guidelines_en.pdf#page=10>`_", esp32s3="`ESP32-S3 Hardware Design Guidelines <https://www.espressif.com/sites/default/files/documentation/esp32-s3_hardware_design_guidelines_en.pdf#page=11>`_", esp32c3="`ESP32-C3 Hardware Design Guidelines <https://www.espressif.com/sites/default/files/documentation/esp32-c3_hardware_design_guidelines_en.pdf#page=9>`_"}
{IDF_TARGET_HARDWARE_DESIGN_URL:default="Not updated",esp32="`ESP32 Hardware Design Guidelines <https://www.espressif.com/sites/default/files/documentation/esp32_hardware_design_guidelines_en.pdf#page=11>`_", esp32s2="`ESP32-S2 Hardware Design Guidelines <https://www.espressif.com/sites/default/files/documentation/esp32-s2_hardware_design_guidelines_en.pdf#page=10>`_", esp32s3="`ESP32-S3 Hardware Design Guidelines <https://www.espressif.com/sites/default/files/documentation/esp32-s3_hardware_design_guidelines_en.pdf#page=11>`_", esp32c3="`ESP32-C3 Hardware Design Guidelines <https://www.espressif.com/sites/default/files/documentation/esp32-c3_hardware_design_guidelines_en.pdf#page=9>`_", esp32c6="`ESP32-C6 Hardware Design Guidelines <https://www.espressif.com/sites/default/files/documentation/esp32-c6_hardware_design_guidelines_en.pdf#page=12>`_", esp32c2="`ESP8684 Hardware Design Guidelines <https://www.espressif.com/sites/default/files/documentation/esp8684_hardware_design_guidelines_en.pdf#page=10>`_", esp32h2="`ESP32-H2 Hardware Design Guidelines <https://www.espressif.com/sites/default/files/documentation/esp32-h2_hardware_design_guidelines_en.pdf#page=11>`_"}
Overview
@ -45,18 +45,13 @@ The RTC timer has the following clock sources:
- ``External 32 kHz oscillator at {IDF_TARGET_EXT_OSC_PIN} pin``: Allows using 32 kHz clock generated by an external circuit. The external clock signal must be connected to the {IDF_TARGET_EXT_OSC_PIN} pin. The amplitude should be less than 1.2 V for sine wave signal and less than 1 V for square wave signal. Common mode voltage should be in the range of 0.1 < Vcm < 0.5xVamp, where Vamp stands for signal amplitude. In this case, the {IDF_TARGET_EXT_OSC_PIN} pin cannot be used as a GPIO pin.
:not esp32c6: - ``Internal {IDF_TARGET_INT_OSC_FRE} oscillator, divided by 256 ({IDF_TARGET_INT_OSC_FRE_DIVIDED})``: Provides better frequency stability than the ``Internal {IDF_TARGET_RTC_CLK_FRE} RC oscillator`` at the expense of a higher (by 5 μA) Deep-sleep current consumption. It also does not require external components.
:not esp32c6 and not esp32h2: - ``Internal {IDF_TARGET_INT_OSC_FRE} oscillator, divided by 256 ({IDF_TARGET_INT_OSC_FRE_DIVIDED})``: Provides better frequency stability than the ``Internal {IDF_TARGET_RTC_CLK_FRE} RC oscillator`` at the expense of a higher (by 5 μA) Deep-sleep current consumption. It also does not require external components.
:esp32c6: - ``Internal 32 kHz RC oscillator``
:esp32c6 or esp32h2: - ``Internal 32 kHz RC oscillator``
The choice depends on your requirements for system time accuracy and power consumption in sleep modes. To modify the RTC clock source, set :ref:`CONFIG_RTC_CLK_SRC` in project configuration.
.. Need to add esp32c2 and esp32c6 hardware design guideline link after it is publsihed.
.. only:: not esp32c2 and not esp32c6
More details about the wiring requirements for the external crystal or external oscillator, please refer to {IDF_TARGET_HARDWARE_DESIGN_URL}.
More details about the wiring requirements for the external crystal or external oscillator, please refer to {IDF_TARGET_HARDWARE_DESIGN_URL}.
Get Current Time
----------------

Wyświetl plik

@ -141,8 +141,8 @@ Sometimes the USB-to-UART bridge is external. This is often used in small develo
For the {IDF_TARGET_NAME}, the USB peripheral is available, allowing you to flash the binaries without the need for an external USB-to-UART bridge.
{IDF_TARGET_USB_PIN_DM:default="Not Updated!", esp32c3="GPIO18", esp32s3="GPIO19", esp32s2="GPIO19", esp32c6="GPIO12"}
{IDF_TARGET_USB_PIN_DP:default="Not Updated!", esp32c3="GPIO19", esp32s3="GPIO20", esp32s2="GPIO20", esp32c6="GPIO13"}
{IDF_TARGET_USB_PIN_DM:default="Not Updated!", esp32c3="GPIO18", esp32s3="GPIO19", esp32s2="GPIO19", esp32c6="GPIO12", esp32h2="GPIO26"}
{IDF_TARGET_USB_PIN_DP:default="Not Updated!", esp32c3="GPIO19", esp32s3="GPIO20", esp32s2="GPIO20", esp32c6="GPIO13", esp32h2="GPIO27"}
The USB on the {IDF_TARGET_NAME} uses the **{IDF_TARGET_USB_PIN_DP}** for **D+** and **{IDF_TARGET_USB_PIN_DM}** for **D-**.

Wyświetl plik

@ -6,7 +6,7 @@ Flashing Troubleshooting
Failed to Connect
-----------------
{IDF_TARGET_STRAP_GPIO:default="[NEEDS TO BE UPDATED]", esp32="GPIO0", esp32s2="GPIO0", esp32s3="GPIO0", esp32c2="GPIO9", esp32c3="GPIO9", esp32c6="GPIO9"}
{IDF_TARGET_STRAP_GPIO:default="[NEEDS TO BE UPDATED]", esp32="GPIO0", esp32s2="GPIO0", esp32s3="GPIO0", esp32c2="GPIO9", esp32c3="GPIO9", esp32c6="GPIO9", esp32h2="GPIO9"}
If you run the given command and see errors such as "Failed to connect", there might be several reasons for this. One of the reasons might be issues encountered by ``esptool.py``, the utility that is called by the build system to reset the chip, interact with the ROM bootloader, and flash firmware. One simple solution to try is to manually reset as described below. If it does not help, you can find more details about possible issues in the `esptool troubleshooting <https://docs.espressif.com/projects/esptool/en/latest/esp32/troubleshooting.html>`_ page.

Wyświetl plik

@ -68,6 +68,14 @@ Introduction
* Multiple peripherals
* Built-in security hardware
.. only:: esp32h2
* Bluetooth Low Energy
* 802.15.4 Thread/Zigbee
* High performance 32-bit RISC-V single-core processor
* Multiple peripherals
* Built-in security hardware
Powered by 40 nm technology, {IDF_TARGET_NAME} provides a robust, highly integrated platform, which helps meet the continuous demands for efficient power usage, compact design, security, high performance, and reliability.
Espressif provides basic hardware and software resources to help application developers realize their ideas using the {IDF_TARGET_NAME} series hardware. The software development framework by Espressif is intended for development of Internet-of-Things (IoT) applications with Wi-Fi, Bluetooth, power management and several other system features.

Wyświetl plik

@ -1,6 +1,6 @@
{IDF_TARGET_FEATURES:default="[NEEDS TO BE UPDATED]", esp32="WiFi/BT/BLE, silicon revision 1, 2 MB external flash", esp32s2="WiFi, silicon revision 0, 2 MB external flash", esp32s3="This is esp32s3 chip with 2 CPU core(s), WiFi/BLE, silicon revision 0, 2 MB external flash", esp32c2="WiFi/BLE, silicon revision 0, 2 MB embedded flash", esp32c3="WiFi/BLE, silicon revision 0, 2 MB external flash", esp32c6="WiFi/BLE, 802.15.4 (Zigbee/Thread), silicon revision v0.0, 2 MB external flash"}
{IDF_TARGET_FEATURES:default="[NEEDS TO BE UPDATED]", esp32="WiFi/BT/BLE, silicon revision 1, 2 MB external flash", esp32s2="WiFi, silicon revision 0, 2 MB external flash", esp32s3="This is esp32s3 chip with 2 CPU core(s), WiFi/BLE, silicon revision 0, 2 MB external flash", esp32c2="WiFi/BLE, silicon revision 0, 2 MB embedded flash", esp32c3="WiFi/BLE, silicon revision 0, 2 MB external flash", esp32c6="WiFi/BLE, 802.15.4 (Zigbee/Thread), silicon revision v0.0, 2 MB external flash", esp32h2="BLE, 802.15.4 (Zigbee/Thread), silicon revision v0.1, 2 MB external flash"}
{IDF_TARGET_HEAP_SIZE:default="[NEEDS TO BE UPDATED]", esp32="298968", esp32s2="253900", esp32s3="390684", esp32c2="203888", esp32c3="337332", esp32c6="337332"}
{IDF_TARGET_HEAP_SIZE:default="[NEEDS TO BE UPDATED]", esp32="298968", esp32s2="253900", esp32s3="390684", esp32c2="203888", esp32c3="337332", esp32c6="473816", esp32h2="268256"}
Build the Project
=================
@ -318,6 +318,44 @@ When flashing, you will see the output log similar to the following:
Leaving...
Hard resetting via RTS pin...
.. only:: esp32h2
esptool esp32h2 -p /dev/ttyUSB0 -b 460800 --before=default_reset --after=hard_reset write_flash --flash_mode dio --flash_freq 48m --flash_size 2MB 0x0 bootloader/bootloader.bin 0x10000 hello_world.bin 0x8000 partition_table/partition-table.bin
esptool.py v4.6
Serial port /dev/ttyUSB0
Connecting....
Chip is ESP32-H2 (revision v0.1)
Features: BLE
Crystal is 32MHz
MAC: 60:55:f9:f7:3e:93:ff:fe
Uploading stub...
Running stub...
Stub running...
Changing baud rate to 460800
Changed.
Configuring flash size...
Flash will be erased from 0x00000000 to 0x00005fff...
Flash will be erased from 0x00010000 to 0x00034fff...
Flash will be erased from 0x00008000 to 0x00008fff...
Compressed 20880 bytes to 12788...
Writing at 0x00000000... (100 %)
Wrote 20880 bytes (12788 compressed) at 0x00000000 in 0.6 seconds (effective 297.5 kbit/s)...
Hash of data verified.
Compressed 149424 bytes to 79574...
Writing at 0x00010000... (20 %)
Writing at 0x00019959... (40 %)
Writing at 0x00020bb5... (60 %)
Writing at 0x00026d8f... (80 %)
Writing at 0x0002e60a... (100 %)
Wrote 149424 bytes (79574 compressed) at 0x00010000 in 2.1 seconds (effective 571.7 kbit/s)...
Hash of data verified.
Compressed 3072 bytes to 103...
Writing at 0x00008000... (100 %)
Wrote 3072 bytes (103 compressed) at 0x00008000 in 0.0 seconds (effective 539.7 kbit/s)...
Hash of data verified.
Leaving...
Hard resetting via RTS pin...
If there are no issues by the end of the flash process, the board will reboot and start up the “hello_world” application.

Wyświetl plik

@ -6,22 +6,26 @@ Hardware Reference
.. toctree::
:maxdepth: 1
:not esp32h2: Technical Reference Manual (PDF) <{IDF_TARGET_TRM_EN_URL}>
Technical Reference Manual (PDF) <{IDF_TARGET_TRM_EN_URL}>
:esp32: Chip Datasheet (PDF) <https://espressif.com/sites/default/files/documentation/esp32_datasheet_en.pdf>
:esp32s2: Chip Datasheet (PDF) <https://espressif.com/sites/default/files/documentation/esp32-s2_datasheet_en.pdf>
:esp32s3: Chip Datasheet (PDF) <https://espressif.com/sites/default/files/documentation/esp32-s3_datasheet_en.pdf>
:esp32c2: Chip Datasheet (PDF) <https://espressif.com/sites/default/files/documentation/esp8684_datasheet_en.pdf>
:esp32c3: Chip Datasheet (PDF) <https://espressif.com/sites/default/files/documentation/esp32-c3_datasheet_en.pdf>
:esp32c6: Chip Datasheet (PDF) <https://espressif.com/sites/default/files/documentation/esp32-c6_datasheet_en.pdf>
:esp32h2: Chip Datasheet (PDF) <https://espressif.com/sites/default/files/documentation/esp32-h2_datasheet_en.pdf>
:esp32: Hardware Design Guidelines (PDF) <https://espressif.com/sites/default/files/documentation/esp32_hardware_design_guidelines_en.pdf>
:esp32s2: Hardware Design Guidelines (PDF) <https://espressif.com/sites/default/files/documentation/esp32-s2_hardware_design_guidelines_en.pdf>
:esp32s3: Hardware Design Guidelines (PDF) <https://espressif.com/sites/default/files/documentation/esp32-s3_hardware_design_guidelines_en.pdf>
:esp32c2: Hardware Design Guidelines (PDF) <https://espressif.com/sites/default/files/documentation/esp8684_hardware_design_guidelines_en.pdf>
:esp32c3: Hardware Design Guidelines (PDF) <https://espressif.com/sites/default/files/documentation/esp32-c3_hardware_design_guidelines_en.pdf>
:esp32c6: Hardware Design Guidelines (PDF) <https://espressif.com/sites/default/files/documentation/esp32-c6_hardware_design_guidelines_en.pdf>
:esp32h2: Hardware Design Guidelines (PDF) <https://espressif.com/sites/default/files/documentation/esp32-h2_hardware_design_guidelines_en.pdf>
:esp32: Silicon Errata (PDF) <https://espressif.com/sites/default/files/documentation/eco_and_workarounds_for_bugs_in_esp32_en.pdf>
:esp32s2: Silicon Errata (PDF) <https://www.espressif.com/sites/default/files/documentation/esp32-s2_errata_en.pdf>
:esp32s3: Silicon Errata (PDF) <https://www.espressif.com/sites/default/files/documentation/esp32-s3_errata_en.pdf>
:esp32c3: Silicon Errata (PDF) <https://www.espressif.com/sites/default/files/documentation/esp32-c3_errata_en.pdf>
:esp32c2: Silicon Errata (PDF) <https://www.espressif.com/sites/default/files/documentation/esp8684_errata_en.pdf>
Chip Variants <https://espressif.com/en/products/socs?id={IDF_TARGET_NAME}>
Modules <https://espressif.com/en/products/modules?id={IDF_TARGET_NAME}>
Development Boards <https://www.espressif.com/en/products/devkits?id={IDF_TARGET_NAME}>

Wyświetl plik

@ -35,6 +35,12 @@
{IDF_TARGET_NAME} 是一款支持 2.4 GHz Wi-Fi, 802.15.4 Thread/Zigbee 和低功耗蓝牙的芯片,搭载 RISC-V RV32IMAC 32 位单核处理器。
.. only:: esp32h2
本指南为 {IDF_TARGET_NAME} 官方应用开发框架 `ESP-IDF <https://github.com/espressif/esp-idf>`_ 的配套文档。
{IDF_TARGET_NAME} 是一款支持 802.15.4 Thread/Zigbee 和低功耗蓝牙的芯片,搭载 RISC-V RV32IMAC 32 位单核处理器。
.. figure:: ../_static/about-doc.png
:align: center
:alt: 乐鑫物联网综合开发框架

Wyświetl plik

@ -5,7 +5,7 @@
{IDF_TARGET_HR_TIMER:default = "SYSTIMER", esp32 = "LAC 定时器"}
{IDF_TARGET_HR_TIMER_Resolution:default = "Not updated", esp32 = "64", esp32s2 = "64", esp32c3 = "52", esp32s3 = "52", esp32c2 = "52", esp32c6 = "52"}
{IDF_TARGET_HR_TIMER_Resolution:default = "Not updated", esp32 = "64", esp32s2 = "64", esp32c3 = "52", esp32s3 = "52", esp32c2 = "52", esp32c6 = "52", esp32h2 = "52"}
概述
@ -18,7 +18,10 @@
硬件定时器虽不受上述限制但使用不便。例如应用组件可能需要在特定的未来时间触发计时器事件但硬件定时器通常只有一个“compare比较”值用于中断生成。为提升使用的便利性应在硬件定时器的基础上构建某种机制来管理待处理事件列表确保在相应的硬件中断发生时调度回调。
配置 :ref:`CONFIG_ESP_TIMER_INTERRUPT_LEVEL` 选项,设置硬件定时器中断的优先级(可设置为 1、2 或 3 级),提高定时器中断的优先级可以减少由中断延迟引起的定时器处理延迟。
.. only:: esp32
配置 :ref:`CONFIG_ESP_TIMER_INTERRUPT_LEVEL` 选项,设置硬件定时器中断的优先级(可设置为 1、2 或 3 级),提高定时器中断的优先级可以减少由中断延迟引起的定时器处理延迟。
``esp_timer`` API 集支持单次定时器和周期定时器、微秒级的时间分辨率、以及 {IDF_TARGET_HR_TIMER_Resolution} 位范围。

Wyświetl plik

@ -3,12 +3,12 @@
:link_to_translation:`en:[English]`
{IDF_TARGET_RTC_CLK_FRE:default="未更新", esp32="150 kHz", esp32s2="90 kHz", esp32s3="136 kHz", esp32c3="136 kHz", esp32c2="136 kHz", esp32c6="150 kHz"}
{IDF_TARGET_RTC_CLK_FRE:default="未更新", esp32="150 kHz", esp32s2="90 kHz", esp32s3="136 kHz", esp32c3="136 kHz", esp32c2="136 kHz", esp32c6="150 kHz", esp32h2="150 kHz"}
{IDF_TARGET_INT_OSC_FRE:default="未更新", esp32="8.5 MHz", esp32s2="8.5 MHz", esp32s3="17.5 MHz", esp32c3="17.5 MHz", esp32c2="17.5 MHz", esp32c6="20 MHz"}
{IDF_TARGET_INT_OSC_FRE_DIVIDED:default="未更新", esp32="~33 kHz", esp32s2="~33 kHz", esp32s3="~68 kHz", esp32c3="~68 kHz", esp32c2="~68 kHz"}
{IDF_TARGET_EXT_CRYSTAL_PIN:default="未更新", esp32="32K_XP 和 32K_XN", esp32s2="XTAL_32K_P 和 XTAL_32K_N", esp32s3="XTAL_32K_P 和 XTAL_32K_N", esp32c3="XTAL_32K_P 和 XTAL_32K_N", esp32c6="XTAL_32K_P 和 XTAL_32K_N"}
{IDF_TARGET_EXT_CRYSTAL_PIN:default="未更新", esp32="32K_XP 和 32K_XN", esp32s2="XTAL_32K_P 和 XTAL_32K_N", esp32s3="XTAL_32K_P 和 XTAL_32K_N", esp32c3="XTAL_32K_P 和 XTAL_32K_N", esp32c6="XTAL_32K_P 和 XTAL_32K_N", esp32h2="XTAL_32K_P 和 XTAL_32K_N"}
{IDF_TARGET_EXT_OSC_PIN:default="未更新", esp32="32K_XN", esp32s2="XTAL_32K_P", esp32s3="XTAL_32K_P", esp32c3="XTAL_32K_P", esp32c2="GPIO0", esp32c6="XTAL_32K_P"}
{IDF_TARGET_HARDWARE_DESIGN_URL:default="未更新", esp32="`ESP32 硬件设计指南 <https://www.espressif.com/sites/default/files/documentation/esp32_hardware_design_guidelines_cn.pdf#page=10>`_", esp32s2="`ESP32-S2 硬件设计指南 <https://www.espressif.com/sites/default/files/documentation/esp32-s2_hardware_design_guidelines_cn.pdf#page=10>`_", esp32s3="`ESP32-S3 硬件设计指南 <https://www.espressif.com/sites/default/files/documentation/esp32-s3_hardware_design_guidelines_cn.pdf#page=12>`_", esp32c3="`ESP32-C3 硬件设计指南 <https://www.espressif.com/sites/default/files/documentation/esp32-c3_hardware_design_guidelines_cn.pdf#page=9>`_"}
{IDF_TARGET_HARDWARE_DESIGN_URL:default="未更新", esp32="`ESP32 硬件设计指南 <https://www.espressif.com/sites/default/files/documentation/esp32_hardware_design_guidelines_cn.pdf#page=10>`_", esp32s2="`ESP32-S2 硬件设计指南 <https://www.espressif.com/sites/default/files/documentation/esp32-s2_hardware_design_guidelines_cn.pdf#page=10>`_", esp32s3="`ESP32-S3 硬件设计指南 <https://www.espressif.com/sites/default/files/documentation/esp32-s3_hardware_design_guidelines_cn.pdf#page=12>`_", esp32c3="`ESP32-C3 硬件设计指南 <https://www.espressif.com/sites/default/files/documentation/esp32-c3_hardware_design_guidelines_cn.pdf#page=9>`_", esp32c2="`ESP8684 硬件设计指南 <https://www.espressif.com/sites/default/files/documentation/esp8684_hardware_design_guidelines_cn.pdf#page=10>`_", esp32c6="`ESP32-C6 硬件设计指南 <https://www.espressif.com/sites/default/files/documentation/esp32-c6_hardware_design_guidelines_cn.pdf#page=12>`_", esp32h2="`ESP32-H2 硬件设计指南 <https://www.espressif.com/sites/default/files/documentation/esp32-h2_hardware_design_guidelines_cn.pdf#page=11>`_"}
概述
@ -45,18 +45,13 @@ RTC 定时器有以下时钟源:
- ``管脚 {IDF_TARGET_EXT_OSC_PIN} 外置 32 kHz 振荡器``:允许使用由外部电路产生的 32 kHz 时钟。外部时钟信号必须连接到管脚 {IDF_TARGET_EXT_OSC_PIN}。正弦波信号的振幅应小于 1.2 V方波信号的振幅应小于 1 V。正常模式下电压范围应为 0.1 < Vcm < 0.5 xVamp其中 Vamp 代表信号振幅。使用此时钟源时,管脚 {IDF_TARGET_EXT_OSC_PIN} 无法用作 GPIO 管脚。
:not esp32c6: - ``内置 {IDF_TARGET_INT_OSC_FRE} 振荡器的 256 分频时钟 ({IDF_TARGET_INT_OSC_FRE_DIVIDED})``:频率稳定性优于 ``内置 {IDF_TARGET_RTC_CLK_FRE} RC 振荡器``,同样无需外部元件,但 Deep-sleep 模式下电流消耗更高(比默认模式高 5 μA
:not esp32c6 and not esp32h2: - ``内置 {IDF_TARGET_INT_OSC_FRE} 振荡器的 256 分频时钟 ({IDF_TARGET_INT_OSC_FRE_DIVIDED})``:频率稳定性优于 ``内置 {IDF_TARGET_RTC_CLK_FRE} RC 振荡器``,同样无需外部元件,但 Deep-sleep 模式下电流消耗更高(比默认模式高 5 μA
:esp32c6: - ``内置 32 kHz RC 振荡器``
:esp32c6 or esp32h2: - ``内置 32 kHz RC 振荡器``
时钟源的选择取决于系统时间精度要求和睡眠模式下的功耗要求。要修改 RTC 时钟源,请在项目配置中设置 :ref:`CONFIG_RTC_CLK_SRC`
.. Need to add esp32c2 and esp32c6 hardware design guideline link after it is publsihed.
.. only:: not esp32c2 and not esp32c6
想要了解外置晶振或外置振荡器的更多布线要求,请参考 {IDF_TARGET_HARDWARE_DESIGN_URL}。
想要了解外置晶振或外置振荡器的更多布线要求,请参考 {IDF_TARGET_HARDWARE_DESIGN_URL}。
获取当前时间
--------------

Wyświetl plik

@ -141,8 +141,8 @@
{IDF_TARGET_NAME} 支持 USB 外设,无需外部 USB 至 UART 桥,即可烧录二进制文件。
{IDF_TARGET_USB_PIN_DM:default="尚未更新!", esp32c3="GPIO18", esp32s3="GPIO19", esp32s2="GPIO19", esp32c6="GPIO12"}
{IDF_TARGET_USB_PIN_DP:default="尚未更新!", esp32c3="GPIO19", esp32s3="GPIO20", esp32s2="GPIO20", esp32c6="GPIO13"}
{IDF_TARGET_USB_PIN_DM:default="尚未更新!", esp32c3="GPIO18", esp32s3="GPIO19", esp32s2="GPIO19", esp32c6="GPIO12", esp32h2="GPIO26"}
{IDF_TARGET_USB_PIN_DP:default="尚未更新!", esp32c3="GPIO19", esp32s3="GPIO20", esp32s2="GPIO20", esp32c6="GPIO13", esp32h2="GPIO27"}
{IDF_TARGET_NAME} 上的 USB 使用 **{IDF_TARGET_USB_PIN_DP}** 作为 **D+** **{IDF_TARGET_USB_PIN_DM}** 作为 **D-**

Wyświetl plik

@ -6,7 +6,7 @@
连接失败
-----------------
{IDF_TARGET_STRAP_GPIO:default="[NEEDS TO BE UPDATED]", esp32="GPIO0", esp32s2="GPIO0", esp32s3="GPIO0", esp32c2="GPIO9", esp32c3="GPIO9", esp32c6="GPIO9"}
{IDF_TARGET_STRAP_GPIO:default="[NEEDS TO BE UPDATED]", esp32="GPIO0", esp32s2="GPIO0", esp32s3="GPIO0", esp32c2="GPIO9", esp32c3="GPIO9", esp32c6="GPIO9", esp32h2="GPIO9"}
如果在运行给定命令时出现如“连接失败”这样的错误,造成该错误的原因之一可能是运行 ``esptool.py`` 时出现错误。 ``esptool.py`` 是构建系统调用的程序,用于重置芯片、与 ROM 引导加载器交互以及烧录固件的工具。可以按照以下步骤进行手动复位,轻松解决该问题。如果问题仍未解决,请参考 `esptool 故障排除 <https://docs.espressif.com/projects/esptool/en/latest/esp32/troubleshooting.html>`_ 获取更多信息。

Wyświetl plik

@ -68,6 +68,14 @@
* 多种外设
* 内置安全硬件
.. only:: esp32h2
* 低功耗蓝牙
* 802.15.4,支持 Thread 和 Zigbee 协议
* 高性能 32 位 RISC-V 单核处理器
* 多种外设
* 内置安全硬件
{IDF_TARGET_NAME} 采用 40 nm 工艺制成,具有最佳的功耗性能、射频性能、稳定性、通用性和可靠性,适用于各种应用场景和不同功耗需求。
乐鑫为用户提供完整的软、硬件资源,进行 {IDF_TARGET_NAME} 硬件设备的开发。其中,乐鑫的软件开发环境 ESP-IDF 旨在协助用户快速开发物联网 (IoT) 应用,可满足用户对 Wi-Fi、蓝牙、低功耗等方面的要求。

Wyświetl plik

@ -1,6 +1,6 @@
{IDF_TARGET_FEATURES:default="[NEEDS TO BE UPDATED]", esp32="WiFi/BT/BLE, silicon revision 1, 2 MB external flash", esp32s2="WiFi, silicon revision 0, 2 MB external flash", esp32s3="This is esp32s3 chip with 2 CPU core(s), WiFi/BLE, silicon revision 0, 2 MB external flash", esp32c2="WiFi/BLE, silicon revision 0, 2 MB embedded flash", esp32c3="WiFi/BLE, silicon revision 0, 2 MB external flash", esp32c6="WiFi/BLE, 802.15.4 (Zigbee/Thread), silicon revision v0.0, 2 MB external flash"}
{IDF_TARGET_FEATURES:default="[NEEDS TO BE UPDATED]", esp32="WiFi/BT/BLE, silicon revision 1, 2 MB external flash", esp32s2="WiFi, silicon revision 0, 2 MB external flash", esp32s3="This is esp32s3 chip with 2 CPU core(s), WiFi/BLE, silicon revision 0, 2 MB external flash", esp32c2="WiFi/BLE, silicon revision 0, 2 MB embedded flash", esp32c3="WiFi/BLE, silicon revision 0, 2 MB external flash", esp32c6="WiFi/BLE, 802.15.4 (Zigbee/Thread), silicon revision v0.0, 2 MB external flash", esp32h2="BLE, 802.15.4 (Zigbee/Thread), silicon revision v0.1, 2 MB external flash"}
{IDF_TARGET_HEAP_SIZE:default="[NEEDS TO BE UPDATED]", esp32="298968", esp32s2="253900", esp32s3="390684", esp32c2="203888", esp32c3="337332", esp32c6="337332"}
{IDF_TARGET_HEAP_SIZE:default="[NEEDS TO BE UPDATED]", esp32="298968", esp32s2="253900", esp32s3="390684", esp32c2="203888", esp32c3="337332", esp32c6="473816", esp32h2="268256"}
编译工程
=========================
@ -318,6 +318,44 @@
Leaving...
Hard resetting via RTS pin...
.. only:: esp32h2
esptool esp32h2 -p /dev/ttyUSB0 -b 460800 --before=default_reset --after=hard_reset write_flash --flash_mode dio --flash_freq 48m --flash_size 2MB 0x0 bootloader/bootloader.bin 0x10000 hello_world.bin 0x8000 partition_table/partition-table.bin
esptool.py v4.6
Serial port /dev/ttyUSB0
Connecting....
Chip is ESP32-H2 (revision v0.1)
Features: BLE
Crystal is 32MHz
MAC: 60:55:f9:f7:3e:93:ff:fe
Uploading stub...
Running stub...
Stub running...
Changing baud rate to 460800
Changed.
Configuring flash size...
Flash will be erased from 0x00000000 to 0x00005fff...
Flash will be erased from 0x00010000 to 0x00034fff...
Flash will be erased from 0x00008000 to 0x00008fff...
Compressed 20880 bytes to 12788...
Writing at 0x00000000... (100 %)
Wrote 20880 bytes (12788 compressed) at 0x00000000 in 0.6 seconds (effective 297.5 kbit/s)...
Hash of data verified.
Compressed 149424 bytes to 79574...
Writing at 0x00010000... (20 %)
Writing at 0x00019959... (40 %)
Writing at 0x00020bb5... (60 %)
Writing at 0x00026d8f... (80 %)
Writing at 0x0002e60a... (100 %)
Wrote 149424 bytes (79574 compressed) at 0x00010000 in 2.1 seconds (effective 571.7 kbit/s)...
Hash of data verified.
Compressed 3072 bytes to 103...
Writing at 0x00008000... (100 %)
Wrote 3072 bytes (103 compressed) at 0x00008000 in 0.0 seconds (effective 539.7 kbit/s)...
Hash of data verified.
Leaving...
Hard resetting via RTS pin...
如果一切顺利,烧录完成后,开发板将会复位,应用程序 "hello_world" 开始运行。

Wyświetl plik

@ -6,22 +6,26 @@ H/W 硬件参考
.. toctree::
:maxdepth: 1
:not esp32h2: 技术参考手册 (PDF) <{IDF_TARGET_TRM_CN_URL}>
技术参考手册 (PDF) <{IDF_TARGET_TRM_CN_URL}>
:esp32: 技术规格书 (PDF) <https://espressif.com/sites/default/files/documentation/esp32_datasheet_cn.pdf>
:esp32s2: 技术规格书 (PDF) <https://espressif.com/sites/default/files/documentation/esp32-s2_datasheet_cn.pdf>
:esp32s3: 技术规格书 (PDF) <https://espressif.com/sites/default/files/documentation/esp32-s3_datasheet_cn.pdf>
:esp32c2: 技术规格书 (PDF) <https://espressif.com/sites/default/files/documentation/esp8684_datasheet_cn.pdf>
:esp32c3: 技术规格书 (PDF) <https://espressif.com/sites/default/files/documentation/esp32-c3_datasheet_cn.pdf>
:esp32c6: 技术规格书 (PDF) <https://espressif.com/sites/default/files/documentation/esp32-c6_datasheet_cn.pdf>
:esp32h2: 技术规格书 (PDF) <https://espressif.com/sites/default/files/documentation/esp32-h2_datasheet_cn.pdf>
:esp32: 硬件设计指南 (PDF) <https://espressif.com/sites/default/files/documentation/esp32_hardware_design_guidelines_cn.pdf>
:esp32s2: 硬件设计指南 (PDF) <https://espressif.com/sites/default/files/documentation/esp32-s2_hardware_design_guidelines_cn.pdf>
:esp32s3: 硬件设计指南 (PDF) <https://espressif.com/sites/default/files/documentation/esp32-s3_hardware_design_guidelines_cn.pdf>
:esp32c2: 硬件设计指南 (PDF) <https://espressif.com/sites/default/files/documentation/esp8684_hardware_design_guidelines_cn.pdf>
:esp32c3: 硬件设计指南 (PDF) <https://espressif.com/sites/default/files/documentation/esp32-c3_hardware_design_guidelines_cn.pdf>
:esp32c6: 硬件设计指南 (PDF) <https://espressif.com/sites/default/files/documentation/esp32-c6_hardware_design_guidelines_cn.pdf>
:esp32h2: 硬件设计指南 (PDF) <https://espressif.com/sites/default/files/documentation/esp32-h2_hardware_design_guidelines_cn.pdf>
:esp32: 勘误表及解决方法 (PDF) <https://espressif.com/sites/default/files/documentation/eco_and_workarounds_for_bugs_in_esp32_cn.pdf>
:esp32s2: 勘误表及解决方法 (PDF) <https://www.espressif.com/sites/default/files/documentation/esp32-s2_errata_cn.pdf>
:esp32s3: 勘误表及解决方法 (PDF) <https://www.espressif.com/sites/default/files/documentation/esp32-s3_errata_cn.pdf>
:esp32c3: 勘误表及解决方法 (PDF) <https://www.espressif.com/sites/default/files/documentation/esp32-c3_errata_cn.pdf>
:esp32c2: 勘误表及解决方法 (PDF) <https://www.espressif.com/sites/default/files/documentation/esp8684_errata_cn.pdf>
芯片变型 <https://espressif.com/zh-hans/products/socs?id={IDF_TARGET_NAME}>
模组 <https://www.espressif.com/zh-hans/products/modules?id={IDF_TARGET_NAME}>
开发板 <https://www.espressif.com/zh-hans/products/devkits?id={IDF_TARGET_NAME}>

Wyświetl plik

@ -20,11 +20,12 @@ void app_main(void)
esp_chip_info_t chip_info;
uint32_t flash_size;
esp_chip_info(&chip_info);
printf("This is %s chip with %d CPU core(s), WiFi%s%s%s, ",
printf("This is %s chip with %d CPU core(s), %s%s%s%s, ",
CONFIG_IDF_TARGET,
chip_info.cores,
(chip_info.features & CHIP_FEATURE_BT) ? "/BT" : "",
(chip_info.features & CHIP_FEATURE_BLE) ? "/BLE" : "",
(chip_info.features & CHIP_FEATURE_WIFI_BGN) ? "WiFi/" : "",
(chip_info.features & CHIP_FEATURE_BT) ? "BT" : "",
(chip_info.features & CHIP_FEATURE_BLE) ? "BLE" : "",
(chip_info.features & CHIP_FEATURE_IEEE802154) ? ", 802.15.4 (Zigbee/Thread)" : "");
unsigned major_rev = chip_info.revision / 100;