Auto brightness - Droid Incredible Q&A, Help & Troubleshooting

So, using the ota I see it uses a range if values for the auto brightness.
Is there a mod or way to move the range down? As it is now, my eye sockets burn after looking at the web in a darkened room.
Sent from my ADR6300 using Tapatalk

I seem to have the opposite problem. On every ROM I have installed on my Inc, using the Auto setting always makes the screen way too dim and it is slow to brighten back up when light hits the sensors. I think maybe the screen protector is causing some of that but I'm not sure. Usually after this I just set my CurveFish widget to 25% and leave it at that.

I'm guessing there aren't any mods?
Sent from my ADR6300 using Tapatalk

Just bumping this hoping for something.
Can;t a flashable zip be made that just changes the range auto brightness uses?

I changed my default brightness setting in the build.prop file to 10. Will test tonight
-- Sent from my HP TouchPad using Communities

Didn't change anything.
Screw it. I'm decompiling the required resource file tomorrow.
Sent from my ADR6300 using Tapatalk

I'm actually interested in this so we all have a closer configuration that everyone can use on any rom. cm7 has like 19 levels and slow to adjust and I'm hearing rumors only 10 levels actually work

dyetheskin said:
I'm actually interested in this so we all have a closer configuration that everyone can use on any rom. cm7 has like 19 levels and slow to adjust and I'm hearing rumors only 10 levels actually work
Click to expand...
Click to collapse
I'll post an update tomorrow for.sure.
Sent from my ADR6300 using Tapatalk

zoomy942 said:
So, using the ota I see it uses a range if values for the auto brightness.
Is there a mod or way to move the range down? As it is now, my eye sockets burn after looking at the web in a darkened room.
Sent from my ADR6300 using Tapatalk
Click to expand...
Click to collapse
It's funny I seem to have the opposite problem with stock 2.2 on mine. My screen will go quite dim in the sunlight and I need to turn the lcd off and on again to restore it back to proper brightness. It only seems to happen when I let the LCD go dim while in the browser.

Done. I'm testing now. If it works I'll upload it.

zoomy942 said:
Done. I'm testing now. If it works I'll upload it.
Click to expand...
Click to collapse
Okay. It's 100% working. I had to pull the framework.res, decompile it, adjust the settings (called arrays), recompile it, and reinsert it into my rom. Once I did that, it broke some stuff like accounts and syncs. I knew it would and i reloaded them.
Once i knew it worked, i inserted that file into a rom I made and reflashed. Works great. Now it will go full bright in a bright room and in a dark room it fades down to 10, which is the lowest number.
Exactly what i wanted since at night the screen was blinding.
How does anyway want me to get the file to them? Upload the file? My rom?
FYI - my rom is just a simple OTA that's rooted but tons of stuff is removed from it. It's so much more than debloated....

What exactly did you change, and where is it located in the framework-res.apk?

Once I decompiled the framework-res.apk, I look in
\framework-res\res\values\arrays.xml
Opened it in notepad and changed this part...
Code:
<integer-array name="config_autoBrightnessLcdBacklightValues">
<item>11</item>
<item>41</item>
<item>91</item>
<item>126</item>
<item>161</item>
<item>164</item>
<item>187</item>
<item>210</item>
<item>233</item>
<item>255</item>
Then i recompiled the file and inserted the framework file into my ROM archive/zip file.
A flashable zip would be ideal then we could list it as a mod.
Huzaa!!

Once I decompiled the framework-res.apk, I look in
\framework-res\res\values\arrays.xml
Opened it in notepad and changed this part...
Code:
11
41
91
126
161
164
187
210
233
255
Then i recompiled the file and inserted the framework file into my ROM archive/zip file.
A flashable zip would be ideal then we could list it as a mod.
Huzaa!![/quote]
did you try it? I'd love to offer this as a mod to the community
Click to expand...
Click to collapse

zoomy942 said:
did you try it? I'd love to offer this as a mod to the community
Click to expand...
Click to collapse
Yes just got finished and rebooted. Great find. Just like you said bright in bright light and dim in the dark.
The only problem with making this a flashable is that a bunch of other mods also edit the framework-res.apk. So flashing this mod would wipe out those mods and flashing other mods would wipe out this one. Also i believe some rom devs edit their framework-res file for their specific rom. So a flashable of this mod may mess up other things in the rom. As a manual edit though its awesome.

