We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 5dffc7b + 8268acf commit 1e1ace5Copy full SHA for 1e1ace5
src/current_sense/hardware_specific/esp32/esp32_adc_driver.cpp
@@ -162,8 +162,8 @@ bool IRAM_ATTR adcInit(uint8_t pin){
162
analogReadResolution(SIMPLEFOC_ADC_RES);
163
}
164
pinMode(pin, ANALOG);
165
- analogSetPinAttenuation(pin, SIMPLEFOC_ADC_ATTEN);
166
analogRead(pin);
+ analogSetPinAttenuation(pin, SIMPLEFOC_ADC_ATTEN);
167
168
#if CONFIG_IDF_TARGET_ESP32 // if esp32 variant
169
__configFastADCs();
0 commit comments