Hi,
I have a LILYGO TTGO T5 V2.3 2.13 Inch E-Paper Screen with built-in battery connector on the board.
I connected a spare 3.7 battery and that seems to be working fine.
Now I am trying to figure out how do I get the battery level in ESPHome?
On the board close to the battery connector there is a text saying BAT_TEST_35 so I tried to use adc platform
sensor:
- platform: adc
pin:
number: 35
id: "VCC"
internal: true
- platform: template
name: "eink_battery"
unit_of_measurement: '%'
update_interval: 60s
lambda: |-
return ((id(VCC).state /3.30) * 100.00);
but that gave me this error:
mapping values are not allowed here
in "/config/esphome/epaperclock12.yaml", line 41, column 8:
pin:
^
Is that the right way to do this?
Thanks