Yes just got finished and rebooted. Great find. Just like you said bright in bright light and dim in the dark.
The only problem with making this a flashable is that a bunch of other mods also edit the framework-res.apk. So flashing this mod would wipe out those mods and flashing other mods would wipe out this one. Also i believe many rom devs edit their framework-res file for their specific rom. So a flashable of this mod may mess up other things in the rom. As a manual edit though its awesome.
Click to expand...
Click to collapse
Understood, and I surely don't want to go breaking stuff. Too bad though because I'd love to contribute to xda and my fellow inc owners with this. That auto brightness was making me nuts.

If you want to spend the bucks, Juicedefender beta with UltimateJuice has an excellent brightness control, plus a lot more features. Been using it for several months and I'm very happy with it. CPU control works great with tiny's newest kernel, too.

Yes just got finished and rebooted. Great find. Just like you said bright in bright light and dim in the dark.
The only problem with making this a flashable is that a bunch of other mods also edit the framework-res.apk. So flashing this mod would wipe out those mods and flashing other mods would wipe out this one. Also i believe some rom devs edit their framework-res file for their specific rom. So a flashable of this mod may mess up other things in the rom. As a manual edit though its awesome.
Click to expand...
Click to collapse
I also found changing the default brightness in the build.prop made the initial brightness detections smoother.

Great work.

steelerfnpeter said:
Great work.
Click to expand...
Click to collapse
Thanks! Just wish I could advertise it more.
Sent from my ADR6300 using Tapatalk

Related

LCD Calibration (Nova color fix)

