Check Battery Level
Posted:
Thu Mar 16, 2017 11:01 am
by obenavidez
Hello i have an ESP8266 with NodeMCU 0.9.6 build 20150704, is connected to a li-po 3.7V and 500mAh, in the VCC and the GND, i want to know if there is a way to read the battery level from LUA and turn on a led if is low the battery, or i need some special hardware configuration, thanks for your help.
Re: Check Battery Level
Posted:
Thu Mar 16, 2017 3:10 pm
by marcelstoer
The first thing really with such ancient firmware is to build a recent and supported version:
http://nodemcu.readthedocs.io/en/latest/en/build/#toolsThen you flash the binary:
http://nodemcu.readthedocs.io/en/latest/en/flash/Then you use the ADC module to retrieve the information you need:
http://nodemcu.readthedocs.io/en/latest/en/modules/adc/
Re: Check Battery Level
Posted:
Fri Mar 17, 2017 1:14 am
by trackerj