Answer the question
In order to leave comments, you need to log in
Why do ADCs in esp32 wroom have mutual guidance or how to read correctly?
Hello.
There is an ESP32 Wroom and 2 sensors that output a voltage of 0-3.3 V. I am trying to get a value from them using ADC:
#define SENSOR_ADC_PIN ADC1_CHANNEL_0 //-- ADC1 channel 0: GPIO 36
#define ENDSWITCH_ADC_PIN ADC1_CHANNEL_5 //-- ADC1 channel 5: GPIO 33
....
adc1_config_width(ADC_WIDTH_BIT_12);
adc1_config_channel_atten(SENSOR_ADC_PIN, ADC_ATTEN_DB_11);
adc1_config_channel_atten(ENDSWITCH_ADC_PIN, ADC_ATTEN_DB_11);
....
loop() {
...
_sensorADCRAW = adc1_get_raw(SENSOR_ADC_PIN);
_endSwitchADCRAW = adc1_get_raw(ENDSWITCH_ADC_PIN);
...
}
...
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question