esp32c3.inc 2.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119
  1. .. This file gets included from other .rst files in this folder.
  2. .. It contains target-specific snippets.
  3. .. Comments and '---' lines act as delimiters.
  4. ..
  5. .. This is necessary mainly because RST doesn't support substitutions
  6. .. (defined in RST, not in Python) inside code blocks. If that is ever implemented,
  7. .. These code blocks can be moved back to the main .rst files, with target-specific
  8. .. file names being replaced by substitutions.
  9. .. gpio-summary
  10. {IDF_TARGET_NAME} 芯片具有 22 个物理 GPIO 管脚(GPIO0 ~ GPIO21)。每个管脚都可用作一个通用 IO,或连接一个内部的外设信号。通过 GPIO 交换矩阵和 IO MUX,可配置外设模块的输入信号来源于任何的 IO 管脚,并且外设模块的输出信号也可连接到任意 IO 管脚。这些模块共同组成了芯片的 IO 控制。更多详细信息,请参阅 *{IDF_TARGET_NAME} 技术参考手册* > *IO MUX 和 GPIO 矩阵(GPIO、IO_MUX)* [`PDF <{IDF_TARGET_TRM_CN_URL}#iomuxgpio>`__]。
  11. 下表提供了各管脚的详细信息,部分 GPIO 具有特殊的使用限制,具体可参考表中的注释列。
  12. .. list-table::
  13. :header-rows: 1
  14. :widths: 12 12 22
  15. * - GPIO
  16. - 模拟功能
  17. - 注释
  18. * - GPIO0
  19. - ADC1_CH0
  20. - RTC
  21. * - GPIO1
  22. - ADC1_CH1
  23. - RTC
  24. * - GPIO2
  25. - ADC1_CH2
  26. - Strapping 管脚;RTC
  27. * - GPIO3
  28. - ADC1_CH3
  29. - RTC
  30. * - GPIO4
  31. - ADC1_CH4
  32. - RTC
  33. * - GPIO5
  34. - ADC2_CH0
  35. - RTC
  36. * - GPIO6
  37. -
  38. -
  39. * - GPIO7
  40. -
  41. -
  42. * - GPIO8
  43. -
  44. - Strapping 管脚
  45. * - GPIO9
  46. -
  47. - Strapping 管脚
  48. * - GPIO10
  49. -
  50. -
  51. * - GPIO11
  52. -
  53. -
  54. * - GPIO12
  55. -
  56. - SPI0/1
  57. * - GPIO13
  58. -
  59. - SPI0/1
  60. * - GPIO14
  61. -
  62. - SPI0/1
  63. * - GPIO15
  64. -
  65. - SPI0/1
  66. * - GPIO16
  67. -
  68. - SPI0/1
  69. * - GPIO17
  70. -
  71. - SPI0/1
  72. * - GPIO18
  73. -
  74. - USB-JTAG
  75. * - GPIO19
  76. -
  77. - USB-JTAG
  78. * - GPIO20
  79. -
  80. -
  81. * - GPIO21
  82. -
  83. -
  84. .. note::
  85. - Strapping 管脚:GPIO2、GPIO8、和 GPIO9 是 Strapping 管脚。更多信息请参考 `ESP32-C3 技术规格书 <{IDF_TARGET_DATASHEET_CN_URL}>`_。
  86. - SPI0/1:GPIO12-17 通常用于 SPI flash 和 PSRAM,不推荐用于其他用途。
  87. - USB-JTAG:GPIO18 和 GPIO19 默认用于 USB-JTAG。用做 GPIO 时驱动程序将禁用 USB-JTAG。
  88. - RTC:GPIO0-5 可用于将芯片从 Deep-sleep 模式中唤醒,其他 GPIO 仅能将芯片从 Light-sleep 模式中唤醒。更多信息请参考 :ref:`唤醒源<api-reference-wakeup-source>` 章节。
  89. ---