4) ESP32 Potentiometer Reading using ADC | Arduino IDE Tutorial.
Автор: ShyberDev
Загружено: 2025-08-21
Просмотров: 34
Описание:
🔴 ESP32 Potentiometer Reading using ADC | Arduino IDE Tutorial 🔴
In this video, I explain how to read analog values from a potentiometer using the ESP32 ADC (Analog to Digital Converter) and display the readings in the Serial Monitor.
✨ What you will learn in this project:
✔ What ADC pins are on ESP32
✔ How to connect a potentiometer to ESP32
✔ Using analogRead() function in Arduino IDE
✔ Printing values on Serial Monitor
✔ Difference between ADC1 and ADC2 pins
🛠️ Connections Used:
Potentiometer middle pin → GPIO34 (ADC1_CH6)
Potentiometer side pin → 3.3V
Other side pin → GND
✅ ESP32 ADC Pins
The ESP32 has 2 ADC units:
ADC1 → 8 channels (GPIO 32–39)
ADC2 → 10 channels (GPIO 0, 2, 4, 12–15, 25–27)
So in total, 18 ADC channels.
---
📌 Details:
ADC1 Channels:
GPIO32 → ADC1_CH4
GPIO33 → ADC1_CH5
GPIO34 → ADC1_CH6
GPIO35 → ADC1_CH7
GPIO36 (VP) → ADC1_CH0
GPIO39 (VN) → ADC1_CH3
GPIO37, GPIO38 → (on some modules, not always broken out)
ADC2 Channels:
GPIO0 → ADC2_CH1
GPIO2 → ADC2_CH2
GPIO4 → ADC2_CH0
GPIO12 → ADC2_CH5
GPIO13 → ADC2_CH4
GPIO14 → ADC2_CH6
GPIO15 → ADC2_CH3
GPIO25 → ADC2_CH8
GPIO26 → ADC2_CH9
GPIO27 → ADC2_CH7
⚠️ Note: ADC2 channels cannot be used when Wi-Fi is active, because Wi-Fi internally uses ADC2. So for reliable analog readings, always prefer ADC1 pins (GPIO 32–39).
👉 Perfect for beginners learning ESP32 ADC and sensor interfacing.
Don’t forget to Like 👍 | Share 🔗 | Subscribe 🔔 for more ESP32 tutorials.
Повторяем попытку...
Доступные форматы для скачивания:
Скачать видео
-
Информация по загрузке: