Related
There are already different custom kernels getting released for Xiaomi Mi 3W. And "Kernel Adiutor" is always being suggested app to manage this customizabilities, but not all users (like me ) is too technical to understand things we can see in this app. I hope someone could explain like what would happen if you this, and do that. If you increase this, or lessen that. Or if youre that kind of user then it would be better if you do this or that.
That would be a great help if someone would start a thread like it, then where other users can also share how they setup their kernel settings, etc.
TAKE THESE:
[Kernel Settings]
Kernel: Stuxnet+ Alpha X
App used: Kernel Adiutor
1-CPU
CPU maximum frequency- 1267 MHz
CPU governer- Interective or OnDemand
Multicore powersaving- Enable
Explaination: This will make your device CPU to use limited frequency as you don't need full power in normal usage, it's like Balanced mode of MIUI.
2-CPU Voltage
Global Offset- (-75v) or (-50v)
Explaination: It limits the power consumed by each core upto 883 MHz, don't go beyond (-75v) it's harmfull for CPU.
3-GPU
GPU maximum frequency- 462 MHz
Explaination: Same as CPU.
4-Low Memory Killer
Select 'Medium'.
Explaination: Frequent RAM cleaning affect battery life, as once FREE RAM is below the level, it will auto clean RAM & thing process continues, as those apps will run again & so. Also this will helps you to make your apps on background for a long time.
Note 1: Make sure you check 'Apply on boot'. Otherwise your settings will set to default on each boot.
Note 2: You can use 'Greenify' to hibernate apps.
Note 3: Visibilty of options in Kernel Adiutor app depends upon the features of a kernel, if one kernel doesn't have that feature, it wont be show in this app.
Note 4: If you don't know a thing about kernel then please don't try this on your device. First search on Google, educate yourself & try this.
Enjoy.
Guys,
Not seeing much activity here in this forum
I was searching for some xposed modules to improve on the battery performance.
can you guys suggest some good xposed modules you use in general.
Greenify is the best to improve battery performance using XPosed.
Hibernates apps.
Less power to wake a hibernated app than restart a killed one.
Amplify too. But only use it if you are conversant with wakelocks.
Now I haven't seen this anywhere while trying to find a fix so I may possibly be sharing a new idea.
I know that we already have Greenify and such apps to extend our phones battery life, but what I find is that in some way or another they reduce the overall performance of it.
My idea is to create a Tasker profile where the phone runs at normal performance during screen on but recognises when the display is locked and reduces the CPU speed to its minimum, because surely being at anything more is a waste of CPU energy?
I have created a profile that's activated by a display off event, followed by a System >> CPU task called "Lower CPU" that reduces the max frequency to the value of min frequency.
When activated it does lower the speed while the screen is off, but once I turn the screen back on it takes a reboot to get the cores speed to increase again even if I turn off the Tasker profile.
It won't allow me to create an exit task for an event context so do I need to create a new profile to raise the CPU speed in an event of a screen on? Or is there a way to use a plugin like Trickster Mod to lower and raise it instead?
Apologies for it being so long, I'm not sure if I'm making it more complicated? But help please!
Thank you!
P.s - the images are screenshots of CPU-Z 1. Before locking the screen. 2. Immediately after unlocking the phone 3. About 2 minutes after unlocking the phone and it just doesn't return to normal
AJHylton said:
Now I haven't seen this anywhere while trying to find a fix so I may possibly be sharing a new idea.
I know that we already have Greenify and such apps to extend our phones battery life, but what I find is that in some way or another they reduce the overall performance of it.
My idea is to create a Tasker profile where the phone runs at normal performance during screen on but recognises when the display is locked and reduces the CPU speed to its minimum, because surely being at anything more is a waste of CPU energy?
I have created a profile that's activated by a display off event, followed by a System >> CPU task called "Lower CPU" that reduces the max frequency to the value of min frequency.
When activated it does lower the speed while the screen is off, but once I turn the screen back on it takes a reboot to get the cores speed to increase again even if I turn off the Tasker profile.
It won't allow me to create an exit task for an event context so do I need to create a new profile to raise the CPU speed in an event of a screen on? Or is there a way to use a plugin like Trickster Mod to lower and raise it instead?
Apologies for it being so long, I'm not sure if I'm making it more complicated? But help please!
Thank you!
P.s - the images are screenshots of CPU-Z 1. Before locking the screen. 2. Immediately after unlocking the phone 3. About 2 minutes after unlocking the phone and it just doesn't return to normal
Click to expand...
Click to collapse
I understand what you're getting at, but it's really not necessary to do such a thing. CPU cores clock down and all cores except for core0 usually shut down when the phone goes into sleep mode, so the amount of battery you're saving is negligible doing this. If your phone is running hot while the screen is off, then you likely have wakelock issues and that's something separate you need to tackle.
MishaalRahman said:
I understand what you're getting at, but it's really not necessary to do such a thing. CPU cores clock down and all cores except for core0 usually shut down when the phone goes into sleep mode, so the amount of battery you're saving is negligible doing this. If your phone is running hot while the screen is off, then you likely have wakelock issues and that's something separate you need to tackle.
Click to expand...
Click to collapse
Ohh I see, thank you for explaining. I would have thought that this would be implemented somewhere as otherwise it would have been a clear battery drain but I thought I'd double check lol
Doze Mode
What version of Android are you running? If you're on Marshmallow, adjusting the CPU may not be necessary as it has Doze mode and using either Naptime or Doze Settings Editor and adjusting the settings can defintely increase battery life when the device is sleeping.
If not, I suggest using PowerNap with Xposed and Greenify.
In fact, Greenify has Tasker integration so you can set it to hibernate apps upon screen off situations.
Of course, all the apps I listed need root access...
Another helpful resource to help with power saving can be found at http://forum.xda-developers.com/nexus-5x/general/guide-advanced-interactive-governor-t3269557
You will have to adjust it based on your device and kernel of course, but I've experinced great power savings using a combination all I've mentioned
Ozonethegreat said:
What version of Android are you running? If you're on Marshmallow, adjusting the CPU may not be necessary as it has Doze mode and using either Naptime or Doze Settings Editor and adjusting the settings can defintely increase battery life when the device is sleeping.
If not, I suggest using PowerNap with Xposed and Greenify.
In fact, Greenify has Tasker integration so you can set it to hibernate apps upon screen off situations.
Of course, all the apps I listed need root access...
Another helpful resource to help with power saving can be found at http://forum.xda-developers.com/nexus-5x/general/guide-advanced-interactive-governor-t3269557
You will have to adjust it based on your device and kernel of course, but I've experinced great power savings using a combination all I've mentioned
Click to expand...
Click to collapse
Alright thank you for that, I'll take a look at those. I'm currently using a Oneplus Two on OxygenOS 2.2 which is based on KitKat. I have been looking at Xposed modules as that's what really made me root this phone but apparently I need to go through steps to make SeLinux permissive because at the moment nothing from Xposed works. And considering yesterday I spent hours unbricking this phone, I'm going to stop fiddling with it for a little while :laugh:
AJHylton said:
Alright thank you for that, I'll take a look at those. I'm currently using a Oneplus Two on OxygenOS 2.2 which is based on KitKat. I have been looking at Xposed modules as that's what really made me root this phone but apparently I need to go through steps to make SeLinux permissive because at the moment nothing from Xposed works. And considering yesterday I spent hours unbricking this phone, I'm going to stop fiddling with it for a little while :laugh:
Click to expand...
Click to collapse
You can set SeLinux to permissive using the code below in your terminal app or adb shell (found here):
Code:
su
mount -o remount,rw /system
mkdir /system/su.d
echo "#!/system/bin/sh" > /system/su.d/permissive.sh
echo "setenforce 0" > /system/su.d/permissive.sh
echo "0" > /sys/fs/selinux/enforce
chmod 755 /system/su.d/permissive.sh
Or if that's too much for ya, SeLinuxModeChanger works as well. Keep in mind that Google marks this as harmful but that's only because they don't want to changing SeLinux.
Ozonethegreat said:
You can set SeLinux to permissive using the code below in your terminal app or adb shell (found here):
Code:
su
mount -o remount,rw /system
mkdir /system/su.d
echo "#!/system/bin/sh" > /system/su.d/permissive.sh
echo "setenforce 0" > /system/su.d/permissive.sh
echo "0" > /sys/fs/selinux/enforce
chmod 755 /system/su.d/permissive.sh
Or if that's too much for ya, SeLinuxModeChanger works as well. Keep in mind that Google marks this as harmful but that's only because they don't want to changing SeLinux.
Click to expand...
Click to collapse
I have actually tried the SELinuxModeChanger to change it and when I run 'getenforce' in Terminal it says permissive but Xposed still doesn't work even then. The steps I was told to try are http://forum.xda-developers.com/oneplus-2/general/guide-disable-selinux-to-allow-xposed-t3331105 which seems a little more intense lol.
I'm going to try the code now and see if that works, if it doesn't is it likely that that's not what's stopping Xposed from working?
Update: I tried the code and running getenforce on the terminal says permissive but the Xposed modules still dont have any effect when activated
AJHylton said:
I have actually tried the SELinuxModeChanger to change it and when I run 'getenforce' in Terminal it says permissive but Xposed still doesn't work even then. The steps I was told to try are http://forum.xda-developers.com/oneplus-2/general/guide-disable-selinux-to-allow-xposed-t3331105 which seems a little more intense lol.
I'm going to try the code now and see if that works, if it doesn't is it likely that that's not what's stopping Xposed from working?
Update: I tried the code and running getenforce on the terminal says permissive but the Xposed modules still dont have any effect when activated
Click to expand...
Click to collapse
Strange. Both worked for me and I've had no problems. Might be the rom you're running. I'm not sure.
this entire thing could be achieved with a init.d script which I used to use back in 2012.
Screen off- powersave governor...
screenon- normal governor
Introduction:
Hello everyone!
The idea to this 'project' did blossom after having an conversation with @pkgnex in the past about the general idea of creating something else that follows what he started with his PK's Tuning Script for Pixel 2 (XL) but with a twist, mainly as a complement to his own thread that you can find here, but also with a completely different vision and focus on what the script itself should achieve (and deliver) for kind of results for myself and for all of you personally, of course, that wants to try it out and use it as a "daily driver".
Shortly explained.
This script is created with the goal of improving both battery life and performance on our Pixel 3a (XL) devices, and after a whole range of configurations and various set-ups, I've come up with something that, in my eyes, is worth sharing with all of you so that you can try it out yourself and judge on your own, with constructive feedback on what can be improved or added in future releases - if desired. My philosophy is, and will always be, this:
If something can be improved or altered in a positive way so the average user can feel and see a difference, then go for it. Non stop.
The latest release can be found here.
Disclaimer:
This is presented as "what if". If this modification screws up or breaks anything for you, I am not the one to be held responsible. It's a free will to try out this kind of changes/modifications/addons/tweaks, just don't blame the inventors for eventual bad results and/or screw-ups.
Note: This script is not recommended to be modified or customized by the user.
Features:
Reduced battery consumption
Device specific enhancements for best possible balance between battery life & performance
Enabled, and fully configured, Boeffla generic kernel wakelock blocker
Disabled a lot of useless stuff at kernel level (Improves battery life as well as performance)
CPUSet improvements & optimizations
Power efficiency enhancements
Wide IO block tuning (Reduces the possibility of hiccups, lags and overhead)
Possibly other miscellaneous things I've forgotten to write down here, both big and small.
Requirements/what you need for getting this script fully working:
An unlocked bootloader
Your own specific choice of kernel
Latest possible version of Magisk
Busybox for Android NDK Magisk Module by @osm0sis
Patience
Installation/How-To use & abuse:
1) Download the attached ZIP
2) Extract the script
3) Move the script to the following location;
/data/adb/service.d and give it the following & needed file permissions (0755)
4) Reboot your phone, let Android boot to the launcher and let Magisk boot service do its crucial magic (takes a few seconds before the scripts is fully up and running around behind the scenes)
5) Enjoy!
Note: If you still are unsure how to do for making my kernel configuration / modification work & be up and running behind the scenes, then please read @Phalanx7621 phenomenal guide here or check out @Phalanx7621 in-depth video here. The installation method is the same for all generations of released Pixels!
Credits:
@franciscofranco for all the information on which kernel wakelocks that is safe to block
@Phalanx7621 for his phenomenal how-to guide
@Lord Boeffla for his awesome generic kernel wakelock blocker
@pkgnex for inspiring me walking into this partially unknown territory.
@flar2 for his excellent EXKM application and ElementalX Kernel
@osm0sis for his Magisk Busybox module
Everyone that I've forgotten to mention here
Telegram:
If you want to try out betas / previews of my script before they are officially released, or just hangout and chat a little, then join the official Telegram group here
To-Do list:
Optimize and properly tune things even further for best possible balance between battery life, system responsivness and performance
Contributors:
@xFirefly93
Created: 2019-07-06
Last updated: 2019-07-21
Update!
Note: It is recommended that you reboot your phone after you have applied v1.0 so the customized changes / improvements takes full effect and is fully up & running as intended.
Version v1.0 (Initial release):
- Initial test release for Google Pixel 3a (XL)
- Enabled, and tuned, Boefflas wakelock blocker
- Enabled the backlight dimmer per default
- Disabled some useless kernel stuff for less overhead
- Some additional high quality customizations & improvements
If you optionally want to donate a beer or five as a way to show your appreciation for all the dedicated hours and work that I am putting into this mod on a daily rate - then this link is the way to go!
Enjoy!
I try it thanks a lot
Update!
Note: It is recommended that you reboot your phone after you have applied v1.1 so the customized changes / improvements takes full effect and is fully up & running as intended.
Version v1.1 (Semi-major release):
- Adjusted the task scheduler for better system responsivness
- Added my own Schedutil governor profile for a better balance between performance and battery life through the whole day
If you optionally want to donate a beer or five as a way to show your appreciation for all the dedicated hours and work that I am putting into this mod on a daily rate - then this link is the way to go!
Enjoy!
Update!
Note: It is recommended that you reboot your phone after you have applied v1.2 so the customized changes / improvements takes full effect and is fully up & running as intended.
Be aware that you have to flash the Busybox Magisk module by @osm0sis for getting the newest enhancements, that is featured / included on v1.2, up and running as intended!
Version v1.2 (Major release):
- Added a few crucial filesystem tweaks for improved performance (Credits goes to @pkgnex for this contribution. Be aware that you have to flash the Busybox Magisk module for getting those modifications up and running as fully intended)
- Fully removed all of the alternative task scheduler values / settings (they was only causing random freezes and lagspikes)
- Slightly adjusted the default stock CPUSet values for hopefully improved power efficiency as well as system responsivness
- Cleaned up the script on a few minor typos and what not
- Disabled a few minor CPU related loggers (experimental)
- Reduced suspend latency by enabling console_suspend
- Added a few tweaks for overall better network performance
- Shifted to Westwood TCP congestion algorithm per default
- Disabled the useless Adreno GPU frequency throttling tunable
- Disabled RCU expedited and 'replaced' it with RCU normal for improved real-time latency, CPU utilization and energy efficiency
If you optionally want to donate a beer or five as a way to show your appreciation for all the dedicated hours and work that I am putting into this mod on a daily rate - then this link is the way to go!
Enjoy!
Does 'Boefflas wakelock blocker' also get enabled on stock kernel? I am thinking of getting my Mother the 3a as a present, but would prefer to stick to stock. If not I can flash EX Kernel.
xFirefly93 said:
Update!
Note: It is recommended that you reboot your phone after you have applied v1.2 so the customized changes / improvements takes full effect and is fully up & running as intended.
Be aware that you have to flash the Busybox Magisk module by @osm0sis for getting the newest enhancements, that is featured / included on v1.2, up and running as intended!
Version v1.2 (Major release):
- Added a few crucial filesystem tweaks for improved performance (Credits goes to @pkgnex for this contribution. Be aware that you have to flash the Busybox Magisk module for getting those modifications up and running as fully intended)
- Fully removed all of the alternative task scheduler values / settings (they was only causing random freezes and lagspikes)
- Slightly adjusted the default stock CPUSet values for hopefully improved power efficiency as well as system responsivness
- Cleaned up the script on a few minor typos and what not
- Disabled a few minor CPU related loggers (experimental)
- Reduced suspend latency by enabling console_suspend
- Added a few tweaks for overall better network performance
- Shifted to Westwood TCP congestion algorithm per default
- Disabled the useless Adreno GPU frequency throttling tunable
- Disabled RCU expedited and 'replaced' it with RCU normal for improved real-time latency, CPU utilization and energy efficiency
If you optionally want to donate a beer or five as a way to show your appreciation for all the dedicated hours and work that I am putting into this mod on a daily rate - then this link is the way to go!
Enjoy!
Click to expand...
Click to collapse
My pixel didn't go Deep sleep with 1.2
MrPhilo said:
Does 'Boefflas wakelock blocker' also get enabled on stock kernel? I am thinking of getting my Mother the 3a as a present, but would prefer to stick to stock. If not I can flash EX Kernel.
Click to expand...
Click to collapse
It does only exist on a few selected custom kernels.
djisma86 said:
My pixel didn't go Deep sleep with 1.2
Click to expand...
Click to collapse
Deep sleep is fine for me here. Go and check which partial wakelocks that is screwing up your phone by using BBS.
How do I know it's working? Set the permissions to 755.
Sent from my Pixel 3a XL using Tapatalk
arenaboy007 said:
How do I know it's working? Set the permissions to 755.
Click to expand...
Click to collapse
The changelog isn't needed inside the service.d folder.. ;p
And.. Have you created a logs folder inside your internal storage on your device, and tried with rebooting once?
xFirefly93 said:
The changelog isn't needed inside the service.d folder.. ;p
And.. Have you created a logs folder inside your internal storage on your device, and tried with rebooting once?
Click to expand...
Click to collapse
I have not created a logs folder yet. How do I generate one? So far I moved the file in the service.d folder and media/0 folder.
Sent from my Pixel 3a XL using Tapatalk
arenaboy007 said:
I have not created a logs folder yet. How do I generate one? So far I moved the file in the service.d folder and media/0 folder.
Sent from my Pixel 3a XL using Tapatalk
Click to expand...
Click to collapse
You don't have to do it yourself, the automatically folder creation will be featured on v1.3, which will be released either tomorrow or at Friday.
I've to try a few minor things out first before firing it up into the wild.
I have placed the script in both the service.d and 0 folder, but no logs have been generated after reboot? I already have busybox installed too.
Edit: I noticed that some settings within EX Kernel manager have been changed, like cubic to Westwood, and fiops to cfq. I guess it worked?
Sent from my Pixel 3a XL using Tapatalk
arenaboy007 said:
I have placed the script in both the service.d and 0 folder, but no logs have been generated after reboot? I already have busybox installed too.
Edit: I noticed that some settings within EX Kernel manager have been changed, like cubic to Westwood, and fiops to cfq. I guess it worked?
Click to expand...
Click to collapse
Just make a new empty folder on the sdcard. /sdcard/logs/ Then reboot your device. After boot has completely finished wait 30-60 seconds. Then look into the new logs folder. You should see a new log file in the folder. The log tells you that the script has run successfully.
12paq said:
Just make a new empty folder on the sdcard. /sdcard/logs/ Then reboot your device. After boot has completely finished wait 30-60 seconds. Then look into the new logs folder. You should see a new log file in the folder. The log tells you that the script has run successfully.
Click to expand...
Click to collapse
It worked! I created a log folder and on next reboot saw a log inside. Thank you!
Sent from my Pixel 3a XL using Tapatalk
Not for teasing far too much right now but.. The weird maxing out on the LITTLE cluster cores have finally been fixed once and for all!
Thanks to everyone that reported about this issue that I sadly enough introduced.
xFirefly93 said:
Not for teasing far too much right now but.. The weird maxing out on the LITTLE cluster cores have finally been fixed once and for all!
Thanks to everyone that reported about this issue that I sadly enough introduced.
Click to expand...
Click to collapse
Is it possible for you to set the min clock speed to 300mhz for both clusters? This clock speed is available on the elementalx kernel.
Sent from my Pixel 3a XL using Tapatalk
arenaboy007 said:
Is it possible for you to set the min clock speed to 300mhz for both clusters? This clock speed is available on the elementalx kernel.
Click to expand...
Click to collapse
I can give it a try.
Update!
Note: It is recommended that you reboot your phone after you have applied v1.3 so the customized changes / improvements takes full effect and is fully up & running as intended.
Version v1.3 (Minor release):
- Added the needed commands so the logs folder, and the output message, will be automatically generated after each completed boot sequence (Thanks to @crian for giving a few seconds of his time helping me out with this contribution. You rock, dude!)
- Simplified a few explanations of what each section does
- Fully enabled the RET idle power state for both clusters (may, or may not, lead to slightly improved battery life for everyone)
- Most likely fixed the minor issue with the weird all over the place maximum CPU frequency bouncing on the whole LITTLE cluster
If you optionally want to donate a beer or five as a way to show your appreciation for all the dedicated hours and work that I am putting into this mod on a daily rate - then this link is the way to go!
Enjoy!
Update!
Note: It is recommended that you reboot your phone after you have applied v1.4 so the customized changes / improvements takes full effect and is fully up & running as intended.
Version v1.4 (Minor release):
- Disabled RET idle state for all of the cores again (it wasn't showing any major notable power savings as expected)
- Fully disabled the 'block_validity' mount option for the /system partition (this slightly improves overall system performance)
- Enabled power efficient workqueues (improves battery life - was actually enabled on v1.3, it was just I that forgot to mention it)
If you optionally want to donate a beer or five as a way to show your appreciation for all the dedicated hours and work that I am putting into this mod on a daily rate - then this link is the way to go!
Enjoy!
There are several Magisk modules that claim to optimize settings for better performance and extended battery life. What are people's experience with these on the Sony Xperia?
NFS Injector
This module aim to improve kernel / ram management between efficiency and energy aware .
Using a complex algorithm , it deteremine the most optimal settings between battery and performance for your device.
NFS improve your overall experience , as well as specifically enhances PUBG performance , Others Games also.
LKT
LKT aims to achieve a fair balance between power consumption and performance. Instead of tuning the parameters manually, LKT adopts Project WIPE open-source interactive parameters for the mainstream SOCs that are generated by machine learning AI via simulation and heuristic optimization algorithms.
WIPE v2 focuses on meeting performance requirements when interacting with APP, while reducing non-interactive lag weights, pushing the trade-off between fluency and power-saving even further. QTI Boost Framework, which must be disabled before applying optimization, is able to dynamically override parameters based on perf hint. This project utilizes the QTI Boost Framework and extends the ability to override custom parameters. When launching APPs or scrolling the screen, applying more aggressive parameters to improve response at an acceptable power penalty. When there is no interaction, use conservative parameters, use small core clusters as much as possible, and run at a higher energy efficiency OPP under heavy load.
FDE.AI
FDE - very universal Android OS optimizer. Very wide-range settings of OS and Linux kernel are configured, still being cross-platform utility, maximally compatible with all devices. This means that it doesn't have any dirty hacks/hardcore and 3rd part binaries (except busybox) & config files. FDE applies configurations depending on It's hardware and software, so that in the end every device is configured individually.
New unique method of execution - all required FDE components are loaded directly to RAM and executed from there. System partitions are remounted RW only once while installation. This means high speed (the worst RAM will have at least ~500MB/s of I/O speed), no power consumption (no NAND memory I/O occurs) and security (system partitions are in read-only state). Also new-gen FDE is synced with OS boot process - so tweaks will be applied in correct time. All system partitions are trimmed and checked for errors after every OS boot with FDE onboard. Universal installer automatically detects what ROOT-method you use and how to auto-start. Finally, FDE is not only about optimization. It's also about security and feature-enabler.
Custom Thermal Mod
- Improved overall performance
- Prevent aggressive early thermal throttling
- Maintain a consistent performance for extended periods of time
- Prolonged camera usage & video recording
- Suitable for daily usage & gaming
LuminousOne said:
What are people's experience with these on the Sony Xperia?
Click to expand...
Click to collapse
I am using the custom thermal mod. Can't say I've noticed much difference. I tried it in performance mode for a while, it was definately snappier, but also ate battery quicker. Put it to balanced and since then it's been ok, can't see any difference in operation or battery life.