High battery consumption in flight mode and without WiFi

Hello this is my first post here on the forum. Sorry for my bad English. I am from Germany.
I have been using Home Assistant for almost a year now. Mainly because of the Companion App. That was the reason why I switched from IO Broker.
Now to my problem.

Since the last update of the Android Companion App (version 2023.3.0-full), I have extremely high battery consumption on 3 Android phones.
My husband has not activated the automatic updates in the Play Store and therefore still has version 2023.1.1-full. He does not have the problem.
The settings in the app are the same on all 4 phones. We haven’t changed anything in the settings on the 3 phones with the new version either.
We only use the app at home in the WLAN. My Rasperry Pi has no internet connection (I’m a bit paranoid :slight_smile:
Accordingly, I have set the permanent connection in the app to “Always”.
I have deactivated all location sensors. Only the battery status is transmitted.
However, I have not changed this setting to the previous version. They were always like this.

With the 3 mobile phones with the latest version of the app, we have more than 25% battery loss overnight in the mobile phone’s flight mode. The same happens when we are not in the Wi-Fi area of the house. Then the battery consumption increases very strongly.

At home in the Wi-Fi area, everything is fine if the mobile phone has Wi-Fi reception.
During a normal working week when I’m not at home, the Home Assistant app takes up more than 50% of the total battery consumption. It’s the same with my children. It wasn’t like this on all three phones before the app update.

I have also uninstalled and reinstalled the app. No success. Still the same problem.

At the moment, I force the app to stop when I drive to work or set the mobile phone to flight mode in the evening. I have uninstalled the app on my children’s phones at the moment. But I don’t want this to be permanent.

I have already seen this page.

Does no one else have this problem? Does anyone have any ideas what else I can try?

Thank you for reading.
Greetings Monika

Hi Monica,
I am having what appears to be a similar issue to you. I had 75% battery, put my phone in airplane mode, went to sleep for 9 hours, and then woke up with it at 14% battery. The built-in battery usage showed Home Assistant consumed 47%.

I rebooted my phone and will see if I can replicate the issue. Sorry I can’t be of more help, but I wanted to share that I had this issue too.

My phone is an Android Pixel 4a with LineageOS 20-20230219-micrG-sunfish. Home Assistant app is version 2023.3.0-full from the Aurora Store.

(Your English is flawless, by the way.)

weve had an issue reported recently

developers have not had much luck reproducing or knowing where the issue comes from.

Are both of you guys using the persistent connection set to always ?

Similar thing happening on my phone and my wife’s - both android and started in the last week or two both on v2023.3.0 . We get massive battery drain and is to the point where whatever the problem is, is draining the battery on my phone as fast as charging it.

I notice in the logs Bluetooth problems, which may make sense as the beacon monitor was part of the

05-03 18:02:15.025 17251 17320 D BluetoothAdapter: isLeEnabled(): ON
05-03 18:02:15.025 17251 17320 D BluetoothLeScanner: could not find callback wrapper
05-03 18:02:16.233 17251 17320 D BluetoothAdapter: isLeEnabled(): ON
05-03 18:02:16.233 17251 17320 D BluetoothLeScanner: could not find callback wrapper
05-03 18:02:17.822 17251 17320 D
BluetoothAdapter: isLeEnabled(): ON
05-03 18:02:17.822 17251 17320 D BluetoothLeScanner: could not find callback wrapper
05-03 18:02:19.421 17251 17320 D BluetoothAdapter: isLeEnabled(): ON
05-03 18:02:19.421 17251 17320 D BluetoothLeScanner: could not find callback wrapper
05-03 18:02:20.522 17251 17320 D BluetoothAdapter: isLeEnabled(): ON
05-03 18:02:20.523 17251 17320 D BluetoothLeScanner: could not find callback wrapper
05-03 18:02:20.636 17251 17251 D LocBroadcastReceiver: Received location update.
05-03 18:02:20.638 17251 17251 W LocBroadcastReceiver: Location accuracy didn’t meet requirements, disregarding: Location[fused xxxxxccc,xxxxxx hAcc=252.5 et=+21d8h34m17s659ms alt=61.70000076293945 vAcc=1.0991334 vel=0.05099606 sAcc=3.0513768]
05-03 18:02:21.020 17251 17320 D BluetoothAdapter: isLeEnabled(): ON
05-03 18:02:21.020 17251 17320 D BluetoothLeScanner: could not find callback wrapper
05-03 18:02:21.020 17251 17320 D BluetoothAdapter: isLeEnabled(): ON
05-03 18:02:23.022 17251 17251 E CycledLeScannerForLollipop: Scan failed: app cannot be registered
05-03 18:02:23.023 17251 17320 D BluetoothAdapter: isLeEnabled(): ON
05-03 18:02:23.023 17251 17320 D BluetoothLeScanner: could not find callback wrapper
05-03 18:02:24.221 17251 17320 D BluetoothAdapter: isLeEnabled(): ON
05-03 18:02:24.221 17251 17320 D BluetoothLeScanner: could not find callback wrapper
05-03 18:02:25.821 17251 17320 D BluetoothAdapter: isLeEnabled(): ON
05-03 18:02:25.821 17251 17320 D BluetoothLeScanner: could not find callback wrapper
05-03 18:02:27.422 17251 17320 D BluetoothAdapter: isLeEnabled(): ON
05-03 18:02:27.422 17251 17320 D BluetoothLeScanner: could not find callback wrapper
05-03 18:02:28.530 17251 17320 D BluetoothAdapter: isLeEnabled(): ON
05-03 18:02:28.530 17251 17320 D BluetoothLeScanner: could not find callback wrapper

And on and on and on.

I have turned off Bluetooth on my phone and will see what happens.

This looks like you had either the Bluetooth transmitter or beacon monitor enabled. Both of those drain battery.

Hello,

have a similar or the same problem. The massive loss of battery power only occurs sporadically. 1 in 3 to 4 days. The HA app version is 2023.3.-full. Bluetooth is permanently on (Smartphone). At night, the smartphone is always on “Do not disturb” and “Flight mode”. Android 13 is running on it.

Frank

My persistent connection was set to Never. I found this setting through your other post - thanks!

Hello and thank you for the feedback so far. I am now reassured that this is not my problem alone. Unfortunately, my husband has now also made the update by mistake :roll_eyes:. The next morning, the same problem. So now I have 4 mobile phones with the same problem. For us, the permanent connection is set to always, as I don’t allow my Rasperry Pi to access the Internet.

I force the app to stop every evening. Then my battery is not empty.

I hope that a cause and solution will be found there.
Have a nice evening… Monika

Hello,
for me an uninstall of the app from my smartphone and the follow up new installation solved the problem.
Frank

Hello,
Unfortunately, an update to the new version 2023.6.0-full did not bring any improvement. I still have the same problem on 4 different mobile phones. If I forget to stop the app in the evening, I have about 30% less battery in the morning.
According to the battery indicator in the phone, the Home Assistant app has consumed the most. So it only happens in flight mode.
It often happens that the app hangs if I forget to stop the app in the evening. If I then switch off the flight mode in the morning, my phone freezes for a moment and Android reports that the app is not responding.
I have now uninstalled the app again and reinstalled it. Maybe it will work then (I had already tried the old version without success). This is the last attempt for me. I hope this works.
Monika

I have this issue too, just now installed 2023.6 (coming from 2023.3, always use minimal)

I’m not using BT and none of the BT sensors (I don’t have beacon) are enabled.

Here is a small interim status. I had completely reinstalled version 2023.6.0-full.
I set persistent connection to always again (as already described, my Home Assistant Raspi has no direct internet connection).
Then I directly deactivated all sensors. So nothing is transmitted from the mobile phone to the Home Assistant.
I don’t have a widget active. I have also deactivated the item “Remote control app and device”.
I have no “Shortcut” and no “Tile (in German ‘Kachel’)” active.
Then I was very happy because I only lost about 4 % battery overnight in flight mode. This then went on for several days. I then changed NOTHING and suddenly the app again consumed 30 to 40% battery overnight.
I have a VPN firewall on my phone. I have already switched off the rules for the Home Assistant Companion App. However, it still consumes so much battery. Nothing has changed with 2023.7.0-full either.
I’m getting desperate. I don’t want to do without the app. But it’s really annoying with the battery.
I’ll uninstall the VPN firewall again to test it. I will then report whether the problem still exists.
Monika

Hello.
I have now uninstalled the VPN firewall. Nevertheless, the consumption in flight mode is still around 30 %.

Since I don’t want to do without the app, but this is not a good state of affairs either, I thought about whether I could stop the Home Assistant Companion App automatically via a “sent intent” command as soon as no more WLAN is available and start it again when I am back on my WLAN.
Is there an intent command that stops the Home Assistant Companion App?

I would do this with the Android app Tasker.
Best regards Monika

if you change it to never do you still see the battery drain issue?

Thank you for your patience with me.
I have now set the persistent connection to never (last night). Battery consumption at 6%. So much better.
I then just tried to set the persistent connection to the option “only in the home wifi” (translated from German). But then no more notifications arrive on my mobile phone. I have also defined my WLAN as “home WLAN”.
With the option “while screen on”, the notifications work.
Perhaps the option “only in home WLAN” would be sufficient. But somehow it doesn’t work.

If necessary, I would really try to switch the option via Tasker. But I haven’t managed that yet.
:raising_hand_woman:

Settings > Companion App > Troubleshooting > Show and share logs

From this screen you can see if the app sees you on home wifi or not, we print the decision there under ServerConnectionInfo

probably someting we need to check, also keep in mind the app and device needs location enabled in order to read the connected WiFi SSID

Hi dshokouhi,
thank you for this information.
I have now managed to get the notifications under “home WLAN only”.
I had not entered the “Internal connection URL” under the “Connection information”. Now the app also recognises me on the home wifi.
Now I’m looking forward to the night to see how the battery behaves in flight mode. I will report back.
Greetings Monika

1 Like

Hi,
Only 2% battery consumption on my phone and on my wife’s phone only 1% throughout the night in flight mode. This is now the same as with version 2023.1.1-full.
However, I would like to emphasise once again that I did not change anything in the settings when I updated to 2023.3.0-full.
Now everything is back the way I want it. :hugs:
Maybe I can find the difference between version 2023.3.0-full and 2023.2.0-full or 2023.1.1-full.

For all those who also have this problem, here is a summary of how it seems to have been solved for me (on 2 phones, the other 2 are now also being changed over).

I have now set the “Home Assistant URL” and the “Internal connection URL” to the same value under “Connection information”.
2. under “Home network WLAN SSID” I have entered the SSID of my WLAN at home. 3.
3. under “persistent connection” I clicked on “only in the home WLAN”.

For your information, I have switched on my VPN firewall again and still only have low battery consumption.

Thanks again for the help. I am glad that everything works again.

Greetings Monika :raising_hand_woman: