yashsingh1/xdaforums huggingface dataset:
[Motorola Droid RAZR] BytecodeMe:
I'll do that.

It's finished I just have to replace the build.prop in the flashable .zip with the one I enhanced. I'll start on updating the script and posting the .zip right now.

Edit/update: the build.prop bricks, will have to make some edits to make it work, add another 2 or 3 hours on top of it.

UPDATE #2: I had to go through the entire unbrick method, took an hour and a half. will update tomorrow if possible. It'll take so long, because I lost the filews, have to make the edits again.
[Motorola Droid RAZR] The Sensei:
^ Dude you SIMPLY \M/ !
[Motorola Droid RAZR] BytecodeMe:
Thanks.:victory:

On an unfortunate note, I was on a custom ROM and my Speed it Up script was running stable. Now, on stock .211 causes reboots, I'm looking into this and I think it has to do with some of the values I set having to do with the hotplug governor. Seems that there is just one setback after the other... :(
[Motorola Droid RAZR] onepoint:
Has this been addressed? Running Rom Toolbox (Scripter) with the battery saver script I'm getting the nonexistent directory error.
[Motorola Droid RAZR] BytecodeMe:
Yes, I've checked the file paths and the only one that hasn't been addressed is sched_compat_yield. This is because it's in the CDMA kernel and not in the EU or any other kernel. I know because I don't get that error. If any of you still get one of those errors inform me please.
[Motorola Droid RAZR] BytecodeMe:
OP updated with new Speed it UP script, replacing the performance script, inform me of any problems with it. The Battery Saver is now called Make it Last, and it was given a slight update.

Enjoy.
[Motorola Droid RAZR] sreeman:
Get the non-existing directory error too. Ill prolly wait for the build.prop!

Thanks alot!
[Motorola Droid RAZR] BytecodeMe:
With what script? The updated ones or...?
[Motorola Droid RAZR] thepsen:
Hello

I ran this script and I check log. Don't know of this work ? Thanks
[Motorola Droid RAZR] BytecodeMe:
Yes, that means that for all but one value was applied, and that value does not apply to any kernel but CDMA.
[Motorola Droid RAZR] thepsen:
Thanks will monitor and update the status
[Motorola Droid RAZR] BytecodeMe:
Battery script was given an update!

Update on the flashable build.prop, I can say nothing else but I've tried a lot and looked for many typos and have been able to find almost nothing that would brick the phone, but I'll keep looking!
[Motorola Droid RAZR] Skyblue93:
Most people say hot plug gives better battery life and smooth game play but for me it lags.......

When i use this script (the performance one) i always change the governor back to interactive. Hot plug just lags for me. Browsing the web i can experience noticeable lag when on it.
[Motorola Droid RAZR] BytecodeMe:
Well, hardware can vary. In the script, where you see hotplug about half way down,change it to interactive to have it set interactive on boot. Or just delete the line.

Sent from my XT912 with Tapatalk
[Motorola Droid RAZR] sreeman:
Erm i tried with the ones in the front page.
[Motorola Droid RAZR] BytecodeMe:
Right before you posted I posted new versions of the script, and I didn't know whether you were talking about the old ones or the new ones.

Sent from my XT912 with Tapatalk
[Motorola Droid RAZR] deboyz1014:
Maybe I missed it but could this be run with safestrap enabled and another ROM installed? Reason I asked is because I'm running 211 Black Widow ROM with Safestrap and neither the file nor the copy/paste method of the make it last script work.

I'm using Script Manager, SU and BOOT enabled and the file is on the internal sd card. There are no funny characters that I can see on the script so I'm at a lost. The error I'm getting is like the one reported on post 12 and it shows up on the log. One funny thing is that if I use Rom Toolbox to run the script manually, it said script run successfully but there is no way for me to verify that. Any thoughts on what to try next?
[Motorola Droid RAZR] BytecodeMe:
Go into "Kernel Tweaks", the vales should be as following:

Dirty Ratio:90

Background Dirty Ratio:80

VFS Cache Pressure:20

In "CPU Control" the governor should be "hotplug" or "hotplugx" if you have it.

You I/O scheduler should be "noop" or SIO if you have it.
[Motorola Droid RAZR] magisterludi:
May i request a downloadable .txt file for the performance script? Im having the darndest time trying to copy paste the code. On my rzr i Tried chrome/stock browser and about 6 different txt editors. Seems there are no line breaks. /shrug

This may have been addressed, i confess i havent yet read the whole thread. OP's are updated, i didnt want to wind up with a depreciated ver.

