[MOD][APP][XPOSED][4.1+] Power Nap for Xposed - Sony's Stamina Mode for all devices!

Search This thread

wasd-

Senior Member
Jan 9, 2014
378
335
I'm testing it on JellyBean(4.2.1)and I select Whatsapp to keep my notifications but I don't reveive them, only when I open again Whatsapp they appear and if I look the time of the messages they are received while the screen its OFF.

Looking at the Xposed Log I can only see "[PowerNap] Whitelist updated. Count: 4"
 

Progressive82

Senior Member
Apr 20, 2012
100
9
If I cannot insert Google Cloud Messaging (GCM service) into whitelist, I cannot receive any notifications with greenify donate version. Can you insert the possibility to add activities and services in whitelist too?
 

navtab

Senior Member
Mar 29, 2013
322
36
Delhi
which basic apps should be added in whitelist. pls help since I m facing some issues.
1. mobile data not getting on automatically althuogh it is on in setting.I have to do it manually.
2. clock time in status bar not getting changed although alarm is working.
 

waylaidwanderer

Senior Member
Feb 19, 2012
190
799
Wow, awesome!! Would be really Nice if you get this Baby stable

I can't Wake my Device when it goes to standby (screen off) and powernap is active.

Can I'll Make a log, also when I'll get bsod ? How?

Thx

I'm looking into the problem, but as far as I know there's no way to retrieve the logcat if your phone reboots.

I'm testing it on JellyBean(4.2.1)and I select Whatsapp to keep my notifications but I don't reveive them, only when I open again Whatsapp they appear and if I look the time of the messages they are received while the screen its OFF.

Looking at the Xposed Log I can only see "[PowerNap] Whitelist updated. Count: 4"

I'll download Whatsapp to see if I can find the problem.

If I cannot insert Google Cloud Messaging (GCM service) into whitelist, I cannot receive any notifications with greenify donate version. Can you insert the possibility to add activities and services in whitelist too?

