dzurikmiroslav / esp32-evse

ESP32 EVSE firmware
GNU General Public License v3.0
56 stars 21 forks source link

ADC_ATTEN_DB_11 is deprecated. New warning after #de2fd29 update #28

Closed Alfred1975 closed 7 months ago

Alfred1975 commented 7 months ago

Also after #de2fd29 update I receive errors like below:

51 | ADC_ATTEN_DB_11 attribute((deprecated)) = ADC_ATTEN_DB_12, ///<This is deprecated, it behaves the same as ADC_ATTEN_DB_12
| ^~~~~~~ [983/1062] Building C object esp-idf/peripherals/CMakeFiles/__idf_peripherals.dir/src/energy_meter.c.obj D:/esp32-evse/components/peripherals/src/energy_meter.c: In function 'energy_meter_init': D:/esp32-evse/components/peripherals/src/energy_meter.c:280:5: warning: 'ADC_ATTEN_DB_11' is deprecated [-Wdeprecated-declarations]

I need to change all to ADC_ATTEN_DB_12 in your code?

Regards, Alfred

dzurikmiroslav commented 7 months ago

You probably fetch master branch of ESP-IDF, currently latest stable release is 5.1.1 When you check line 46 at https://github.com/espressif/esp-idf/blob/v5.1.1/components/hal/include/hal/adc_types.h there is no deprecated warning. Master branch of ESP-IDF is does not have to be compilable, you should use stable tagged version...

After all commits in project I have Github action, which compile entire project (I understand, different behavior may occur depending on the operating system), currently master branch is compilable https://github.com/dzurikmiroslav/esp32-evse/actions

This could also cause other compilation problems like https://github.com/dzurikmiroslav/esp32-evse/issues/27