Eager to give it a rip, code and values look solid.
[Motorola Droid RAZR] BytecodeMe:
Yeah, there used to be downloadable files, but the formatting on those got messed up and stopped the script from working. Sorry for the inconvience, but that's the way it has to be.
[Motorola Droid RAZR] magisterludi:
all good mate.

Appreciate the response, I'll grab it on a pc.

Thanks for your work.

I read something about a modified build.prop several pages ago, is it still floating around?
[Motorola Droid RAZR] BytecodeMe:
The deal was that I'm going to take it and enhance it and release in this thread. But there have been some setbacks, such as boot loops when testing the build.prop, so it's still coming, just not very fast.
[Motorola Droid RAZR] deboyz1014:
Dirty Ratio 90

Dirty Background Ratio 80

VFS Cache Pressure 15

The I/O is set to deadline right now, I just manually changed it to noop.

So other than VFS Cache pressure not matching and I/O changing manually, it should still help right?
[Motorola Droid RAZR] BytecodeMe:
Yes, you actually just confirmed what I've been thinking, I now know I have to confirm that sio and hotplugx are there if I also say that noop and hotplug are there. That will be fixed by the end if the day. Yes, the other values are still in place.

Do you have any other scripts or things in your ROM that would interfere with my script.? Sometimes when you exit Kernel Tweaks and then reenter everything is set to my values, it's either a glitch in ROM Toolbox or a conflict in what is being set.

Sent from my XT912 with Tapatalk
[Motorola Droid RAZR] tbhall77:
Just need to convert the txt files to unix. I've done the "tr" command on my phone before and it worked. There are other methods and utils out there if you prefer. Just google for "windows to unix file conversion" or "dos to unix file conversion"

More info here https://en.wikipedia.org/wiki/Newline
[Motorola Droid RAZR] prstorero:
I want to use the performance script but I read opening it with a windows text editor breaks it so how can I get it on my phone without copying the whole post then pasting it in a text editor on my phone then deleting all the other stuff lol
[Motorola Droid RAZR] BytecodeMe:
Hold your finger on the first line of the script in the code box, wait for the for the highlighting things(bars?) to come up and drag all the way down. It takes a couple tries, but I managed to do it.
[Motorola Droid RAZR] prstorero:
Anyway someone could post a downloadable file of it :) haha
[Motorola Droid RAZR] BytecodeMe:
Okay, I'll probably get one up tomorrow for those who really want it.
[Motorola Droid RAZR] prstorero:
Sweet thanks
[Motorola Droid RAZR] yyh2503:
i run it as a script in script manager but it says no such file or directorym all

than i set it run in boot and reboot

but after it i check the value what should be changed,but it isn't changed

my phone is on 676.226.3.en.EU

and i also try rom toolbox but it is same

sorry for my bad english,i am a chinese;)

but i really want to use this script ,i think it will help my phone a lot~~

thankyou
[Motorola Droid RAZR] BytecodeMe:
Are you setting it to Run as SU/root? It needs that or it won't work. Did you open it up in a windows based text editor before you got it on your phone?
[Motorola Droid RAZR] Skyblue93:
You're better off without running the script. When I was on .33 leak the script did help after the update it doesn't help much. In fact, it lags my phone.

The new update is perfect imo. Battery life is much better and the phone is buttery smooth.

Besides, I did a test on Antutu on the script I got 6113

without it i got 6452....quite a big difference!
[Motorola Droid RAZR] BytecodeMe:
Seems that I can't strike a balance, either too laggy or doesn't save enough battery, there's a trade off I guess. Anyway, that's because the system normally flushes "dirty" data to disc every .5-.10 seconds. Now it flushes every 3.1, a huge increase.
[Motorola Droid RAZR] yyh2503:
i run it with su

but i just copy your script to a txt file

and than i set an new script in script manager ,than copy from the txt
[Motorola Droid RAZR] deboyz1014:
I too have a heck of a time with SM, just use Rom Tool box instead.
[Motorola Droid RAZR] networkdood:
Some of the numbers listed in the script you download from the Google Drive file vary from what is posted in OP for the make it last script:

For example, line 3 and 5 vary per script.

Still getting no directories found error on this and I am now running .215, but I will keep on trying....

Permissions are ---rwxr-x for the script - is that what they should be?

---------- Post added at 01:43 PM ---------- Previous post was at 12:53 PM ----------

ok, so after downloading the script from Drive to Dropbox and to sd card, I followed the instructions, rebooted and now when I run the script, I get this:

card/Battery Script.txt'

So, I am all set, right?
[Motorola Droid RAZR] BytecodeMe:
Yes, the values vary because one is old and the other is new, housa would have to add me as a collaborator if I was to keep that script updated. Try using a scripter like in ROM Toolbox or a Buybox Installer.
[Motorola Droid RAZR] networkdood:
Well, my output that I posted....does that look correct?

It is much different than what I used to get, which were those directory not found errors.

---------- Post added at 03:00 PM ---------- Previous post was at 02:46 PM ----------

echo "2000000" > /proc/sys/kernel/sched_wakeup_granularity_ns

echo "1" > /proc/sys/kernel/sched_compat_yield

echo "0" > /proc/sys/kernel/sched_child_runs_first

Now, the line with echo "1" is not in the Google Drive version file.

I was reading online that it fixes broken schedule yield behavior, but is it a necessary line in the battery saving script?
[Motorola Droid RAZR] BytecodeMe:
Yes for the most part the output looks correct. No, it just helps slightly, the most active line is dirty_expire_centisecs and dirty_writeback_centisecs.
[Motorola Droid RAZR] prstorero:
Any luck on a downloadable version for the performance script?
[Motorola Droid RAZR] BytecodeMe:
Well no, actually, for some reason my phone won't let me upload to Dropbox, Drive, GMail, Skype or any other service.

To get your self a version on your computer that you can send to your self using any of the above services:

1. Highlight all of the text in side the code(script) box.

2. Right Click

3. Save as.

4. Send to your self and run.

Tell me if that works or not.
[Motorola Droid RAZR] prstorero:
Alright ill try that out in a bit, how will i be able to check if its working or not?
[Motorola Droid RAZR] BytecodeMe:
If your using Script Manager it shouldn't say "Directory not found" a whole bunch of times, if it doesn't say that then you're good. If you're using ROM Toolbox check

Dirty Ratio=90

Background Dirty Ratio=80

VFS Cache Pressure=20

All that is under "Kernel Tweaks", try using ROM Toolbox first, it's easier/works better.
[Motorola Droid RAZR] joshw0000:
I just set this to boot in Rom Manager and rebooted. It appears to have ran. VFS Cache Pressure is 15, not 20. Maybe we're running different versions.
[Motorola Droid RAZR] prstorero:
U can't click save as. Only options are copy search and inspect element.
[Motorola Droid RAZR] networkdood:
Go to Drive app and find file you want.

Hit the share option and choose dropbox.

Now, go to your dropbox and find that file and press and hold down and choose export.

Now choose save to SD card, internal or external.

BAMMMM!!! Problem solved.
[Motorola Droid RAZR] prstorero:
Got the script working. Weird I actually get a lower bench mark with it. 2900s. Without I get a bit over 3000 but not much of a difference
[Motorola Droid RAZR] deboyz1014:
What benchmark are you using?
[Motorola Droid RAZR] prstorero:
The typical quadrant. And yes I know its not the best thing to test with just posting my findings haha
[Motorola Droid RAZR] sreeman:
Hmm, finally got this to run. Sent the codes to my gmail and copied and pasted it.

Weirdly when i spam my scrolling at drawer it lags now. Never have i had this problem. Do i need to install the CPU governers too? Only ran the scripts.

Yes, i did reboot :D
[Motorola Droid RAZR] reaperzero:
to get the best effects you should get the CPU governors and schedulers SIO works great for me while using the hotplugx governors
[Motorola Droid RAZR] sreeman:
Okay, got the kernels and i/o scheduler installed. Seems alot better now! WIll see how the battery works!

Thanks alot !!
[Motorola Droid RAZR] RynoD:
Running script causes force close on many game apps. Don't know what setting would cause this
[Motorola Droid RAZR] BytecodeMe:
I just played Temple Run, VGBA Emulator, Cut the Rope, and Angry Birds, I had no force closes. Have you tried rebooting, clearing your cache and dalvik?
[Motorola Droid RAZR] reaperzero:
i noticed that the make it last script is amazing. it even reduces the temperature of my battery. with out the script i average at 30 to 33 Celsius. now its hovering at 24 to 30. awesome battery life to boot
[Motorola Droid RAZR] RynoD:
I'll try it maybe it's just stupid zynga apps words with friends always fc's
[Motorola Droid RAZR] deboyz1014:
Very weird, so I restored a backup that I did yesterday and now the script is not behaving correctly.

Using Rom Toolbox and I even copy/pasted the script again just to make sure. It is set on boot but seems its not running

DR - 20

DBR - 5

VFS CP - 100

CPU is set to interactive and I/O is set to deadline

If I don't run the script and set CPU to hotplug and I/O to noop, it stays but if I set script on boot, it changes those settings back. If I run the script manually, it spits out one error like it did before

stderr:

/data/data/com.jrummy.liberty.toolbox/files/scripts/battery[17]:cannot create /proc/sys/kernel/sched_compat_yield: No such file or directory

DR - 90

DBR 80

VFS 15

Looks like the script is not running on boot even though its set to run. I even cleared out the data on Rom Tool Box, maybe I need to reinstall it.
[Motorola Droid RAZR] BytecodeMe:
Try setting the script to run on boot, exit Scripter and then go back in to Scripter and if it is no longer to be run on boot, then you know that ROM Toolbox is having problems. I've had that problem a lot.
[Motorola Droid RAZR] deboyz1014:
Still shows as on boot. Did a clear data on RTB app and still have same issue, what did the trick finally was uninstall/reinstall.
[Motorola Droid RAZR] BytecodeMe:
I'm glad you could solve your problem. :)

Sent from my XT912 with Tapatalk
[Motorola Droid RAZR] housas08:
Sorry guys that i was absent for so long... Was quite busy.

Here is the folder with all the versions of the scripts up to date:

https://docs.google.com/open?id=0B1vV1mGH5rAOeTV5d0kyUTVRSTQ

I made editions for both CDMA GSM versions (for make it last script - removed the line that gives error on GSM models).

Running the performance script returned many "no such file" errors, "create file" errors and "permission denied" (at mmcblk0 and mmcblk1 lines). Maybe it's an issue with GSM versions?

All files tested and working (as far as file formatting is concerned).
[Motorola Droid RAZR] BytecodeMe:
OP updated with that new link.

Can I have just some of the errors, it makes it easier than just checking every single mmcblk line.
[Motorola Droid RAZR] housas08:
Here is the link with the output: http://imageshack.us/photo/my-images/534/screenshot2012072313070.png/

The first 2 file exist errors are caused because i had already flashed the kernel modules, so it is normal.

p.s. the google docs link has all the scripts ready to install so u can describe it as a global download link - folder for all scripts in the OP. :)
[Motorola Droid RAZR] bogante:
25% SCREEN? who the f*ck u dit that? Leviathan26
[Motorola Droid RAZR] BytecodeMe:
Thank you.:good: :)

Okay OP edited to show this. Just some questions, are you running that on boot? I know it's a bad question, but I don't really feel like investigating all of those file paths.
[Motorola Droid RAZR] housas08:
I use init.d folder for all the scripts. I run the script via Script manager manually to check for errors. I daily use the battery script and i'm pretty satisfied about it. I ran the speed up just for testing.
[Motorola Droid RAZR] BytecodeMe:
Sorry for being away, I had to set up my new computer, and then I had the inspiration to write my guide... Anyway, I'll take those errors into account and clean and update it.
[Motorola Droid RAZR] calamity:
This might've fried my sim card all i did was flash the overclock zip and got stuck on 1x was on eclipse ics flashed in safemode had to get a new sim
[Motorola Droid RAZR] BytecodeMe:
Wrong thread? There is no over clock zip here.
[Motorola Droid RAZR] St33l:
Why you insmod hotplugx, but in script you use

for me not work, in this file there is allways 30000. In console I see "permission denied"

for me this commands not work. allways said that option "noauto_da_alloc" unknown.

what I'm doing wrong? )

Firmware: 4.0.4 China
[Motorola Droid RAZR] BytecodeMe:
Insmoding hotplugx and using hotplug was just laziness and experimentation by me, I was testing if and else statements in the script. They work, just haven't updated them yet.

You're doing nothing wrong, those are issues with the script that I haven't worked yet because I've been very busy, with life and other projects. I'll probably take out what isn't working and add some more stuff in in a couple of days.
[Motorola Droid RAZR] fix-this!:
does the "make it last" script interfere with governors i set? also what is the battery life expected to be on a standard razr with this, ball park?
[Motorola Droid RAZR] dtrail1:
This is what I've got WITHOUT battery script :

I am using the latest kernel. With activated battery script I got only 3 hours screen on time. Now I am using Black Widow AOKP and battery life is better than MIUI (screenshot). I got about 4,5 hours screen on time on the first use after flashing.

