use analogReadMilliVolts
on ESP32 platform for adc usage when expecting device_class voltage
#3239
-
Component nameadc Link to component documentation on our websitehttps://esphome.io/components/sensor/adc.html Describe the enhancementI would like to use the auto corrected voltage reading by the analogReadMilliVolts, when my adc sensor is using device_class This should be used to show the chip-wise corrected values for voltage readings (e.g. battery) instead of having to check each chips correction value in fuses area (refs: https://wiki.seeedstudio.com/XIAO_ESP32C3_Getting_Started/#check-the-battery-voltage) Use casesReading the corrected battery voltage and less of an assumption. Anything else?No response |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 1 reply
-
🏷️ I've automatically added the |
Beta Was this translation helpful? Give feedback.
-
The esphome adc component uses the chip's correction values, just like the |
Beta Was this translation helpful? Give feedback.
The esphome adc component uses the chip's correction values, just like the
analogReadMilliVolts
function does. That function is only available in Arduino, so no, we won't be using it.