🛠 ADC 12 bits et capteur de température : piège du date code

ESP32-H2 · intermediaire · Schéma : IMG-esp32-h2-intermediaire-3-h2-adc-capteur-interne.svg — Blocs analogiques du H2 : ADC SAR 12 bits 5 canaux, capteur de température et comparateur analogique, sans DAC, reliés à la console USB-Serial/JTAG.

The ESP32-H2 integrates a 12-bit SAR ADC with up to 5 channels, a temperature sensor, and an analog voltage comparator (PAD) — but no DAC in its peripheral set. Tutorial: read the internal temperature sensor and an analog input, then display both on the USB-Serial/JTAG console (GPIO26/27; keep them reserved for debugging until your product is validated). A pitfall documented by Espressif: ADC accuracy and range depend on the manufacturing date — chips manufactured before and after date code D/C 342023 (shielded components) have different characteristics, and a mixed batch may behave strangely. Note your module’s part number and batch, then calibrate. Plan your pins from the schematic stage: only 19 GPIOs, 2 UARTs, and a single general-purpose SPI (the flash SPI ports on QFN32 packages with SiP flash are not exposed). Full exercise: every 10 s, read temperature + ADC, send a BLE 5 packet, then enter deep-sleep at 7 µA with timer wake-up — ensuring your wake-up pins are indeed in the LP domain.

Other tutorials for this board

Code examples for this board

← Back to the board 🛠 All tutorials