Not sure if this is common knowledge, but Storm over on the Nexus board built a color calibrator program that does a great job fixing color balance problems (I'm looking at you Nova LCD).
http://forum.xda-developers.com/showthread.php?t=745248
I am successfully using the cyanogen nightly apk version to correct the blue/purple hue on my nova. It took a little messing around and I do not have a color meter, but I ended up getting results that look great (used my macbook LCD which is color calibrated as the target).
Every LCD is different, but my settings are 919 red/ 905 green / 722 blue.
im about to try this out myself. so i flash to install this???
which one did you install?
Rydah805 said:
im about to try this out myself. so i flash to install this???
which one did you install?
Click to expand...
Click to collapse
If you have CM6, it's already installed... Just go to Settings -> Cyogenmod Settings -> Display -> Render UI, and choose one of the last 3.
Otherwise, flash the Universal APK from that thread-- it worked for my on BakedSnack and Fresh. Don't forget in any case to install the Calibrator APK... it allows you to manually tweak the settings, and also ensures that any settings you choose will be re-applied at bootup.
Well as I don't have cm6, it seems the sense version might be incompatible. I flashed the version sense (desire) and installed the apk. Upon changing any of the sliders results in a fc.
For now I think this calibration is limited to cm6; unless I just screwed something up and somebody else can get it to work. I'm going to try and use the universal install next and see if that'll get it to work. If it doesn't then us sense users are sol.
edtate said:
Well as I don't have cm6, it seems the sense version might be incompatible. I flashed the version sense (desire) and installed the apk. Upon changing any of the sliders results in a fc.
For now I think this calibration is limited to cm6; unless I just screwed something up and somebody else can get it to work. I'm going to try and use the universal install next and see if that'll get it to work. If it doesn't then us sense users are sol.
Click to expand...
Click to collapse
I had thought i had said if you don't have CM6, then try flashing the Universal version, not the Sense one-- the sense one seems limited to a specific ROM for the Desire. I had no issues flashing the Universal one on BakedSnack and Fresh, which both still have Sense.
Apk
One thing to note for CM6 users - the apk file allows you to tweak the 3 color bands to any setting you want, rather than just the 3 presets provided in the Cyanogen render effect menu. I was getting too much yellow in all of the N1 presets and was able to get good whites with the sliders.
I'm not sure how to run this on sense. Why would anyone want to use sense? I'm in a fast 4g area and I still cant stand it.
for stock with root ota 2.2 version .28 odex, use universal zip.
Sent From My HTC Evo Using Tapatalk Pro!
Using damage control jit performance profile sense less with screen brightness at 200 red at 942 green at 892 and blue and 996 and looking great! thanks this is what I have been looking for much cred
Ps when adjusting the screen brightness makes big difference
the universal app keeps fc'ing on me
I guess I'll try the CM version..
Thanks for the heads up on this, my dad just got an Iphone 4 and i was comparing the two displays by playing the same video on both, and noticed that my epson screen has quite a blue hue. He wouldn't stop poking fun at my Evo...until today! Played around with this and got it to be quite a bit more accurate, no more smack talking from him now haha.
Fc
I get force close... I installed the universal.zip and the normal.apk and when I open the app and touch any of the settings the app force closes... Anyone wanna do a mini tutorial on how they got it?
Wow I didnt even notice this. Thanks man!
mrcamposd said:
I get force close... I installed the universal.zip and the normal.apk and when I open the app and touch any of the settings the app force closes... Anyone wanna do a mini tutorial on how they got it?
Click to expand...
Click to collapse
You flash the zip file just like you would anything else-- there's really not much to it.
You don't mention what ROM/Kernel you are running... that might help.
sohr said:
You flash the zip file just like you would anything else-- there's really not much to it.
You don't mention what ROM/Kernel you are running... that might help.
Click to expand...
Click to collapse
Sorry, Yeah that's what i do and the app keeps crashing.
Evo 4G
Running Android 2.2
Baseband v. =2.15.00.07.28
Kernel v.=2.6.32.15-g3a86144
Build number= Fresh evo 3.2.0.0 by flipz
Software number= 3.28.651.1
is that what you have to or are you using another rom?
Finally I got it to work with another kernel. I have all colors in 1000... Tell me your colors so I can compare and maybe use yours
mrcamposd said:
Finally I got it to work with another kernel. I have all colors in 1000... Tell me your colors so I can compare and maybe use yours
Click to expand...
Click to collapse
Guess it doesn't work with netarchy's 4.1.9.1cfs kernel, because I am experiencing the exact same symptoms and am using the same ROM as you. I was beginning to think it was ROM related. What kernel did you end up using?
mrcamposd said:
Finally I got it to work with another kernel. I have all colors in 1000... Tell me your colors so I can compare and maybe use yours
Click to expand...
Click to collapse
I am currently using:
red 972
green 918
blue: 783
Although what you use will all be personal preference... the big thing is pushing the blue down as it is quite overpowered.
freeza said:
Guess it doesn't work with netarchy's 4.1.9.1cfs kernel, because I am experiencing the exact same symptoms and am using the same ROM as you. I was beginning to think it was ROM related. What kernel did you end up using?
Click to expand...
Click to collapse
Yes i'm assuming its a kernel related problem not a rom problem... Im using this kernel it works pretty good and I'm using the bfs one awesome speed in quadrant hitting 1400's
(Im using the beta version "Revision 4.1.9.1-BFS BETA - Fresh Compatible")
http://forum.xda-developers.com/showthread.php?t=719763
sohr said:
I am currently using:
red 972
green 918
blue: 783
Although what you use will all be personal preference... the big thing is pushing the blue down as it is quite overpowered.
Click to expand...
Click to collapse
Those settings seems too dim for me. I guess personal preference has to do a lot with these settings lol... (sticking with the 1000's RGB color)
thanks a lot
mrcamposd said:
Those settings seems too dim for me. I guess personal preference has to do a lot with these settings lol... (sticking with the 1000's RGB color)
thanks a lot
Click to expand...
Click to collapse
If you stick with 1000s for all 3 values, you might as well as not have the APK installed at all, IMO.
The settings you want to use may vary slightly based on your current lighting conditions and the brightness. On my settings, the screen is tiny,tiny bit dimmer-- but that is only because the blacks and greys become true blacks and greys and not dark purple and lilac. At the bare minimu, leave your red and green at 1000 and push the blue down until your greys are true greys....

[Q] Help with bootanimation

I am failing at making a bootanimation.zip and I am not sure why. Anyone experienced want to take a look at my file and give me a hint as to why this doesn't work? It gets rid of the default Android, but just displays a black screen until the homescreen shows up.
Did I stump everybody? I figured I was just missing something silly like the picture files need to be in 7.5 bit format or something.
Sent from my Epic 3g
JMMusic said:
Did I stump everybody? I figured I was just missing something silly like the picture files need to be in 7.5 bit format or something.
Sent from my Epic 3g
Click to expand...
Click to collapse
I haven't a clue...I'm just here to help that uncomfortably alone feeling. :-( good luck
Id like to know/learn how to make a bootanimation is there a section/tutorial on this somewhere??
I see there's a section on theme-ing. Am i mising something?
Sorry not trying to thread jack, just thought the OP can shed some light.
Good luck on your question!
Haven't tried it yet myself, but I've noticed these tutorial threads in the past:
http://forum.xda-developers.com/showthread.php?t=1096068
http://forum.xda-developers.com/showthread.php?t=1234611
You must save the zip as an uncompressed zip file. Compression level should be set to storage mode.
Sent from my SPH-D700 using xda premium
bbelos said:
Haven't tried it yet myself, but I've noticed these tutorial threads in the past:
http://forum.xda-developers.com/showthread.php?t=1096068
http://forum.xda-developers.com/showthread.php?t=1234611
Click to expand...
Click to collapse
I hadn't seen that first thread (or the tool in it). Neat. Thank you. Wish I had seen that before I started.
It still didn't work, but at least that lets me know that it really is an odd problem.
starskyrob said:
You must save the zip as an uncompressed zip file. Compression level should be set to storage mode.
Click to expand...
Click to collapse
That I am doing. Though I have noticed that sometimes "store" in WinRar compresses by just a few bytes. I made one that was completely not compressed (byte match for stored size versus on drive size). Still not working, so I've ruled that out as being the issue.
I'm attaching a version created by the tool in the link above. It still doesn't work. I have no clue why... still looking for hints.
JMMusic said:
I'm attaching a version created by the tool in the link above. It still doesn't work. I have no clue why... still looking for hints.
Click to expand...
Click to collapse
That looks like it'd be a cool animation. I'll mess with it later when I get home. But at first glance comparing it to other animations I have that work, they are either greyscale or RGB jpgs @ 72dpi. Yours are indexed pngs @ 300dpi. That link says png should be ok, but it says to use RGB. Maybe you could try that next.
Here you go. I converted the images to 72dpi RGB jpgs. I'll still probably try again leaving them as 72dpi RGB pngs, but these animations work now.
I included your original 30fps version, but also slowed it down a bit. I think the 12fps looks good, but unless you have just wiped your dalvik cache, you might not have enough time to see very many blinks. The 21fps version isn't bad, but I think it's still a bit too fast. Tweak the speed to your preference.
These are not flashable, btw, so just copy over with root explorer or whatever.
Has to be renamed sanim.zip to work in GB.
Sent from my Samsung Legendary 4G, a Universe UTES phone, running "two.three.five"
True, I guess I assumed he was using a kernel with the symlink to bootanimation.zip since his phone was actually trying to use the original file. Thanks for the reminder to anyone else trying to get this to work.
Sent from my SPH-D700 using XDA App
I've tried this myself many times to no evail. I get boot animations from a rom that i like and try to put the boot ani in a diff rom and it never works. i'm never able to get the files into the other zip. I can't wait till i figure out how to completely customize roms to exactly what i want! i'm learning a little more day by day. this thread has helped me a little and will now be my reference if i run into this problem once i finally make my own boot ani. Thanks guys!
bbelos said:
Here you go. I converted the images to 72dpi RGB jpgs. I'll still probably try again leaving them as 72dpi RGB pngs, but these animations work now.
I included your original 30fps version, but also slowed it down a bit. I think the 12fps looks good, but unless you have just wiped your dalvik cache, you might not have enough time to see very many blinks. The 21fps version isn't bad, but I think it's still a bit too fast. Tweak the speed to your preference.
These are not flashable, btw, so just copy over with root explorer or whatever.
Click to expand...
Click to collapse
I am thinking the editor I was using for the images was doing something funky. Anyway, much appreciated, the 21 fps one works beautifully.
JMMusic said:
I am thinking the editor I was using for the images was doing something funky.
Click to expand...
Click to collapse
GIMP is typically the only image program I use, hasn't failed me yet.

How do you disable the crt animations on Calk's rom?

Hey all, the crt animations are just plain buggy. Is there any way to permanently disable and remove it when running calks rom?
I know how to disable it via settings and display settings under turn off all animations but I want all animations minus the crt?
Thanks in advance you all.
Sent from my SPH-D710 using Tapatalk
Try downloading Spare Parts from Market and set transition animation to fast and leave window animation normal
Sent from my SPH-D710 using xda premium
I tried this method and it worked but now I just flashed a all in one theme for hotspot fix and rotational lag and it is showing crt again. Does anyone have a permanent disable or fix for this? To me the crt is extremely buggy and inefficient to use as it wastes my time. The wake is already slow as is I don't need to wait for the extra delay.
Sent from my SPH-D710 using Tapatalk
If you know how to decompile your framwork-res.apk file with apktool, you can disable.
Change "<bool name="config_animateScreenLights">false</bool>" to "<bool name="config_animateScreenLights">true</bool>"
Don't do that if you don't know how or haven't done a backup though. You'll get bootloop if you mess it up.
Hi - Any other way than spare parts to disable this? I'm not familier with the APK tool. I can look into if I need be, but if there is a more straight forward way.....
Spare parts isn't currently changing anything for me.
EpicAOSP ROM, AIO Mod
i beleive the most recent 2 new ROM versions have it disabled by default. but there is a zip somewhere in E4GT forums that allos you to disable. i'd do a search for that if you dont want to flash a new ROM.
do people really like it that much that it has to be included on every ROM? I was always kind of indifferent to it
Im with the OP. I cannot stand the CRT annimation. It was cool at first. For the first week or so, but now its just old. I don't get why all roms include it now. Is there a .ZIP that could be flashed or any other methods to remove (that dont risk bootloading)
PimpDaddyInc said:
Im with the OP. I cannot stand the CRT annimation. It was cool at first. For the first week or so, but now its just old. I don't get why all roms include it now. Is there a .ZIP that could be flashed or any other methods to remove (that dont risk bootloading)
Click to expand...
Click to collapse
The action is in the one of the xml files within your framework-res.apk. Now there seems to be work arounds but to to fix it you have to decompile the file and change the setting. Its honestly not a big deal to do and you may learn something along the way.
I believe these developers do a lot for us and certain small things like this we should all try and learn so we can help ourselves and not have to bother them.. IMHO
bralkan said:
Hi - Any other way than spare parts to disable this? I'm not familier with the APK tool. I can look into if I need be, but if there is a more straight forward way.....
Spare parts isn't currently changing anything for me.
EpicAOSP ROM, AIO Mod
Click to expand...
Click to collapse
Go to this link: http://forum.xda-developers.com/showthread.php?t=1307635
It explains how to decompile/recompile. Note that you will be working on framework.apk and not on systemui.apk
Then do as $roid said and
Change "<bool name="config_animateScreenLights">false</bool>" to "<bool name="config_animateScreenLights">true</bool>"
meatwadathf said:
Go to this link: http://forum.xda-developers.com/showthread.php?t=1307635
It explains how to decompile/recompile. Note that you will be working on framework.apk and not on systemui.apk
Then do as $roid said and
Change "<bool name="config_animateScreenLights">false</bool>" to "<bool name="config_animateScreenLights">true</bool>"
Click to expand...
Click to collapse
Still got to use APK tool for this though and honestly its not that hard...
CRT is the shiznit !
I love my counter rotational transponder !
Sent from my tofu plasma converter.

[DEV] Rotating capacitive buttons for ICS and other builds

Credits goes to st.matt, he gets full credit for the programming. He seemed a little busy, so I thought I'd spread the news so you guys can implement into your builds.
st.matt said:
Also just a run-down of how it works for anyone that is interested:
I use three different elements to get it working. Firstly, I use a small addition to surfaceflinger to set a system property (sys.orientation.landscape) to 1 when it is in landscape mode (either 90 or 270 degrees rotation) and 0 when it is in portrait mode (0 degrees rotation).
When this is set an init service will start depending on the value of sys.orientation.landscape, which in turn starts a script (/system/etc/rotate_lights.sh) which takes the brightness value from the expected led class (ie. if it's changing to landscape it will look at /sys/class/leds/button-backlight-portrait/brightness) and then set this to the new orientation's led class.
The third part is a small modification to the lights lib which also checks that system property when making changes to the button backlight brightness so that it sets it to the correct class.
Click to expand...
Click to collapse
The necessary files/code are on Virtuous' ICS vivo repository: https://github.com/vivo-ICS/android_device_htc_vivo, and you will also need the patched proprietary libsurfaceflinger.so that references to the changes.
Any way to make this backward compatible with cm7.2?
Un1c0de said:
Any way to make this backward compatible with cm7.2?
Click to expand...
Click to collapse
made a CM7.2 kang for you Inc2 users.
All I did was put in the latest commits as of March 03 2012 and added the rotating softkeys. I can't really test it because I don't have an Inc2, so back up your data in case you are not sure if it will work.
You can flash this without wiping if you are on 7.x already.
For the IncS, I know the rotating buttons for them are not perfect. Sometimes you have to toggle the brightness to get it working. Other times it might take a few seconds to rotate instead of immediately. This is because this script was originally written for ICS roms in mind, but it's backwards compatible with GB.
http://www.mediafire.com/?lggqggdx1m4n656
Wow thanks Kaijura. Downloading now, will post back with results
Sent from my Incredible 2 using xda premium
Thanks Kaijura for posting the info, and the CM7 build. Appreciate it a lot
Is this rom dependent? It will only work on cm 7.2? has anyone tried it on miui? Or any other roms?
Sent from my Incredible 2 using xda premium
Ihatepullups said:
Is this rom dependent? It will only work on cm 7.2? has anyone tried it on miui? Or any other roms?
Sent from my Incredible 2 using xda premium
Click to expand...
Click to collapse
Will be trying on miui.us shortly.
Never mind its beyond my knowledge and time.
Sent from my Incredible 2 using xda premium
knipp21 said:
Will be trying on miui.us shortly.
Never mind its beyond my knowledge and time.
Sent from my Incredible 2 using xda premium
Click to expand...
Click to collapse
Ah, that blows would have been cool... Hey if someone points me in the right direction, I'll try: I know how to use adb and the sdk and I'm an experienced ROM'aholic
Sent from my Incredible 2 using xda premium
Awesome. Hopefully I have time tonight to check it out. Thanks
knipp21 said:
Will be trying on miui.us shortly.
Never mind its beyond my knowledge and time.
Sent from my Incredible 2 using xda premium
Click to expand...
Click to collapse
Ihatepullups said:
Ah, that blows would have been cool... Hey if someone points me in the right direction, I'll try: I know how to use adb and the sdk and I'm an experienced ROM'aholic
Sent from my Incredible 2 using xda premium
Click to expand...
Click to collapse
its different for miui, because we dont build it from source and cant cherry pick commits
miui is more like a sense rom port that uses cm9 or another aosp rom as a "base"
any significant changes have to be done in smali, which is more involved than java source....i k nowwhat has to be changed (or at least part of it) and where for rotating buttons in miui by diffing the builds from aerovan before and after it was implemented but it was a no go on my part...and didnt seem worth the effort to keep pursuing it atm
I tried this yesterday. My phone wouldn't get past the HTC boot screen. I ended up having to pull the battery and reflash my current ROM.
zohner said:
I tried this yesterday. My phone wouldn't get past the HTC boot screen. I ended up having to pull the battery and reflash my current ROM.
Click to expand...
Click to collapse
Hmm, well I guess that didn't work. If you push /system/lib/libsurfaceflinger.so from an earlier working build you should probably be able to boot.
I just copied the file over from the vivo build which seems that it doesn't work with the vivow.
Guess the vivow surfaceflinger is done differently.
kaijura said:
made a CM7.2 kang for you Inc2 users.
All I did was put in the latest commits as of March 03 2012 and added the rotating softkeys. I can't really test it because I don't have an Inc2, so back up your data in case you are not sure if it will work.
You can flash this without wiping if you are on 7.x already.
For the IncS, I know the rotating buttons for them are not perfect. Sometimes you have to toggle the brightness to get it working. Other times it might take a few seconds to rotate instead of immediately. This is because this script was originally written for ICS roms in mind, but it's backwards compatible with GB.
http://www.mediafire.com/?lggqggdx1m4n656
Click to expand...
Click to collapse
Just tried a flash over but didnt work for me. I guess I can always try a wipe and install.
This wouldn't be hard to add to Miui -- as long as they have no weird additions to libsurfaceflinger. You just need the patched liblights, patched libsurfaceflinger (built for CM), script in /system/etc and changes to init.vivo.rc (or init.vivow.rc for Inc2).
Requires no changes to smali or framework.
The other thing is that if someone wants to clean it up and submit it to CM then the MIUI team will pick it up themselves (someone already did this but didn't seem to have to skill / couldn't be bothered to clean it up to their standards and also didn't really submit it correctly).
I would do this but I don't really have the time these days.
Also: I suspect the problem with the lights not working sometimes could be solved just by adding the conditional I have that checks first to see if the brightness is zero to both orientations (in rotate_lights.sh). I will have a quick look at this soon.
just wanted to share a slight modification in the script. When the brightness level is set to the least the leds turn off completely. The attached script makes sure the leds do not turn off completely at this instance. Unzip the file and replace the file in your /etc/ folder. You may want to make a backup of your existing rotate_lights.sh just in case. Ensure the permissions on the file are the same as before after copying.
Just realized that the settings work only the first time when the phone is rotated. I guess I need a better fix. Sorry, remove the attachment as it has undesired issues. Fix No damn good.

[MOD] Disable low battery, battery temperature pop-ups and full battery notification

The reason for this little hack is the fact those 2 pop-ups can become an extreme double-annoyance while driving in hot weather. Imagine, your battery is below 15%, yet scorching hot, beyond the charging cut-off threshold. Connect a charger and you get bombarded with the "charging paused, battery temperature too high" pop-ups. Disconnect it and you get a low battery ones. This little patch deals with the issue by simply disabling the annoying pop-ups. It also disables the annoying battery full notification.
Please note, this doesn't modify any functionality, it just disables the pop-ups. The battery will not and should not charge when overheated.
Instructions:
Download and unpack "BatteryPatch.zip", you should now have "Patch.js" jscript along with the "utils" directory.
Fetch your "/system/app/SystemUI.apk" from the device, place it in the same directory, along with the "Patch.js".
Apply the patch by launching "Patch.js" and push the patched SystemUI.apk back to the device.
Updates:
Not every ROM seems to have the battery full notification and/or battery overheating popup. Patching those is now optional, the script will show a warning in case it fails to patch those instead of erroring out completely.
There are some ROMs out there with showLowBatteryWarning method looking somewhat different from what i've seen on my S3. In order to try & let the patch work on more ROMs, the showLowBatteryWarning method is now being bypassed entirely. Hopefully, no ROM does anything important inside that method, besides showing the annoying low battery popups. In any case, as usual, you use the patch - you take the risk.
PS: For those willing and able to apply the patch manually, download the second zip and do a 3 way merge.
===> reserved <===
Nice mod...just added it to my rom.. purposely drained the battery...no notification pop up (hopefully won't get the temp warning anyway)
Lovely work
Already given 8 thanks today...I will come back!
_neutron_ said:
Nice mod...just added it to my rom.. purposely drained the battery...no notification pop up (hopefully won't get the temp warning anyway)
Lovely work
Already given 8 thanks today...I will come back!
Click to expand...
Click to collapse
Thanks. Temp warning should not be there any longer, too. But the rest of them (bad charger, overcurrent, stuff like that) are still there, i don't think killing those is a good idea.
The reason i did this was primarily the temperature warning. I've been looking all over the forum on how to disable it, but couldn't find any info, so i though, "what the hell, i can find it myself, it's not such a big deal"... during the search i've noticed the low bat one, too, and though "hmm, i hate that one too, lets kill it as well".
Thats about it.
Just patched and tested the full battery notification as well, first post updated.
Lovely, gonna test this when I get home
Thanks for the update
sorry to sound like a total noob, but im completely new to apktool. was reading up on it and trying it, but im slightly confused. what options do you chose exactly when decompiling? i couldnt find the power smali file after decompiling
There are plenty of explanations/tutorials on this around the forum. About not having the smali after decompiling... any chance your rom is odexed? In this case you wont be getting any smali files, cause all the code is in the odex file, not the apk. You will have to deodex it in this case and, possibly, reodex it before placing it back on the device (not sure about it, specifically i am unsure how the odex dependecies work).
Sadly, i cannot provide a ready to use apk, there are too many versions being in use, especially considering the 15 toggles mod, the battery icon mod as well as many other visual mods also patch stuff inside this apk, increasing the number of variations even further. So, sorry, no ready to use apk.
Is there a flashable file?
Sent from my GT-I9300 using Tapatalk 2
baste07 said:
Is there a flashable file?
Click to expand...
Click to collapse
Nope, and it is extremely hard to make. In fact, impossible, with the currently available CWM tools, as far as i know. It would be "for ROM version <insert_version_here> with 15 toggles and circle battery", "for ROM version <insert_version_here> without 15 toggles and green battery" etc etc etc kind of variations, and as i already mentioned, i doubt this is a viable option.
Anyone can prove me wrong and provide a way of writing a CWM script that would decompile (deodex if needed) an existing apk, apply a patch, recompile it and than replace it ? Out of all the things needed, i only know how to do the "replacing" part
Can i ask a massive favour?
im now havin problems with my systemui in regards to it recording the changes (decompiling & recompiling - i think i have an issue with my pc but i cant figure it out)
Could you apply the changes to the attached file for me?
InfX said:
There are plenty of explanations/tutorials on this around the forum. About not having the smali after decompiling... any chance your rom is odexed? In this case you wont be getting any smali files, cause all the code is in the odex file, not the apk. You will have to deodex it in this case and, possibly, reodex it before placing it back on the device (not sure about it, specifically i am unsure how the odex dependecies work).
Sadly, i cannot provide a ready to use apk, there are too many versions being in use, especially considering the 15 toggles mod, the battery icon mod as well as many other visual mods also patch stuff inside this apk, increasing the number of variations even further. So, sorry, no ready to use apk.
Click to expand...
Click to collapse
ah that explains why there is no smali file. thanks for the help!
I also cannot get this mod to work, wishing easier method coming soon, like one zip file thru recovery or similar... i dont have patience to this sorta things.
Sent from my GT-I9300 using xda app-developers app
_neutron_ said:
Can i ask a massive favour?
im now havin problems with my systemui in regards to it recording the changes (decompiling & recompiling - i think i have an issue with my pc but i cant figure it out)
Could you apply the changes to the attached file for me?
Click to expand...
Click to collapse
Done. Enjoy.
GalaxyS3man said:
I also cannot get this mod to work, wishing easier method coming soon, like one zip file thru recovery or similar... i dont have patience to this sorta things.
Sent from my GT-I9300 using xda app-developers app
Click to expand...
Click to collapse
Well, if you know of someone that could have possibly coded an infrastructure for doing this kind of patches onboard, automatically, i would be glad to get pointed to the right direction, and will integrate it there. Currently, i don't know of any.
Seriously, though... is it possible to baksmali in recovery mode somehow ? Can one run patch, sed and similar utilities there ? If yes, can i see an example ? Cause if that's possible, it can make a "flashable zip" for stuff like that possible.
hmm, so if i have these files in my app folder:
systemui.apk
systemui.odex
I cannot just add/replace the code as described?
reprazent said:
hmm, so if i have these files in my app folder:
systemui.apk
systemui.odex
I cannot just add/replace the code as described?
Click to expand...
Click to collapse
You can deodex, patch the smali while having it handy during deodexing, and, possibly, reodex it back into an odex file and replace just the odex. Never did it myself, though. I find odexed roms to be too much of a hassle while modding stuff to use those.
Is it ok if i ask help too?
InfX said:
You can deodex, patch the smali while having it handy during deodexing, and, possibly, reodex it back into an odex file and replace just the odex. Never did it myself, though. I find odexed roms to be too much of a hassle while modding stuff to use those.
Click to expand...
Click to collapse
I been trying for days...help, i go crazy with those popups
Thats what i have on my rooted S3 I just like Omega rom, tried several others non Samsung based aswell.
Sent from my GT-I9300 using xda app-developers app
GalaxyS3man, your apk is NOT odexed. Took me barely 2 minutes to apply the patch. Here we go...
PS: TBH, i've been under impression people on XDA are perfectly familiar applying and/or finding out this kind of stuff, really

Categories

Resources