I am using a Xenon/Argon mesh setup with the 3.6V Lipo battery and am using the given:
float voltage = analogRead(BATT) * 0.0011224;
to track battery level. This will not work in loop(), voltage remains at it’s initialized value. When I put this line of code in setup() as well as loop(), it returns the correct voltage value but remains unchanged over an extended period of time. I have multiple event handlers that could be interrupting this call, but the reference docs say that an analogRead() takes around 10 microseconds, and I doubt the multiplication takes very long either.