[Xposed Framework Modules] aeoveu:
I look mad quoting my own posts, updating again and again on my findings.

So I did a few tests on wifi - the battery drain ranged from anywhere between 1.5% per hour (over a span of 2 hours, minimum) to 3 or 4% on idle.

These are the wakelocks I had throttled (which helped for a fleeting moment, but didn't fix anything for the long run):

- NlpWakeLock: 240 seconds (default)

- NlpCollectorWakeLock: 240 seconds (default)

- UlrDispatchingService: 240 seconds (had to enable this)

- EntriesRefresh_wakelock: 720 seconds (had to enable this)

- BleScanReporter_WakeLock: 2400 seconds (had to enable this)

- TrafficIntentService_onHandleIntent

And I also noticed that the battery drain (as per the chart) was steeper than usual (on wifi). I still don't know what's going on with the battery drain (I made sure I force-closed Whatsapp so that it won't interfere)... even throttling the wakelocks didn't quite help much. Not sure what was going on.

That's when I decided to pay a visit to the alarms section. com.google.android.gms.nlp.ALARM_WAKEUP_ACTIVITY_DETECTION was one wakelock that raked up in numbers (the default 240 didn't seem to throttle it enough, I suppose). I decided to change the 240 into 2400, and remove the wakelocks for TrafficIntentService and ENtriesRefresh_wakelock (I have the alarm for BLE scanner throttled as well as the wakelock).

So now, it's back to defaults plus bluetooth scanning throttling. For posterity, these were my settings:

Wakelocks

- NlpWakeLock: 240 seconds (default)

- NlpCollectorWakeLock: 240 seconds (default)

- BleScanReporter_WakeLock: 2400 seconds

(and got rid of the rest for this test)

Alarms

- com.google.android.gms.nlp.ALARM_WAKEUP_ACTIVITY_DETECTION: 2400 seconds (changed from default 240)

- com.google.android.gms.nlp.ALARM_WAKEUP_LOCATOR: 240 seconds

- .com.google.android.gms/.blescanner.compat.ScanWakefulBroadcastReceiver: 2400 seconds (had enabled this).

Will post back after more investigations over a span of more than two hours... but in these two hours, the ALARM_WAKEUP_ACTIVITY_DETECTION reduced from ~25 per hour (as per BBS) to 12 per hour - halved. I need more testing. The battery drain was 0.5% per hour (over two hours), on wifi, so I'm hopefully doing something right... I hope.

Going out now, so I can actually test the cellular drain now, and hope this simple switch would help a lot! Wish me luck!

Edit: the result was waaaaay worse. The NlpWakeLock wakelock took 80% of the total battery time in one 35-minute long test (which equated to roughly 8% per hour), and then for 15 minutes in another ~1hr test. (which was around 4% or so, can't remember). So this didn't work. I think throttling this wakelock for too long, without adjusting the corressponding NlpWakeLock figure, would cause one to trip over the other.

I guess I'm going to have to turn off Location Reporting and use Google Now without it. It's sad, since sometimes, it can be useful - but then, Location Reporting isn't too accurate., and is patchy (by increasing this wakelock, it doesn't detect too many locations - which kinda defeats the purpose of location reporting).

Or has somebody found the magic pill?