diff --git a/.gitlab/ci/docs.yml b/.gitlab/ci/docs.yml index 809b1612d7..0442e5dac1 100644 --- a/.gitlab/ci/docs.yml +++ b/.gitlab/ci/docs.yml @@ -99,7 +99,7 @@ check_docs_lang_sync: parallel: matrix: - DOCLANG: ["en", "zh_CN"] - DOCTGT: ["esp32", "esp32s2", "esp32s3", "esp32c3", "esp32c2", "esp32c6", "esp32h2", "esp32p4"] + DOCTGT: ["esp32", "esp32s2", "esp32s3", "esp32c3", "esp32c2", "esp32c5", "esp32c6", "esp32h2", "esp32p4"] check_docs_gh_links: image: $ESP_IDF_DOC_ENV_IMAGE diff --git a/components/soc/esp32c5/include/soc/Kconfig.soc_caps.in b/components/soc/esp32c5/include/soc/Kconfig.soc_caps.in index 280d500f2d..90bfb9df01 100644 --- a/components/soc/esp32c5/include/soc/Kconfig.soc_caps.in +++ b/components/soc/esp32c5/include/soc/Kconfig.soc_caps.in @@ -39,10 +39,6 @@ config SOC_SPI_FLASH_SUPPORTED bool default y -config SOC_INT_HW_NESTED_SUPPORTED - bool - default y - config SOC_XTAL_SUPPORT_40M bool default y @@ -83,6 +79,10 @@ config SOC_INT_CLIC_SUPPORTED bool default y +config SOC_INT_HW_NESTED_SUPPORTED + bool + default y + config SOC_BRANCH_PREDICTOR_SUPPORTED bool default y @@ -139,6 +139,10 @@ config SOC_LEDC_SUPPORT_XTAL_CLOCK bool default y +config SOC_LEDC_CHANNEL_NUM + int + default 6 + config SOC_MMU_PERIPH_NUM int default 1 @@ -223,6 +227,10 @@ config SOC_FLASH_ENCRYPTED_XTS_AES_BLOCK_MAX int default 64 +config SOC_FLASH_ENCRYPTION_XTS_AES + bool + default y + config SOC_FLASH_ENCRYPTION_XTS_AES_128 bool default y diff --git a/components/soc/esp32c5/include/soc/soc_caps.h b/components/soc/esp32c5/include/soc/soc_caps.h index f71b8b7e2d..dfd0fdc602 100644 --- a/components/soc/esp32c5/include/soc/soc_caps.h +++ b/components/soc/esp32c5/include/soc/soc_caps.h @@ -1,5 +1,5 @@ /* - * SPDX-FileCopyrightText: 2023 Espressif Systems (Shanghai) CO LTD + * SPDX-FileCopyrightText: 2023-2024 Espressif Systems (Shanghai) CO LTD * * SPDX-License-Identifier: Apache-2.0 */ @@ -71,7 +71,6 @@ // #define SOC_ECDSA_SUPPORTED 1 // TODO: [ESP32C5] IDF-8618 // #define SOC_KEY_MANAGER_SUPPORTED 1 // TODO: [ESP32C5] IDF-8621 // #define SOC_HUK_SUPPORTED 1 // TODO: [ESP32C5] IDF-8617 -#define SOC_INT_HW_NESTED_SUPPORTED 1 /*-------------------------- XTAL CAPS ---------------------------------------*/ #define SOC_XTAL_SUPPORT_40M 1 @@ -265,7 +264,7 @@ // TODO: [ESP32C5] 8684 #define SOC_LEDC_SUPPORT_PLL_DIV_CLOCK (1) #define SOC_LEDC_SUPPORT_XTAL_CLOCK (1) -// #define SOC_LEDC_CHANNEL_NUM (6) +#define SOC_LEDC_CHANNEL_NUM (6) // #define SOC_LEDC_TIMER_BIT_WIDTH (20) // #define SOC_LEDC_SUPPORT_FADE_STOP (1) // #define SOC_LEDC_GAMMA_CURVE_FADE_SUPPORTED (1) @@ -461,7 +460,7 @@ /*-------------------------- Flash Encryption CAPS----------------------------*/ #define SOC_FLASH_ENCRYPTED_XTS_AES_BLOCK_MAX (64) // TODO: [ESP32C5] IDF-8622 -// #define SOC_FLASH_ENCRYPTION_XTS_AES 1 +#define SOC_FLASH_ENCRYPTION_XTS_AES 1 #define SOC_FLASH_ENCRYPTION_XTS_AES_128 1 // TODO: [ESP32C5] IDF-8622 /*------------------------ Anti DPA (Security) CAPS --------------------------*/ diff --git a/docs/conf_common.py b/docs/conf_common.py index db60ac1374..1ed976f6b8 100644 --- a/docs/conf_common.py +++ b/docs/conf_common.py @@ -181,6 +181,8 @@ ESP32C3_DOCS = ['hw-reference/esp32c3/**', ESP32C2_DOCS = ['api-guides/RF_calibration.rst'] +ESP32C5_DOCS = [''] + ESP32C6_DOCS = ['api-guides/RF_calibration.rst', 'api-reference/peripherals/sd_pullup_requirements.rst'] @@ -238,6 +240,7 @@ conditional_include_dict = {'SOC_BT_SUPPORTED':BT_DOCS, 'esp32s3':ESP32S3_DOCS, 'esp32c2':ESP32C2_DOCS, 'esp32c3':ESP32C3_DOCS, + 'esp32c5':ESP32C5_DOCS, 'esp32c6':ESP32C6_DOCS, 'esp32h2':ESP32H2_DOCS, 'esp32p4':ESP32P4_DOCS} @@ -273,7 +276,7 @@ html_context['github_repo'] = 'esp-idf' project_slug = 'esp-idf' versions_url = 'https://dl.espressif.com/dl/esp-idf/idf_versions.js' -idf_targets = ['esp32', 'esp32s2', 'esp32s3', 'esp32c3', 'esp32c2', 'esp32c6', 'esp32p4'] +idf_targets = ['esp32', 'esp32s2', 'esp32s3', 'esp32c3', 'esp32c2', 'esp32c5', 'esp32c6', 'esp32p4'] languages = ['en', 'zh_CN'] google_analytics_id = os.environ.get('CI_GOOGLE_ANALYTICS_ID', None) diff --git a/docs/docs_not_updated/esp32c5.txt b/docs/docs_not_updated/esp32c5.txt new file mode 100644 index 0000000000..bf93d3e42c --- /dev/null +++ b/docs/docs_not_updated/esp32c5.txt @@ -0,0 +1,306 @@ +contribute/esp-idf-tests-with-pytest.rst +contribute/contributor-agreement.rst +contribute/documenting-code.rst +contribute/creating-examples.rst +contribute/style-guide.rst +contribute/copyright-guide.rst +contribute/install-pre-commit-hook.rst +contribute/index.rst +api-guides/core_dump_internals.rst +api-guides/performance/speed.rst +api-guides/performance/size.rst +api-guides/performance/ram-usage.rst +api-guides/performance/index.rst +api-guides/jtag-debugging/debugging-examples.rst +api-guides/jtag-debugging/configure-ft2232h-jtag.rst +api-guides/jtag-debugging/tips-and-quirks.rst +api-guides/jtag-debugging/using-debugger.rst +api-guides/jtag-debugging/building-openocd-macos.rst +api-guides/jtag-debugging/building-openocd-linux.rst +api-guides/jtag-debugging/configure-other-jtag.rst +api-guides/jtag-debugging/building-openocd-windows.rst +api-guides/jtag-debugging/index.rst +api-guides/jtag-debugging/configure-builtin-jtag.rst +api-guides/partition-tables.rst +api-guides/app_trace.rst +api-guides/thread-local-storage.rst +api-guides/error-handling.rst +api-guides/tools/idf-tools.rst +api-guides/tools/idf-clang-tidy.rst +api-guides/tools/idf-component-manager.rst +api-guides/tools/idf-py.rst +api-guides/tools/qemu.rst +api-guides/tools/idf-windows-installer.rst +api-guides/tools/idf-monitor.rst +api-guides/tools/idf-docker-image.rst +api-guides/tools/index.rst +api-guides/low-power-mode.rst +api-guides/startup.rst +api-guides/hlinterrupts.rst +api-guides/RF_calibration.rst +api-guides/unit-tests.rst +api-guides/deep-sleep-stub.rst +api-guides/blufi.rst +api-guides/lwip.rst +api-guides/coexist.rst +api-guides/flash_psram_config.rst +api-guides/usb-serial-jtag-console.rst +api-guides/linker-script-generation.rst +api-guides/wifi.rst +api-guides/usb-otg-console.rst +api-guides/bluetooth.rst +api-guides/wireshark-user-guide.rst +api-guides/bootloader.rst +api-guides/esp-wifi-mesh.rst +api-guides/cplusplus.rst +api-guides/build-system.rst +api-guides/core_dump.rst +api-guides/inc/external-ram-esp32-notes.rst +api-guides/inc/linux-host-requirements.rst +api-guides/c.rst +api-guides/dfu.rst +api-guides/current-consumption-measurement-modules.rst +api-guides/esp-ble-mesh/ble-mesh-index.rst +api-guides/esp-ble-mesh/ble-mesh-feature-list.rst +api-guides/esp-ble-mesh/ble-mesh-terminology.rst +api-guides/esp-ble-mesh/ble-mesh-architecture.rst +api-guides/esp-ble-mesh/ble-mesh-faq.rst +api-guides/external-ram.rst +api-guides/reproducible-builds.rst +api-guides/hardware-abstraction.rst +api-guides/wifi-security.rst +api-guides/host-apps.rst +api-guides/index.rst +api-guides/openthread.rst +api-guides/fatal-errors.rst +api-guides/memory-types.rst +api-guides/general-notes.rst +third-party-tools/platformio.rst +third-party-tools/clion.rst +third-party-tools/visualgdb.rst +COPYRIGHT.rst +libraries-and-frameworks/libs-frameworks.rst +libraries-and-frameworks/index.rst +libraries-and-frameworks/cloud-frameworks.rst +versions.rst +api-reference/api-conventions.rst +api-reference/template.rst +api-reference/provisioning/protocomm.rst +api-reference/provisioning/provisioning.rst +api-reference/provisioning/index.rst +api-reference/provisioning/wifi_provisioning.rst +api-reference/storage/vfs.rst +api-reference/storage/spiffs.rst +api-reference/storage/nvs_encryption.rst +api-reference/storage/wear-levelling.rst +api-reference/storage/fatfs.rst +api-reference/storage/nvs_partition_gen.rst +api-reference/storage/nvs_flash.rst +api-reference/storage/partition.rst +api-reference/storage/sdmmc.rst +api-reference/storage/mass_mfg.rst +api-reference/storage/fatfsgen.rst +api-reference/storage/index.rst +api-reference/storage/nvs_partition_parse.rst +api-reference/peripherals/sdspi_share.rst +api-reference/peripherals/adc_continuous.rst +api-reference/peripherals/adc_oneshot.rst +api-reference/peripherals/usb_host.rst +api-reference/peripherals/twai.rst +api-reference/peripherals/usb_host/usb_host_notes_arch.rst +api-reference/peripherals/usb_host/usb_host_notes_index.rst +api-reference/peripherals/usb_host/usb_host_notes_dwc_otg.rst +api-reference/peripherals/usb_host/usb_host_notes_design.rst +api-reference/peripherals/hmac.rst +api-reference/peripherals/usb_device.rst +api-reference/peripherals/gpio.rst +api-reference/peripherals/sdspi_host.rst +api-reference/peripherals/dac.rst +api-reference/peripherals/spi_slave.rst +api-reference/peripherals/etm.rst +api-reference/peripherals/i2s.rst +api-reference/peripherals/gptimer.rst +api-reference/peripherals/pcnt.rst +api-reference/peripherals/touch_element.rst +api-reference/peripherals/lcd.rst +api-reference/peripherals/mcpwm.rst +api-reference/peripherals/ana_cmpr.rst +api-reference/peripherals/ledc.rst +api-reference/peripherals/temp_sensor.rst +api-reference/peripherals/spi_features.rst +api-reference/peripherals/sdio_slave.rst +api-reference/peripherals/clk_tree.rst +api-reference/peripherals/spi_flash/spi_flash_concurrency.rst +api-reference/peripherals/spi_flash/spi_flash_override_driver.rst +api-reference/peripherals/spi_flash/spi_flash_optional_feature.rst +api-reference/peripherals/spi_flash/spi_flash_idf_vs_rom.rst +api-reference/peripherals/spi_flash/index.rst +api-reference/peripherals/sdm.rst +api-reference/peripherals/touch_pad.rst +api-reference/peripherals/adc_calibration.rst +api-reference/peripherals/spi_slave_hd.rst +api-reference/peripherals/parlio.rst +api-reference/peripherals/ds.rst +api-reference/peripherals/i2c.rst +api-reference/peripherals/dedic_gpio.rst +api-reference/peripherals/sd_pullup_requirements.rst +api-reference/peripherals/spi_master.rst +api-reference/peripherals/index.rst +api-reference/peripherals/sdmmc_host.rst +api-reference/peripherals/uart.rst +api-reference/peripherals/ecdsa.rst +api-reference/peripherals/rmt.rst +api-reference/kconfig.rst +api-reference/network/esp_openthread.rst +api-reference/network/esp_eth.rst +api-reference/network/esp_netif_driver.rst +api-reference/network/esp_dpp.rst +api-reference/network/esp_now.rst +api-reference/network/esp-wifi-mesh.rst +api-reference/network/esp_smartconfig.rst +api-reference/network/esp_nan.rst +api-reference/network/esp_wifi.rst +api-reference/network/index.rst +api-reference/network/esp_netif.rst +api-reference/system/sleep_modes.rst +api-reference/system/mm_sync.rst +api-reference/system/ota.rst +api-reference/system/app_trace.rst +api-reference/system/ulp_macros.rst +api-reference/system/perfmon.rst +api-reference/system/ulp-lp-core.rst +api-reference/system/ulp.rst +api-reference/system/esp_function_with_shared_stack.rst +api-reference/system/efuse.rst +api-reference/system/chip_revision.rst +api-reference/system/ulp_instruction_set.rst +api-reference/system/async_memcpy.rst +api-reference/system/random.rst +api-reference/system/esp_timer.rst +api-reference/system/esp_event.rst +api-reference/system/freertos.rst +api-reference/system/system_time.rst +api-reference/system/log.rst +api-reference/system/soc_caps.rst +api-reference/system/internal-unstable.rst +api-reference/system/app_image_format.rst +api-reference/system/freertos_additions.rst +api-reference/system/himem.rst +api-reference/system/power_management.rst +api-reference/system/mem_alloc.rst +api-reference/system/wdts.rst +api-reference/system/misc_system_api.rst +api-reference/system/bootloader_image_format.rst +api-reference/system/inc/show-efuse-table_ESP32-C5.rst +api-reference/system/inc/revisions_ESP32-C5.rst +api-reference/system/inc/espefuse_summary_ESP32-C5.rst +api-reference/system/inc/power_management_esp32c5.rst +api-reference/system/heap_debug.rst +api-reference/system/mm.rst +api-reference/system/ipc.rst +api-reference/system/esp_https_ota.rst +api-reference/system/ulp-risc-v.rst +api-reference/system/esp_err.rst +api-reference/system/freertos_idf.rst +api-reference/system/console.rst +api-reference/system/intr_alloc.rst +api-reference/system/index.rst +api-reference/system/pthread.rst +api-reference/bluetooth/esp_spp.rst +api-reference/bluetooth/esp_l2cap_bt.rst +api-reference/bluetooth/esp_hidd.rst +api-reference/bluetooth/esp_avrc.rst +api-reference/bluetooth/controller_vhci.rst +api-reference/bluetooth/esp_bt_defs.rst +api-reference/bluetooth/esp_hf_ag.rst +api-reference/bluetooth/esp_bt_main.rst +api-reference/bluetooth/esp_bt_device.rst +api-reference/bluetooth/esp_hidh.rst +api-reference/bluetooth/esp_gatts.rst +api-reference/bluetooth/esp_gattc.rst +api-reference/bluetooth/esp_sdp.rst +api-reference/bluetooth/bt_common.rst +api-reference/bluetooth/nimble/index.rst +api-reference/bluetooth/esp_hf_client.rst +api-reference/bluetooth/esp_a2dp.rst +api-reference/bluetooth/esp_blufi.rst +api-reference/bluetooth/bt_le.rst +api-reference/bluetooth/esp_hf_defs.rst +api-reference/bluetooth/esp_gap_bt.rst +api-reference/bluetooth/esp_gatt_defs.rst +api-reference/bluetooth/esp-ble-mesh.rst +api-reference/bluetooth/index.rst +api-reference/bluetooth/esp_gap_ble.rst +api-reference/bluetooth/classic_bt.rst +api-reference/error-codes.rst +api-reference/index.rst +api-reference/protocols/icmp_echo.rst +api-reference/protocols/esp_serial_slave_link.rst +api-reference/protocols/mqtt.rst +api-reference/protocols/mbedtls.rst +api-reference/protocols/esp_http_server.rst +api-reference/protocols/esp_sdio_slave_protocol.rst +api-reference/protocols/esp_local_ctrl.rst +api-reference/protocols/esp_crt_bundle.rst +api-reference/protocols/esp_http_client.rst +api-reference/protocols/esp_https_server.rst +api-reference/protocols/esp_spi_slave_protocol.rst +api-reference/protocols/modbus.rst +api-reference/protocols/esp_tls.rst +api-reference/protocols/mdns.rst +api-reference/protocols/index.rst +api-reference/protocols/asio.rst +security/host-based-security-workflows.rst +security/flash-encryption.rst +security/security.rst +security/secure-boot-v2.rst +security/secure-boot-v1.rst +security/index.rst +about.rst +resources.rst +migration-guides/release-5.x/5.2/bluetooth-classic.rst +migration-guides/release-5.x/5.2/ieee802154.rst +migration-guides/release-5.x/5.2/gcc.rst +migration-guides/release-5.x/5.2/protocols.rst +migration-guides/release-5.x/5.2/wifi.rst +migration-guides/release-5.x/5.2/storage.rst +migration-guides/release-5.x/5.2/index.rst +migration-guides/release-5.x/5.2/system.rst +migration-guides/release-5.x/5.2/peripherals.rst +migration-guides/release-5.x/5.3/security.rst +migration-guides/release-5.x/5.3/bluetooth-low-energy.rst +migration-guides/release-5.x/5.3/storage.rst +migration-guides/release-5.x/5.3/index.rst +migration-guides/release-5.x/5.3/system.rst +migration-guides/release-5.x/5.3/peripherals.rst +migration-guides/release-5.x/5.1/ieee802154.rst +migration-guides/release-5.x/5.1/gcc.rst +migration-guides/release-5.x/5.1/networking.rst +migration-guides/release-5.x/5.1/storage.rst +migration-guides/release-5.x/5.1/index.rst +migration-guides/release-5.x/5.1/system.rst +migration-guides/release-5.x/5.1/peripherals.rst +migration-guides/release-5.x/5.0/bluetooth-classic.rst +migration-guides/release-5.x/5.0/gcc.rst +migration-guides/release-5.x/5.0/bluetooth-low-energy.rst +migration-guides/release-5.x/5.0/removed-components.rst +migration-guides/release-5.x/5.0/protocols.rst +migration-guides/release-5.x/5.0/networking.rst +migration-guides/release-5.x/5.0/provisioning.rst +migration-guides/release-5.x/5.0/build-system.rst +migration-guides/release-5.x/5.0/storage.rst +migration-guides/release-5.x/5.0/index.rst +migration-guides/release-5.x/5.0/system.rst +migration-guides/release-5.x/5.0/tools.rst +migration-guides/release-5.x/5.0/peripherals.rst +migration-guides/index.rst +get-started/establish-serial-connection.rst +get-started/linux-macos-setup.rst +get-started/linux-macos-start-project.rst +get-started/windows-setup.rst +get-started/start-project.rst +get-started/flashing-troubleshooting.rst +get-started/windows-start-project.rst +get-started/index.rst +get-started/windows-setup-update.rst +index.rst diff --git a/docs/doxygen/Doxyfile_esp32c5 b/docs/doxygen/Doxyfile_esp32c5 new file mode 100644 index 0000000000..910f295a01 --- /dev/null +++ b/docs/doxygen/Doxyfile_esp32c5 @@ -0,0 +1 @@ +INPUT += \ diff --git a/docs/en/api-guides/jtag-debugging/esp32c5.inc b/docs/en/api-guides/jtag-debugging/esp32c5.inc new file mode 100644 index 0000000000..65ccf72bad --- /dev/null +++ b/docs/en/api-guides/jtag-debugging/esp32c5.inc @@ -0,0 +1,173 @@ +.. This file gets included from other .rst files in this folder. +.. It contains target-specific snippets. +.. Comments and '---' lines act as delimiters. +.. +.. This is necessary mainly because RST doesn't support substitutions +.. (defined in RST, not in Python) inside code blocks. If that is ever implemented, +.. These code blocks can be moved back to the main .rst files, with target-specific +.. file names being replaced by substitutions. + +.. run-openocd + +:: + + openocd -f board/esp32c5-builtin.cfg + +.. |run-openocd-device-name| replace:: ESP32-C5 through built-in USB connection + +--- + +.. run-openocd-output + +:: + + user-name@computer-name:~/esp/esp-idf$ openocd -f board/esp32c5-builtin.cfg + Open On-Chip Debugger v0.11.0-esp32-20221026-85-g0718fffd (2023-01-12-07:28) + Licensed under GNU GPL v2 + For bug reports, read + http://openocd.org/doc/doxygen/bugs.html + Info : only one transport option; autoselect 'jtag' + Info : esp_usb_jtag: VID set to 0x303a and PID to 0x1001 + Info : esp_usb_jtag: capabilities descriptor set to 0x2000 + Warn : Transport "jtag" was already selected + WARNING: ESP flash support is disabled! + force hard breakpoints + Info : Listening on port 6666 for tcl connections + Info : Listening on port 4444 for telnet connections + Info : esp_usb_jtag: serial (60:55:F9:F6:03:3C) + Info : esp_usb_jtag: Device found. Base speed 24000KHz, div range 1 to 255 + Info : clock speed 24000 kHz + Info : JTAG tap: esp32c5.cpu tap/device found: 0x0000dc25 (mfg: 0x612 (Espressif Systems), part: 0x000d, ver: 0x0) + Info : datacount=2 progbufsize=16 + Info : Examined RISC-V core; found 2 harts + Info : hart 0: XLEN=32, misa=0x40903105 + Info : starting gdb server for esp32c5 on 3333 + Info : Listening on port 3333 for gdb connections + +.. |run-openocd-cfg-file-err| replace:: ``Can't find board/esp32c5-builtin.cfg`` + +--- + +.. run-openocd-upload + +:: + + openocd -f board/esp32c5-builtin.cfg -c "program_esp filename.bin 0x10000 verify exit" + +--- + +.. run-openocd-src-linux + +.. code-block:: bash + + src/openocd -f board/esp32c5-builtin.cfg + +--- + +.. run-openocd-src-win + +.. code-block:: batch + + src\openocd -f board/esp32c5-builtin.cfg + +--- + +.. idf-py-openocd-default-cfg + +.. |idf-py-def-cfg| replace:: ``-f board/esp32c5-builtin.cfg`` + +--- + +.. run-openocd-appimage-offset + +:: + + openocd -f board/esp32c5-builtin.cfg -c "init; halt; esp appimage_offset 0x210000" + +--- + +.. openocd-cfg-files + +.. list-table:: OpenOCD configuration files for ESP32-C5 + :widths: 25 75 + :header-rows: 1 + + * - Name + - Description + * - ``board/esp32c5-builtin.cfg`` + - Board configuration file for ESP32-C5 through built-in USB, includes target and adapter configuration. + * - ``board/esp32c5-ftdi.cfg`` + - Board configuration file for ESP32-C5 for via externally connected FTDI-based probe like ESP-Prog, includes target and adapter configuration. + * - ``target/esp32c5.cfg`` + - ESP32-C5 target configuration file. Can be used together with one of the ``interface/`` configuration files. + * - ``interface/esp_usb_jtag.cfg`` + - JTAG adapter configuration file for ESP32-C5. + * - ``interface/ftdi/esp32_devkitj_v1.cfg`` + - JTAG adapter configuration file for ESP-Prog boards. + +--- + +.. openocd-target-specific-config-vars + +--- + +--- + +.. jtag-pins + +.. list-table:: ESP32-C5 pins and JTAG signals + :widths: 25 75 + :header-rows: 1 + + * - ESP32-C5 Pin + - JTAG Signal + * - MTDO / GPIO7 + - TDO + * - MTDI / GPIO5 + - TDI + * - MTCK / GPIO6 + - TCK + * - MTMS / GPIO4 + - TMS + +.. |jtag-sel-gpio| replace:: GPIO15 +.. |jtag-gpio-list| replace:: GPIO4-GPIO7 + +--- + +.. run-openocd-d3 + +:: + + openocd -l openocd_log.txt -d3 -f board/esp32c5-builtin.cfg + +--- + +.. run-openocd-d3-tee + +:: + + openocd -d3 -f board/esp32c5-builtin.cfg 2>&1 | tee openocd.log + +--- + +.. run-gdb-remotelog + +:: + + riscv32-esp-elf-gdb -ex "set remotelogfile gdb_log.txt" + +--- + +.. devkit-defs + +.. |devkit-name| replace:: ESP32-C5 +.. |devkit-name-with-link| replace:: :doc:`ESP32-C5 <../../hw-reference/index>` + +--- + +.. devkit-hw-config + +* Out of the box, ESP32-C5 doesn't need any additional hardware configuration for JTAG debugging. + +--- diff --git a/docs/en/api-guides/partition-tables.rst b/docs/en/api-guides/partition-tables.rst index 932eb773a2..c452e82d47 100644 --- a/docs/en/api-guides/partition-tables.rst +++ b/docs/en/api-guides/partition-tables.rst @@ -89,7 +89,7 @@ The ESP-IDF bootloader ignores any partition types other than ``app`` (0x00) and SubType ~~~~~~~ -{IDF_TARGET_ESP_PHY_REF:default = ":ref:`CONFIG_ESP_PHY_INIT_DATA_IN_PARTITION`", esp32p4="NOT UPDATED YET"} +{IDF_TARGET_ESP_PHY_REF:default = ":ref:`CONFIG_ESP_PHY_INIT_DATA_IN_PARTITION`", esp32p4, esp32c5="NOT UPDATED YET"} The 8-bit SubType field is specific to a given partition type. ESP-IDF currently only specifies the meaning of the subtype field for ``app`` and ``data`` partition types. diff --git a/docs/en/api-reference/peripherals/gpio/esp32c5.inc b/docs/en/api-reference/peripherals/gpio/esp32c5.inc new file mode 100644 index 0000000000..ff86eae9dc --- /dev/null +++ b/docs/en/api-reference/peripherals/gpio/esp32c5.inc @@ -0,0 +1,14 @@ +.. This file gets included from other .rst files in this folder. +.. It contains target-specific snippets. +.. Comments and '---' lines act as delimiters. +.. +.. This is necessary mainly because RST doesn't support substitutions +.. (defined in RST, not in Python) inside code blocks. If that is ever implemented, +.. These code blocks can be moved back to the main .rst files, with target-specific +.. file names being replaced by substitutions. + +.. gpio-summary + + To be updated for C5 + +--- diff --git a/docs/en/api-reference/system/inc/espefuse_summary_ESP32-C5.rst b/docs/en/api-reference/system/inc/espefuse_summary_ESP32-C5.rst new file mode 100644 index 0000000000..f1070d8a43 --- /dev/null +++ b/docs/en/api-reference/system/inc/espefuse_summary_ESP32-C5.rst @@ -0,0 +1,3 @@ +.. code-block:: none + + To be updated for C5 diff --git a/docs/en/api-reference/system/inc/power_management_esp32c5.rst b/docs/en/api-reference/system/inc/power_management_esp32c5.rst new file mode 100644 index 0000000000..239a3cac19 --- /dev/null +++ b/docs/en/api-reference/system/inc/power_management_esp32c5.rst @@ -0,0 +1,4 @@ ++---------------+---------------------------------------+-------------------------------------+ +| Max CPU | Lock Acquisition | CPU and APB Frequencies | +| Frequency Set | | | ++---------------+---------------------------------------+-------------------------------------+ diff --git a/docs/en/api-reference/system/inc/revisions_ESP32-C5.rst b/docs/en/api-reference/system/inc/revisions_ESP32-C5.rst new file mode 100644 index 0000000000..4d9ae1300d --- /dev/null +++ b/docs/en/api-reference/system/inc/revisions_ESP32-C5.rst @@ -0,0 +1,6 @@ + ++--------+------------------------+ +| ECO | Revision (Major.Minor) | ++--------+------------------------+ +| ECO0 | v0.0 | ++--------+------------------------+ diff --git a/docs/en/api-reference/system/inc/show-efuse-table_ESP32-C5.rst b/docs/en/api-reference/system/inc/show-efuse-table_ESP32-C5.rst new file mode 100644 index 0000000000..83365425f1 --- /dev/null +++ b/docs/en/api-reference/system/inc/show-efuse-table_ESP32-C5.rst @@ -0,0 +1,4 @@ + +.. code-block:: none + + To be updated for C5 diff --git a/docs/en/get-started/esp32c5_output_log.inc b/docs/en/get-started/esp32c5_output_log.inc new file mode 100644 index 0000000000..408ee2930b --- /dev/null +++ b/docs/en/get-started/esp32c5_output_log.inc @@ -0,0 +1,5 @@ +.. output_log + +.. code-block:: none + + To be updated for C5 diff --git a/docs/en/security/esp32c5_log.inc b/docs/en/security/esp32c5_log.inc new file mode 100644 index 0000000000..64c5df4264 --- /dev/null +++ b/docs/en/security/esp32c5_log.inc @@ -0,0 +1,17 @@ + +.. first_boot_enc + +.. code-block:: none + + To be updated for C5 + + +------ + +.. already_en_enc + +.. code-block:: none + + To be updated for C5 + +------ diff --git a/docs/zh_CN/api-guides/jtag-debugging/esp32c5.inc b/docs/zh_CN/api-guides/jtag-debugging/esp32c5.inc new file mode 100644 index 0000000000..65ccf72bad --- /dev/null +++ b/docs/zh_CN/api-guides/jtag-debugging/esp32c5.inc @@ -0,0 +1,173 @@ +.. This file gets included from other .rst files in this folder. +.. It contains target-specific snippets. +.. Comments and '---' lines act as delimiters. +.. +.. This is necessary mainly because RST doesn't support substitutions +.. (defined in RST, not in Python) inside code blocks. If that is ever implemented, +.. These code blocks can be moved back to the main .rst files, with target-specific +.. file names being replaced by substitutions. + +.. run-openocd + +:: + + openocd -f board/esp32c5-builtin.cfg + +.. |run-openocd-device-name| replace:: ESP32-C5 through built-in USB connection + +--- + +.. run-openocd-output + +:: + + user-name@computer-name:~/esp/esp-idf$ openocd -f board/esp32c5-builtin.cfg + Open On-Chip Debugger v0.11.0-esp32-20221026-85-g0718fffd (2023-01-12-07:28) + Licensed under GNU GPL v2 + For bug reports, read + http://openocd.org/doc/doxygen/bugs.html + Info : only one transport option; autoselect 'jtag' + Info : esp_usb_jtag: VID set to 0x303a and PID to 0x1001 + Info : esp_usb_jtag: capabilities descriptor set to 0x2000 + Warn : Transport "jtag" was already selected + WARNING: ESP flash support is disabled! + force hard breakpoints + Info : Listening on port 6666 for tcl connections + Info : Listening on port 4444 for telnet connections + Info : esp_usb_jtag: serial (60:55:F9:F6:03:3C) + Info : esp_usb_jtag: Device found. Base speed 24000KHz, div range 1 to 255 + Info : clock speed 24000 kHz + Info : JTAG tap: esp32c5.cpu tap/device found: 0x0000dc25 (mfg: 0x612 (Espressif Systems), part: 0x000d, ver: 0x0) + Info : datacount=2 progbufsize=16 + Info : Examined RISC-V core; found 2 harts + Info : hart 0: XLEN=32, misa=0x40903105 + Info : starting gdb server for esp32c5 on 3333 + Info : Listening on port 3333 for gdb connections + +.. |run-openocd-cfg-file-err| replace:: ``Can't find board/esp32c5-builtin.cfg`` + +--- + +.. run-openocd-upload + +:: + + openocd -f board/esp32c5-builtin.cfg -c "program_esp filename.bin 0x10000 verify exit" + +--- + +.. run-openocd-src-linux + +.. code-block:: bash + + src/openocd -f board/esp32c5-builtin.cfg + +--- + +.. run-openocd-src-win + +.. code-block:: batch + + src\openocd -f board/esp32c5-builtin.cfg + +--- + +.. idf-py-openocd-default-cfg + +.. |idf-py-def-cfg| replace:: ``-f board/esp32c5-builtin.cfg`` + +--- + +.. run-openocd-appimage-offset + +:: + + openocd -f board/esp32c5-builtin.cfg -c "init; halt; esp appimage_offset 0x210000" + +--- + +.. openocd-cfg-files + +.. list-table:: OpenOCD configuration files for ESP32-C5 + :widths: 25 75 + :header-rows: 1 + + * - Name + - Description + * - ``board/esp32c5-builtin.cfg`` + - Board configuration file for ESP32-C5 through built-in USB, includes target and adapter configuration. + * - ``board/esp32c5-ftdi.cfg`` + - Board configuration file for ESP32-C5 for via externally connected FTDI-based probe like ESP-Prog, includes target and adapter configuration. + * - ``target/esp32c5.cfg`` + - ESP32-C5 target configuration file. Can be used together with one of the ``interface/`` configuration files. + * - ``interface/esp_usb_jtag.cfg`` + - JTAG adapter configuration file for ESP32-C5. + * - ``interface/ftdi/esp32_devkitj_v1.cfg`` + - JTAG adapter configuration file for ESP-Prog boards. + +--- + +.. openocd-target-specific-config-vars + +--- + +--- + +.. jtag-pins + +.. list-table:: ESP32-C5 pins and JTAG signals + :widths: 25 75 + :header-rows: 1 + + * - ESP32-C5 Pin + - JTAG Signal + * - MTDO / GPIO7 + - TDO + * - MTDI / GPIO5 + - TDI + * - MTCK / GPIO6 + - TCK + * - MTMS / GPIO4 + - TMS + +.. |jtag-sel-gpio| replace:: GPIO15 +.. |jtag-gpio-list| replace:: GPIO4-GPIO7 + +--- + +.. run-openocd-d3 + +:: + + openocd -l openocd_log.txt -d3 -f board/esp32c5-builtin.cfg + +--- + +.. run-openocd-d3-tee + +:: + + openocd -d3 -f board/esp32c5-builtin.cfg 2>&1 | tee openocd.log + +--- + +.. run-gdb-remotelog + +:: + + riscv32-esp-elf-gdb -ex "set remotelogfile gdb_log.txt" + +--- + +.. devkit-defs + +.. |devkit-name| replace:: ESP32-C5 +.. |devkit-name-with-link| replace:: :doc:`ESP32-C5 <../../hw-reference/index>` + +--- + +.. devkit-hw-config + +* Out of the box, ESP32-C5 doesn't need any additional hardware configuration for JTAG debugging. + +--- diff --git a/docs/zh_CN/api-guides/partition-tables.rst b/docs/zh_CN/api-guides/partition-tables.rst index 69a26b5faf..8364ed0dc5 100644 --- a/docs/zh_CN/api-guides/partition-tables.rst +++ b/docs/zh_CN/api-guides/partition-tables.rst @@ -89,7 +89,7 @@ Type 字段可以指定为 app (0x00) 或者 data (0x01),也可以直接使用 SubType 字段 ~~~~~~~~~~~~ -{IDF_TARGET_ESP_PHY_REF:default = ":ref:`CONFIG_ESP_PHY_INIT_DATA_IN_PARTITION`", esp32p4 = "NOT UPDATED YET"} +{IDF_TARGET_ESP_PHY_REF:default = ":ref:`CONFIG_ESP_PHY_INIT_DATA_IN_PARTITION`", esp32p4, esp32c5 = "NOT UPDATED YET"} SubType 字段长度为 8 bit,内容与具体分区 Type 有关。目前,esp-idf 仅仅规定了 “app” 和 “data” 两种分区类型的子类型含义。 diff --git a/docs/zh_CN/api-reference/peripherals/gpio/esp32c5.inc b/docs/zh_CN/api-reference/peripherals/gpio/esp32c5.inc new file mode 100644 index 0000000000..ff86eae9dc --- /dev/null +++ b/docs/zh_CN/api-reference/peripherals/gpio/esp32c5.inc @@ -0,0 +1,14 @@ +.. This file gets included from other .rst files in this folder. +.. It contains target-specific snippets. +.. Comments and '---' lines act as delimiters. +.. +.. This is necessary mainly because RST doesn't support substitutions +.. (defined in RST, not in Python) inside code blocks. If that is ever implemented, +.. These code blocks can be moved back to the main .rst files, with target-specific +.. file names being replaced by substitutions. + +.. gpio-summary + + To be updated for C5 + +--- diff --git a/docs/zh_CN/api-reference/system/inc/espefuse_summary_ESP32-C5.rst b/docs/zh_CN/api-reference/system/inc/espefuse_summary_ESP32-C5.rst new file mode 100644 index 0000000000..f1070d8a43 --- /dev/null +++ b/docs/zh_CN/api-reference/system/inc/espefuse_summary_ESP32-C5.rst @@ -0,0 +1,3 @@ +.. code-block:: none + + To be updated for C5 diff --git a/docs/zh_CN/api-reference/system/inc/power_management_esp32c5.rst b/docs/zh_CN/api-reference/system/inc/power_management_esp32c5.rst new file mode 100644 index 0000000000..239a3cac19 --- /dev/null +++ b/docs/zh_CN/api-reference/system/inc/power_management_esp32c5.rst @@ -0,0 +1,4 @@ ++---------------+---------------------------------------+-------------------------------------+ +| Max CPU | Lock Acquisition | CPU and APB Frequencies | +| Frequency Set | | | ++---------------+---------------------------------------+-------------------------------------+ diff --git a/docs/zh_CN/api-reference/system/inc/revisions_ESP32-C5.rst b/docs/zh_CN/api-reference/system/inc/revisions_ESP32-C5.rst new file mode 100644 index 0000000000..4d9ae1300d --- /dev/null +++ b/docs/zh_CN/api-reference/system/inc/revisions_ESP32-C5.rst @@ -0,0 +1,6 @@ + ++--------+------------------------+ +| ECO | Revision (Major.Minor) | ++--------+------------------------+ +| ECO0 | v0.0 | ++--------+------------------------+ diff --git a/docs/zh_CN/api-reference/system/inc/show-efuse-table_ESP32-C5.rst b/docs/zh_CN/api-reference/system/inc/show-efuse-table_ESP32-C5.rst new file mode 100644 index 0000000000..83365425f1 --- /dev/null +++ b/docs/zh_CN/api-reference/system/inc/show-efuse-table_ESP32-C5.rst @@ -0,0 +1,4 @@ + +.. code-block:: none + + To be updated for C5 diff --git a/docs/zh_CN/get-started/esp32c5_output_log.inc b/docs/zh_CN/get-started/esp32c5_output_log.inc new file mode 100644 index 0000000000..408ee2930b --- /dev/null +++ b/docs/zh_CN/get-started/esp32c5_output_log.inc @@ -0,0 +1,5 @@ +.. output_log + +.. code-block:: none + + To be updated for C5 diff --git a/docs/zh_CN/security/esp32c5_log.inc b/docs/zh_CN/security/esp32c5_log.inc new file mode 100644 index 0000000000..64c5df4264 --- /dev/null +++ b/docs/zh_CN/security/esp32c5_log.inc @@ -0,0 +1,17 @@ + +.. first_boot_enc + +.. code-block:: none + + To be updated for C5 + + +------ + +.. already_en_enc + +.. code-block:: none + + To be updated for C5 + +------