File tree Expand file tree Collapse file tree 2 files changed +4
-4
lines changed
src/current_sense/hardware_specific/esp32 Expand file tree Collapse file tree 2 files changed +4
-4
lines changed Original file line number Diff line number Diff line change 77#define SIMPLEFOC_ADC_RES 12
88
99
10- #ifdef CONFIG_IDF_TARGET_ESP32 // if esp32 variant
10+ #if CONFIG_IDF_TARGET_ESP32 // if esp32 variant
1111
1212#include " soc/sens_reg.h"
1313
@@ -73,7 +73,7 @@ uint16_t IRAM_ATTR adcRead(uint8_t pin)
7373 return value;
7474}
7575
76- #elif (defined( CONFIG_IDF_TARGET_ESP32S2) || defined( CONFIG_IDF_TARGET_ESP32S3)) // if esp32 s2 or s3 variants
76+ #elif CONFIG_IDF_TARGET_ESP32S2 || CONFIG_IDF_TARGET_ESP32S3 // if esp32 s2 or s3 variants
7777
7878#include " soc/sens_reg.h"
7979
@@ -165,7 +165,7 @@ bool IRAM_ATTR adcInit(uint8_t pin){
165165 analogSetPinAttenuation (pin, SIMPLEFOC_ADC_ATTEN);
166166 analogRead (pin);
167167
168- #ifdef CONFIG_IDF_TARGET_ESP32 // if esp32 variant
168+ #if CONFIG_IDF_TARGET_ESP32 // if esp32 variant
169169 __configFastADCs ();
170170#endif
171171
Original file line number Diff line number Diff line change 11#ifndef SIMPLEFOC_ESP32_HAL_ADC_DRIVER_H_
22#define SIMPLEFOC_ESP32_HAL_ADC_DRIVER_H_
33
4- #if defined(ESP_H ) && defined(ARDUINO_ARCH_ESP32 ) && defined( SOC_MCPWM_SUPPORTED ) && !defined( SIMPLEFOC_ESP32_USELEDC )
4+ #if defined(ESP_H ) && defined(ARDUINO_ARCH_ESP32 )
55
66/**
77 * Get ADC value for pin
You can’t perform that action at this time.
0 commit comments