From f7897db660b27112902ea122fc1a8b41a822965e Mon Sep 17 00:00:00 2001 From: Zoltan Kozma Date: Wed, 10 Aug 2022 16:44:12 +0100 Subject: [PATCH 1/3] Added how to use the built-in battery voltage divider network in the Firebeetle ESP32-E --- components/sensor/adc.rst | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/components/sensor/adc.rst b/components/sensor/adc.rst index 59208db6c..f87173530 100644 --- a/components/sensor/adc.rst +++ b/components/sensor/adc.rst @@ -119,6 +119,24 @@ Multiple ADC Sensors You can only use as many ADC sensors as your device can support. The ESP8266 only has one ADC and can only handle one sensor at a time. For example, on the ESP8266, you can measure the value of an analog pin (A0 on ESP8266) or VCC (see above) but NOT both simultaneously. Using both at the same time will result in incorrect sensor values. +Measuring battery voltage on the Firebeetle ESP32-E +--------------------------------------------------- + +This board has a internal voltage divider and the battery voltage can easily be measured like this using 11dB attenuation +on GPIO34 + +.. code-block:: yaml + + - platform: adc + name: "Battery voltage" + pin: GPIO34 + accuracy_decimals: 2 + update_interval: 60s + attenuation: 11dB + filters: + - multiply: 2.0 # The voltage divider requires us to multiply by 2 + +This works on SKU:DFR0654. For more information see: `manufacturer's website `__ See Also -------- From 94483b0fe917f91b9a34ffa0e763aabaa6ac7d03 Mon Sep 17 00:00:00 2001 From: Zoltan Kozma Date: Wed, 10 Aug 2022 17:06:22 +0100 Subject: [PATCH 2/3] indent --- components/sensor/adc.rst | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/components/sensor/adc.rst b/components/sensor/adc.rst index f87173530..91f42d870 100644 --- a/components/sensor/adc.rst +++ b/components/sensor/adc.rst @@ -127,14 +127,14 @@ on GPIO34 .. code-block:: yaml - - platform: adc - name: "Battery voltage" - pin: GPIO34 - accuracy_decimals: 2 - update_interval: 60s - attenuation: 11dB - filters: - - multiply: 2.0 # The voltage divider requires us to multiply by 2 + - platform: adc + name: "Battery voltage" + pin: GPIO34 + accuracy_decimals: 2 + update_interval: 60s + attenuation: 11dB + filters: + - multiply: 2.0 # The voltage divider requires us to multiply by 2 This works on SKU:DFR0654. For more information see: `manufacturer's website `__ From ccebcb8968fc265000c84edcc82a9ab5d8d21a57 Mon Sep 17 00:00:00 2001 From: Zoltan Kozma Date: Wed, 10 Aug 2022 18:51:56 +0100 Subject: [PATCH 3/3] dots --- components/sensor/adc.rst | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/components/sensor/adc.rst b/components/sensor/adc.rst index 91f42d870..21fa50d61 100644 --- a/components/sensor/adc.rst +++ b/components/sensor/adc.rst @@ -123,7 +123,7 @@ Measuring battery voltage on the Firebeetle ESP32-E --------------------------------------------------- This board has a internal voltage divider and the battery voltage can easily be measured like this using 11dB attenuation -on GPIO34 +on GPIO34. .. code-block:: yaml @@ -136,7 +136,7 @@ on GPIO34 filters: - multiply: 2.0 # The voltage divider requires us to multiply by 2 -This works on SKU:DFR0654. For more information see: `manufacturer's website `__ +This works on SKU:DFR0654. For more information see: `manufacturer's website `__. See Also --------