Activities/services are tied to package names most of the time, so as long as the package (aka app) is whitelisted it should be fine. But you're right, there's no package for GCM (but I'll whitelist it manually).
 
  • Like
Reactions: popy2006

popy2006

Senior Member
Mar 22, 2007
1,440
240
I'm looking into the problem, but as far as I know there's no way to retrieve the logcat if your phone reboots.



I'll download Whatsapp to see if I can find the problem.



Activities/services are tied to package names most of the time, so as long as the package (aka app) is whitelisted it should be fine. But you're right, there's no package for GCM (but I'll whitelist it manually).
Try to get a logcat now with alogrec....

---------- Post added at 09:16 AM ---------- Previous post was at 08:43 AM ----------

Try to get a logcat now with alogrec....
Does Not work, device is awake all the time ?
 

robneymcplum

Senior Member
Oct 22, 2007
737
154
midlands
I also have the status bar clock freezing, system time is right, alarm clock is right, zooper widget is fine. Just status bar clock freezes also.

Android 4.1
 

LiL_Assassin

Senior Member
Feb 19, 2012
1,266
663
Holy $%&#, it made my device alive again!! Thank you very much!! Just one question though. I think its the time_tick service. After the mod kicks in. and I wake up my device. The clock on my status bar hasnt changed. Which one do I need to enable for it to work? Thanks in advanced.

Sent from my GT-I9100 using XDA Free mobile app
 

Attachments

  • 1428840001159.jpg
    1428840001159.jpg
    52.2 KB · Views: 688

waylaidwanderer

Senior Member
Feb 19, 2012
190
799
Holy $%&#, it made my device alive again!! Thank you very much!! Just one question though. I think its the time_tick service. After the mod kicks in. and I wake up my device. The clock on my status bar hasnt changed. Which one do I need to enable for it to work? Thanks in advanced.

Sent from my GT-I9100 using XDA Free mobile app

I fixed the clock problem with the update :)

------------------------------------------------------

Hey guys, I just pushed Power Nap v0.3 Alpha to the Play Store. There's a new permission added, so read the changelog below for details. For the eager users, download links to the apk can be found in the "Releases" section of the testing community.

Changelog:
* added Ultra Endurance Mode (experimental)
* added a ProgressDialog to the Add Applications list so you can see if apps are currently loading
* added a bunch of critical apps to an internal whitelist. This means if something doesn't show up in your whitelist or when you try to add apps, don't worry because they're already whitelisted by default.
* added logging when wakelock/services/alarms are allowed to go through
* added Crashlytics
* fixed bug where status bar clock wasn't updating
* fixed Gmail not syncing when whitelisted
* fixed bug where sometimes you'd need to reboot before settings would update

I am still investigating the random reboot problem. If you encounter it please try to send me logcats.

New Permission: android.permission.INTERNET - this is for Crashlytics only, which will automatically send me stack trace logs if the app crashes due to something non-Xposed related. No other information is being sent to me.
 

hp420

Senior Member
Jul 31, 2011
2,591
1,434
Gainesville, Fl
Google Nexus 4
T-Mobile LG G2
Nexus 4, 5.0.1 factory image, unleashed 101 kernel

statusbar clock is not refreshing after deep sleep. see the video linked below. the notification shade clock and statusbar clock take a minute to refresh, but the lockscreen clock is always accurate.
 

Top Liked Posts

  • There are no posts matching your filters.
  • 506
    Introduction

    As the owner of an Xperia Z3, I found myself missing Stamina Mode after flashing a CM12 ROM. None of the battery apps in the Play Store worked the same way - most of the ones I found merely disabled Wi-Fi/data while the screen was off, along with managing auto-sync, but I still wanted whitelisted apps to be able to access the internet.

    I spent a good 12 hours straight working to replicate the basic features of Stamina Mode, and now here we are: Power Nap for Xposed!

    Images

    Imgur album link for easier viewing: http://imgur.com/a/JvSD8

    7VtGH1q.png

    Cy1bh4t.png

    gysUudu.png

    CF7vaJQ.png

    Czq2RUf.png



    Description

    Compatible with any Android device running 4.1+, with root and Xposed.

    Power Nap for Xposed is the best app for saving battery. When your screen is off, Power Nap maximizes your device's deep sleep time by stopping services, alarms and wakelocks from waking the device when the screen is off. This means you can leave Wi-Fi/data on and still get the notifications from apps you have whitelisted, while all others are unable to wake up your device, leading to an increase in your battery life.

    Power Nap for Xposed also has a Low Battery Mode, where you can selectively functions to save power when battery level is low.

    Power Nap for Xposed is inspired by Sony's Stamina Mode, but accessible for all Android devices 4.1 and higher. This app requires root and Xposed.

    Be sure to whitelist any third-party alarm clock app you are using, or it will be prevented from waking up your device!

    Permissions

    android.permission.INTERNET: this is for Crashlytics only, which will automatically send me stack trace logs if the app crashes due to something non-Xposed related. No other information is being sent.
    android.permission.WRITE_SETTINGS: For Low Battery Mode, to change screen brightness and screen display timeout
    android.permission.READ_SYNC_SETTINGS: For Low Battery Mode, to check if auto-sync is on/off
    android.permission.WRITE_SYNC_SETTINGS: For Low Battery Mode, to turn on/off auto-sync
    android.permission.ACCESS_WIFI_STATE: For Low Battery Mode, to check if Wi-Fi is on/off
    android.permission.CHANGE_WIFI_STATE: For Low Battery Mode, to turn on/off Wi-Fi
    android.permission.ACCESS_NETWORK_STATE: For Low Battery Mode, to check if mobile data is on/off
    android.permission.BLUETOOTH: For Low Battery Mode, to check if Bluetooth is on/off
    android.permission.BLUETOOTH_ADMIN: For Low Battery Mode, to turn on/off Bluetooth
    android.permission.RECEIVE_BOOT_COMPLETED: For Low Battery Mode, to start a service that monitors the current battery level (if LBM is enabled), when the device is finished booting

    Installation Instructions

    To get the app, you can either opt-in for testing on Google Play (and/or join the G+ Alpha testing community if you're interested in helping out by reporting bugs and sharing your experiences), or simply download it directly from the Xposed Module Repository. You may need to change "Versions to be shown" to "Experimental" in the Xposed Installer's Settings to be able to download it using the app.

    The latest APK version is also attached to the "Download" tab of this thread, but you will not receive updates using this method.

    Final Thoughts

    By using Power Nap, you can expect to see as little as 0.2% battery drain per hour (if you don't have many apps whitelisted) during standby. Results may vary by device and depending on which apps have been whitelisted.

    Since it's in Alpha mode, please feel free to leave feedback and report bugs. If you need any clarifications on any aspect of the app, please leave a comment!

    NEW ISSUE TRACKER - POST ISSUES HERE

    XDA:DevDB Information
    Power Nap for Xposed, Xposed for all devices (see above for details)

    Contributors
    waylaidwanderer
    Xposed Package Name: net.jzhang.powernap

    Version Information
    Status: Alpha
    Current Beta Version: 0.8a
    Beta Release Date: 2015-04-09

    Created 2015-04-09
    Last Updated 2016-10-22
    38
    Hi everyone, Power Nap v0.8 Alpha is now available on the Play Store!

    Mirror: http://dl-xda.xposed.info/modules/net.jzhang.powernap_v8_e3c396.apk

    Opt-in for testing
    Google Play link

    Changelog v0.8a (October 22, 2016)

    - added App Settings (click on app in whitelist to set active hours and allow only certain wakelocks)
    - warn the user if module is not enabled
    - fixed swipe to delete not working
    - fix stats not showing up on some devices
    - only ask for root if necessary

    NEW ISSUE TRACKER
    25
    Power Nap 0.8.1a has been uploaded to the Play Store and Xposed repo. There are still lingering issues with statistics not showing up for some people, so I decided to release the fix for the bootloops first.

    Direct download link: http://dl-xda.xposed.info/modules/net.jzhang.powernap_v9_38ab23.apk

    Changelog v0.8.1a (October 26, 2016)

    - fixed bootloop on Android 5.x
    - fix module not working on some 4.x devices
    - update Crashlytics library
    - fix force close when phone reaches low battery level with LBM enabled on Android 6.x (will ask for necessary permission first)
    - some more fixes for statistics not showing up: for those still experiencing issues, post on the issue tracker @ https://github.com/waylaidwanderer/PowerNapForXposed-Development/issues/2
    24
    Power Nap for Xposed is now available for download on the Xposed Module Repository: http://repo.xposed.info/module/net.jzhang.powernap

    You may need to change "Versions to be shown" to "Experimental" in the Xposed Installer's Settings to be able to download it using the app.

    You can also find the latest APK attached to the "Download" tab of this thread.
    21
    Good news, I've discovered the cause of the bootloop issue and fixed it. Funnily enough, I never ran into the problem because it seems to affect < 6.0 devices only. The fix will be available in the next update, once I sort out a bug with statistics not displaying for some people (again).