Gesendet von meinem XT910 mit Tapatalk 2
[Motorola Droid RAZR] MeNaCe2s0cieTy:
Dtrail, what theme are you using on BlackWidow??
[Motorola Droid RAZR] The Sensei:
Does this work for 676.226.3.en.EU Retail ?
[Motorola Droid RAZR] taigetos83:
Yes, it does :)
[Motorola Droid RAZR] danny.sunju:
Hi.. Will this run on stock ICS Rom (rooted) running 673.94.328.XT910.AsiaRetail.en.03?
[Motorola Droid RAZR] BytecodeMe:
I would assume so, I only have access to a CDMA RAZR so I couldn't tell you.
[Motorola Droid RAZR] reaperzero:
i can confirm it works :/ im on PSHAsia retail and the difference is that one has carrier bloatware and the other does not
[Motorola Droid RAZR] danny.sunju:
Oh thanks. I will let you all know in sometime. And if I want to undo it, how do I do it? :o
[Motorola Droid RAZR] BytecodeMe:
Just stop the script from running on boot, and it will all go back to normal.
[Motorola Droid RAZR] danny.sunju:
Thanks... Let me try it and post the result..
[Motorola Droid RAZR] w0rdie:
Looking forward to seeing your results.
[Motorola Droid RAZR] gamethu1:
hello

i use razr xt910 on MIUI ics france, the script does not seem to work, before that, i tried with rom Artic 3.0.0 but i failed ...
[Motorola Droid RAZR] danny.sunju:
Hey all. I am running the script on my phone but I am not too sure if it's doing its work.. I am getting close to three hours of screen time every time after a 100% charge..
[Motorola Droid RAZR] tboooe:
Thank you for this script. I am running the battery saver one on my GSM RAZR with modded Eclipse ROM. The script was installed using ROM Toolbox. So far my battery drain at idle has decreased from 0.9%/hr to 0.6%/hr which is a nice improvement. I am not sure about battery life during usage though. It still seems my RAZR gobbles up batteries like crazy when in use!
[Motorola Droid RAZR] BytecodeMe:
Have you seen improvement in battery life? Since you're getting 3 and a half hours of screen time it seems to me that there is improvement.

Thank you for doing the math on this, I really appreciate it.
[Motorola Droid RAZR] ghaf85:
It is work on miui v4 razr gsm?
[Motorola Droid RAZR] reaperzero:
ya know you could try first, and yes it works >_>
[Motorola Droid RAZR] ghaf85:
i try it...

but my screen still 60%...it seem like usual drain...no effect..
[Motorola Droid RAZR] BytecodeMe:
Do the math, like that guy.
[Motorola Droid RAZR] ghaf85:
can you give example application that show battery good enough..
[Motorola Droid RAZR] Garry1313:
Not able to run the battery script. The logs says following error.

Proc/sys/kernel/sched_compat_yield : no such file or directory

What wrong i am doing??
[Motorola Droid RAZR] BytecodeMe:
That means everything but that line ran correctly. It ran just fine, you'll still get the desired effects.
[Motorola Droid RAZR] reaperzero:
i used to get these errors. but then i just modified the script to not point to those directories :D
[Motorola Droid RAZR] JerseyFF:
My Maxx freezes once it has booted after running the "Make It Last" script.

Any way to disable the script from running on boot with ROM Toolbox?
[Motorola Droid RAZR] royalbloodvi:
do the SIO scheduler / hotplugx work with the make it last scipt or only the fast script?
[Motorola Droid RAZR] :
Deleted
[Motorola Droid RAZR] kaluoshi:
hi Leviathan26 and guys! so can i use it on Gnexus with trinity kernel and noop scheduler? thanks in advice :D
[Motorola Droid RAZR] BytecodeMe:
Yes, you should be able to. But what Morfic has chosen should be better for many of the values. I love his kernels, used his on all my unlocked BL devices!
[Motorola Droid RAZR] kaluoshi:
thanks man i'll keep morfic stuffs so :D great work btw :)
[Motorola Droid RAZR] kaystanford:
Just wondering if this will work on my rooted stock ICS ROM?

Cheers!
[Motorola Droid RAZR] kaystanford:
Oh.

Nvm. Just back tracked and saw danny.sunju tried it too.

Thanks!
[Motorola Droid RAZR] kaystanford:
You managed up to 24 hours? What version of Android are you using? I had Juice Defender + Setcpu + The battery savng script still cant get 24 hrs. I had an average of 12 hours only and its a new device.
[Motorola Droid RAZR] dtrail1:
Juice Defender eats more battery on ICS, it causes kernel/partially wakelocks which lasts the battery saving effect - it's better to set off the sync control in JD to get no more wakelocks. You can use LLama instead of JD. You can set complex rules to get the same effects like with JD but without keeping the device awake all the time. I also suggest you to run CM10 rom, it has incredible battery life.
[Motorola Droid RAZR] blackops11252:
I usually average 1 day or 2 with my razr using the battery script.!
[Motorola Droid RAZR] kaystanford:
Still cant reach 24 hrs

Amazing! Share us your settings and what ROM? :D

I'm on AOKP now with a combination of this script. Not sure whether it really helps. But still can't get that legendary 24 hours or 2 days on average use. Still hoping to get there..