get-started-wrover-kit.rst 16 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385
  1. ESP-WROVER-KIT V4.1 Getting Started Guide
  2. =========================================
  3. :link_to_translation:`zh_CN:[中文]`
  4. This guide shows how to get started with the ESP-WROVER-KIT V4.1 development board and also provides information about its functionality and configuration options. For the description of other ESP-WROVER-KIT versions, please check :doc:`../../hw-reference/index`.
  5. What You Need
  6. -------------
  7. * :ref:`ESP-WROVER-KIT V4.1 board <get-started-esp-wrover-kit-v4.1-board-front>`
  8. * USB 2.0 cable(A to Micro-B)
  9. * Computer running Windows, Linux, or macOS
  10. You can skip the introduction sections and go directly to Section `Start Application Development`_.
  11. Overview
  12. --------
  13. ESP-WROVER-KIT is an ESP32-based development board produced by `Espressif <https://espressif.com>`_.
  14. ESP-WROVER-KIT features the following integrated components:
  15. - ESP32-WROVER-B module
  16. - LCD screen
  17. - MicroSD card slot
  18. Its another distinguishing feature is the embedded FTDI FT2232HL chip - an advanced multi-interface USB bridge. This chip enables to use JTAG for direct debugging of ESP32 through the USB interface without a separate JTAG debugger. ESP-WROVER-KIT makes development convenient, easy, and cost-effective.
  19. Most of the ESP32 I/O pins are broken out to the board's pin headers for easy access.
  20. .. note::
  21. ESP32's GPIO16 and GPIO17 are used as chip select and clock signals for PSRAM. By default, the two GPIOs are not broken out to the board's pin headers in order to ensure reliable performance.
  22. Functionality Overview
  23. ----------------------
  24. The block diagram below shows the main components of ESP-WROVER-KIT and their interconnections.
  25. .. figure:: ../../../_static/esp-wrover-kit-block-diagram.png
  26. :align: center
  27. :alt: ESP-WROVER-KIT block diagram
  28. :figclass: align-center
  29. ESP-WROVER-KIT block diagram
  30. Functional Description
  31. ----------------------
  32. The following two figures and the table below describe the key components, interfaces, and controls of the ESP-WROVER-KIT board.
  33. .. _get-started-esp-wrover-kit-v4.1-board-front:
  34. .. figure:: ../../../_static/esp-wrover-kit-v4.1-layout-front.png
  35. :align: center
  36. :alt: ESP-WROVER-KIT board layout - front
  37. :figclass: align-center
  38. ESP-WROVER-KIT board layout - front
  39. .. _get-started-esp-wrover-kit-v4.1-board-back:
  40. .. figure:: ../../../_static/esp-wrover-kit-v4.1-layout-back.png
  41. :align: center
  42. :alt: ESP-WROVER-KIT board layout - back
  43. :figclass: align-center
  44. ESP-WROVER-KIT board layout - back
  45. The table below provides description in the following manner:
  46. - Starting from the first picture's top right corner and going clockwise
  47. - Then moving on to the second picture
  48. ================== =================================================================================================================================
  49. Key Component Description
  50. ================== =================================================================================================================================
  51. FT2232 The FT2232 chip serves as a multi-protocol USB-to-serial bridge which can be programmed and controlled via USB to provide communication with ESP32. FT2232 also features USB-to-JTAG interface which is available on channel A of the chip, while USB-to-serial is on channel B. The FT2232 chip enhances user-friendliness in terms of application development and debugging. See `ESP-WROVER-KIT V4.1 schematic`_.
  52. 32.768 kHz External precision 32.768 kHz crystal oscillator serves as a clock with low-power consumption while the chip is in Deep-sleep mode.
  53. 0R Zero-ohm resistor intended as a placeholder for a current shunt, can be desoldered or replaced with a current shunt to facilitate the measurement of ESP32's current consumption in different modes.
  54. ESP32-WROVER-B This EPS32 module features 64-Mbit PSRAM for flexible extended storage and data processing capabilities.
  55. Diagnostic LEDs Four red LEDs connected to the GPIO pins of FT2232. Intended for future use.
  56. UART Serial port. The serial TX/RX signals of FT2232 and ESP32 are broken out to the inward and outward sides of JP2 respectively. By default, these pairs of pins are connected with jumpers. To use ESP32's serial interface, remove the jumpers and connect another external serial device to the respective pins.
  57. SPI By default, ESP32 uses its SPI interface to access flash and PSRAM memory inside the module. Use these pins to connect ESP32 to another SPI device. In this case, an extra chip select (CS) signal is needed. Please note that the voltage of this interface is 3.3V.
  58. CTS/RTS Serial port flow control signals: the pins are not connected to the circuitry by default. To enable them, short the respective pins of JP14 with jumpers.
  59. JTAG JTAG interface. JTAG signals of FT2232 and ESP32 are broken out to the inward and outward sides of JP2 respectively. By default, these pairs of pins are disconnected. To enable JTAG, short the respective pins with jumpers as shown in Section `Setup Options`_.
  60. USB Port USB interface. Power supply for the board as well as the communication interface between a computer and the board.
  61. EN Button Reset button.
  62. Boot Button Download button. Holding down **Boot** and then pressing **EN** initiates Firmware Download mode for downloading firmware through the serial port.
  63. Power Switch Power On/Off Switch. Toggling toward the **Boot** button powers the board on, toggling away from **Boot** powers the board off.
  64. Power Selector Power supply selector interface. The board can be powered either via USB or via the 5V Input interface. Select the power source with a jumper. For more details, see Section `Setup Options`_, jumper header JP7.
  65. 5V Input The 5V power supply interface can be more convenient when the board is operating autonomously (not connected to a computer).
  66. 5V Power On LED This red LED turns on when power is supplied to the board, either from **USB** or **5V Input**.
  67. LDO NCP1117(1A). 5V-to-3.3V LDO. NCP1117 can provide a maximum current of 1A. The LDO on the board has a fixed output voltage. Although, the user can install an LDO with adjustable output voltage. For details, please refer to `ESP-WROVER-KIT V4.1 schematic`_.
  68. Camera Connector Camera interface, a standard OV7670 camera module.
  69. RGB LED Red, green and blue (RGB) light emitting diodes (LEDs), can be controlled by pulse width modulation (PWM).
  70. I/O Connector All the pins on the ESP32 module are broken out to pin headers. You can program ESP32 to enable multiple functions, such as PWM, ADC, DAC, I2C, I2S, SPI, etc.
  71. MicroSD Card Slot Useful for developing applications that access MicroSD card for data storage and retrieval.
  72. LCD Support for mounting and interfacing a 3.2” SPI (standard 4-wire Serial Peripheral Interface) LCD, as shown on figure :ref:`get-started-esp-wrover-kit-v4.1-board-back`.
  73. ================== =================================================================================================================================
  74. .. _get-started-esp-wrover-kit-v4.1-setup-options:
  75. Setup Options
  76. -------------
  77. There are three jumper blocks available to set up the board functionality. The most frequently required options are listed in the table below.
  78. ======= ================ =========================================================
  79. Header Jumper Setting Description of Functionality
  80. ======= ================ =========================================================
  81. JP7 |jp7-ext_5v| Power ESP-WROVER-KIT via an external power supply
  82. JP7 |jp7-usb_5v| Power ESP-WROVER-KIT via USB
  83. JP2 |jp2-jtag| Enable JTAG functionality
  84. JP2 |jp2-tx-rx| Enable UART communication
  85. JP14 |jp14| Enable RTS/CTS flow control for serial communication
  86. ======= ================ =========================================================
  87. Allocation of ESP32 Pins
  88. ------------------------
  89. Some pins / terminals of ESP32 are allocated for use with the onboard or external hardware. If that hardware is not used, e.g., nothing is plugged into the Camera (JP4) header, then these GPIOs can be used for other purposes.
  90. Some of the pins, such as GPIO0 or GPIO2, have multiple functions and some of them are shared among onboard and external peripheral devices. Certain combinations of peripherals cannot work together. For example, it is not possible to do JTAG debugging of an application that is using SD card, because several pins are shared by JTAG and the SD card slot.
  91. In other cases, peripherals can coexist under certain conditions. This is applicable to, for example, LCD screen and SD card that share only a single pin GPIO21. This pin is used to provide D/C (Data / Control) signal for the LCD as well as the CD (Card Detect) signal read from the SD card slot. If the card detect functionality is not essential, then it may be disabled by removing R167, so both LCD and SD may operate together.
  92. For more details on which pins are shared among which peripherals, please refer to the table in the next section.
  93. Main I/O Connector / JP1
  94. ^^^^^^^^^^^^^^^^^^^^^^^^
  95. The JP1 connector consists of 14x2 male pins whose functions are shown in the middle two "I/O" columns of the table below. The two "Shared With" columns on both sides describe where else on the board a certain GPIO is used.
  96. ===================== ===== ===== =====================
  97. Shared With I/O I/O Shared With
  98. ===================== ===== ===== =====================
  99. n/a 3.3V GND n/a
  100. NC/XTAL IO32 IO33 NC/XTAL
  101. JTAG, MicroSD IO12 IO13 JTAG, MicroSD
  102. JTAG, MicroSD IO14 IO27 Camera
  103. Camera IO26 IO25 Camera, LCD
  104. Camera IO35 IO34 Camera
  105. Camera IO39 IO36 Camera
  106. JTAG EN IO23 Camera, LCD
  107. Camera, LCD IO22 IO21 Camera, LCD, MicroSD
  108. Camera, LCD IO19 IO18 Camera, LCD
  109. Camera, LCD IO5 IO17 PSRAM
  110. PSRAM IO16 IO4 LED, Camera, MicroSD
  111. Camera, LED, Boot IO0 IO2 LED, MicroSD
  112. JTAG, MicroSD IO15 5V
  113. ===================== ===== ===== =====================
  114. Legend:
  115. * NC/XTAL - :ref:`32.768 kHz Oscillator <get-started-esp-wrover-kit-v4.1-xtal>`
  116. * JTAG - :ref:`JTAG / JP2 <get-started-esp-wrover-kit-v4.1-jtag-header>`
  117. * Boot - Boot button / SW2
  118. * Camera - :ref:`Camera / JP4 <get-started-esp-wrover-kit-v4.1-camera-header>`
  119. * LED - :ref:`RGB LED <get-started-esp-wrover-kit-v4.1-rgb-led-connections>`
  120. * MicroSD - :ref:`MicroSD Card / J4 <get-started-esp-wrover-kit-v4.1-microsd-card-slot>`
  121. * LCD - :ref:`LCD / U5 <get-started-esp-wrover-kit-v4.1-lcd-connector>`
  122. * PSRAM - ESP32-WROVER-B's PSRAM
  123. .. _get-started-esp-wrover-kit-v4.1-xtal:
  124. 32.768 kHz Oscillator
  125. ^^^^^^^^^^^^^^^^^^^^^
  126. ==== ==========
  127. . ESP32 Pin
  128. ==== ==========
  129. 1 GPIO32
  130. 2 GPIO33
  131. ==== ==========
  132. .. note::
  133. Since GPIO32 and GPIO33 are connected to the oscillator by default, they are not connected to the JP1 I/O connector to maintain signal integrity. This allocation may be changed from the oscillator to JP1 by desoldering the zero-ohm resistors from positions R11 / R23 and re-soldering them to positions R12 / R24.
  134. .. _get-started-esp-wrover-kit-v4.1-spi-flash-header:
  135. SPI Flash / JP2
  136. ^^^^^^^^^^^^^^^
  137. ==== =============
  138. . ESP32 Pin
  139. ==== =============
  140. 1 CLK / GPIO6
  141. 2 SD0 / GPIO7
  142. 3 SD1 / GPIO8
  143. 4 SD2 / GPIO9
  144. 5 SD3 / GPIO10
  145. 6 CMD / GPIO11
  146. ==== =============
  147. .. important::
  148. The module's flash bus is connected to the jumper block JP2 through zero-ohm resistors R140 ~ R145. If the flash memory needs to operate at the frequency of 80 MHz, for reasons such as improving the integrity of bus signals, you can desolder these resistors to disconnect the module's flash bus from the pin header JP2.
  149. .. _get-started-esp-wrover-kit-v4.1-jtag-header:
  150. JTAG / JP2
  151. ^^^^^^^^^^
  152. ==== ============== =============
  153. . ESP32 Pin JTAG Signal
  154. ==== ============== =============
  155. 1 EN TRST_N
  156. 2 MTMS / GPIO14 TMS
  157. 3 MTDO / GPIO15 TDO
  158. 4 MTDI / GPIO12 TDI
  159. 5 MTCK / GPIO13 TCK
  160. ==== ============== =============
  161. .. _get-started-esp-wrover-kit-v4.1-camera-header:
  162. Camera / JP4
  163. ^^^^^^^^^^^^
  164. ==== ========== =============================
  165. . ESP32 Pin Camera Signal
  166. ==== ========== =============================
  167. 1 n/a 3.3V
  168. 2 n/a Ground
  169. 3 GPIO27 SIO_C / SCCB Clock
  170. 4 GPIO26 SIO_D / SCCB Data
  171. 5 GPIO25 VSYNC / Vertical Sync
  172. 6 GPIO23 HREF / Horizontal Reference
  173. 7 GPIO22 PCLK / Pixel Clock
  174. 8 GPIO21 XCLK / System Clock
  175. 9 GPIO35 D7 / Pixel Data Bit 7
  176. 10 GPIO34 D6 / Pixel Data Bit 6
  177. 11 GPIO39 D5 / Pixel Data Bit 5
  178. 12 GPIO36 D4 / Pixel Data Bit 4
  179. 13 GPIO19 D3 / Pixel Data Bit 3
  180. 14 GPIO18 D2 / Pixel Data Bit 2
  181. 15 GPIO5 D1 / Pixel Data Bit 1
  182. 16 GPIO4 D0 / Pixel Data Bit 0
  183. 17 GPIO0 RESET / Camera Reset
  184. 18 n/a PWDN / Camera Power Down
  185. ==== ========== =============================
  186. * Signals D0 .. D7 denote camera data bus
  187. .. _get-started-esp-wrover-kit-v4.1-rgb-led-connections:
  188. RGB LED
  189. ^^^^^^^
  190. ==== ========== =========
  191. . ESP32 Pin RGB LED
  192. ==== ========== =========
  193. 1 GPIO0 Red
  194. 2 GPIO2 Green
  195. 3 GPIO4 Blue
  196. ==== ========== =========
  197. .. _get-started-esp-wrover-kit-v4.1-microsd-card-slot:
  198. MicroSD Card
  199. ^^^^^^^^^^^^
  200. ==== ============== ===============
  201. . ESP32 Pin MicroSD Signal
  202. ==== ============== ===============
  203. 1 MTDI / GPIO12 DATA2
  204. 2 MTCK / GPIO13 CD / DATA3
  205. 3 MTDO / GPIO15 CMD
  206. 4 MTMS / GPIO14 CLK
  207. 5 GPIO2 DATA0
  208. 6 GPIO4 DATA1
  209. 7 GPIO21 CD
  210. ==== ============== ===============
  211. .. _get-started-esp-wrover-kit-v4.1-lcd-connector:
  212. LCD / U5
  213. ^^^^^^^^
  214. ==== ============== ===============
  215. . ESP32 Pin LCD Signal
  216. ==== ============== ===============
  217. 1 GPIO18 RESET
  218. 2 GPIO19 SCL
  219. 3 GPIO21 D/C
  220. 4 GPIO22 CS
  221. 5 GPIO23 SDA
  222. 6 GPIO25 SDO
  223. 7 GPIO5 Backlight
  224. ==== ============== ===============
  225. .. _get-started-esp-wrover-kit-start-development:
  226. Start Application Development
  227. -----------------------------
  228. Before powering up your ESP-WROVER-KIT, please make sure that the board is in good condition with no obvious signs of damage.
  229. Initial Setup
  230. ^^^^^^^^^^^^^
  231. Please set only the following jumpers shown in the pictures below:
  232. - Select USB as the power source using the jumper block JP7.
  233. - Enable UART communication using the jumper block JP2.
  234. ======================== ==========================
  235. Power up from USB port Enable UART communication
  236. ======================== ==========================
  237. |jp7-usb_5v| |jp2-tx-rx|
  238. ======================== ==========================
  239. Do not install any other jumpers.
  240. Turn the **Power Switch** to ON, the **5V Power On LED** should light up.
  241. Now to Development
  242. ^^^^^^^^^^^^^^^^^^
  243. Please proceed to :doc:`../../get-started/index`, where Section :ref:`get-started-step-by-step` will quickly help you set up the development environment and then flash an example project onto your board.
  244. Related Documents
  245. -----------------
  246. * `ESP-WROVER-KIT V4.1 schematic`_ (PDF)
  247. * `ESP32 Datasheet <https://www.espressif.com/sites/default/files/documentation/esp32_datasheet_en.pdf>`_ (PDF)
  248. * `ESP32-WROVER-B Datasheet <https://espressif.com/sites/default/files/documentation/esp32-wrover-b_datasheet_en.pdf>`_ (PDF)
  249. * :doc:`../../api-guides/jtag-debugging/index`
  250. * :doc:`../../hw-reference/index`
  251. .. |jp7-ext_5v| image:: ../../../_static/esp-wrover-kit-v4.1-jp7-ext_5v.jpg
  252. .. |jp7-usb_5v| image:: ../../../_static/esp-wrover-kit-v4.1-jp7-usb_5v.jpg
  253. .. |jp2-jtag| image:: ../../../_static/esp-wrover-kit-v4.1-jp2-jtag.jpg
  254. .. |jp2-tx-rx| image:: ../../../_static/esp-wrover-kit-v4.1-jp2-tx-rx.jpg
  255. .. |jp14| image:: ../../../_static/esp-wrover-kit-v4.1-jp14.jpg
  256. .. _ESP-WROVER-KIT V4.1 schematic: https://dl.espressif.com/dl/schematics/ESP-WROVER-KIT_V4_1.pdf
  257. .. toctree::
  258. :hidden:
  259. get-started-wrover-kit-v3.rst
  260. get-started-wrover-kit-v2.rst