[Q] CM11 HWA Settings FC - Defy Q&A, Help & Troubleshooting

Hi xda,
I've been reading the defy section for quite a while now, and love whats happening to the Defy! Thanks to everyone involved.
I have a problem with the HWA Settings, whenever I open them and whatever I do (scroll or uncheck an app), I get a forced closed notification. I am really running low on RAM and would love to disable HWA for a couple of apps, but am unable to do so.
Has anyone experienced a similar behaviour in the past and can recommend a procedure?
I am currently on 20140610, same problem occured to me with 20140518.
Thanks for all hints. If this is a yet unknown behaviour, I'll see if I can get any useful logs.
Cheers

Have you done a clean install means wiped data, cache and dalvik before install the new ROM? Because of I dont have such problems with the newest CM11 ROMs. At the other hand you could try to disable hwa for some apps with the terminal app. I can remember vaguely such a command exists but I dont know the precise writing anymore, sorry. Maybe someone with more profound knowledge can help you out.

Thank you for the hint.
Just in case anyone else is facing this issue and looking for a manual workaround, just create empty files inside /data/local/hwui.deny/ and fix the permissions (likely chown system:system and chmod 600).
e.g.
Code:
cd /data/local/hwui.deny/
touch com.android.browser
chmod 600 *
chown system:system *
My system has beed dirty flashed ever since I started using CM 10.2, I actually do not want to try a clean install now, for this minor issue.
The error that I see in logcat is:
Code:
D/AndroidRuntime( 8960): Shutting down VM
W/dalvikvm( 8960): threadid=1: thread exiting with uncaught exception (group=0x415a4ce0)
E/AndroidRuntime( 8960): FATAL EXCEPTION: main
E/AndroidRuntime( 8960): Process: com.cyanogenmod.settings.device.hwa, PID: 8960
E/AndroidRuntime( 8960): java.lang.ClassCastException: android.text.SpannableString cannot be cast to java.lang.String
E/AndroidRuntime( 8960): at com.cyanogenmod.settings.device.hwa.PackageListFragment.onItemClick(PackageListFragment.java:191)
E/AndroidRuntime( 8960): at android.widget.AdapterView.performItemClick(AdapterView.java:298)
E/AndroidRuntime( 8960): at android.widget.AbsListView.performItemClick(AbsListView.java:1113)
E/AndroidRuntime( 8960): at android.widget.AbsListView$PerformClick.run(AbsListView.java:2911)
E/AndroidRuntime( 8960): at android.widget.AbsListView$3.run(AbsListView.java:3645)
E/AndroidRuntime( 8960): at android.os.Handler.handleCallback(Handler.java:733)
E/AndroidRuntime( 8960): at android.os.Handler.dispatchMessage(Handler.java:95)
E/AndroidRuntime( 8960): at android.os.Looper.loop(Looper.java:136)
E/AndroidRuntime( 8960): at android.app.ActivityThread.main(ActivityThread.java:5161)
E/AndroidRuntime( 8960): at java.lang.reflect.Method.invokeNative(Native Method)
E/AndroidRuntime( 8960): at java.lang.reflect.Method.invoke(Method.java:515)
E/AndroidRuntime( 8960): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:795)
E/AndroidRuntime( 8960): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:611)
E/AndroidRuntime( 8960): at dalvik.system.NativeStart.main(Native Method)
W/ActivityManager( 1618): Force finishing activity com.cyanogenmod.settings.device.hwa/.HwaSettingsActivity
W/ActivityManager( 1618): Activity pause timeout for ActivityRecord{41fdfdc0 u0 com.cyanogenmod.settings.device.hwa/.HwaSettingsActivity t12 f}
I/Timeline( 1893): Timeline: Activity_idle id: [email protected] time:3048164
I/Timeline( 1618): Timeline: Activity_windows_visible id: ActivityRecord{4220a3d0 u0 com.teslacoilsw.launcher/com.android.launcher2.Launcher t1} time:3048618
I/Process ( 8960): Sending signal. PID: 8960 SIG: 9
I/ActivityManager( 1618): Process com.cyanogenmod.settings.device.hwa (pid 8960) has died.
I/WindowState( 1618): WIN DEATH: Window{421c25b0 u0 com.cyanogenmod.settings.device.hwa/com.cyanogenmod.settings.device.hwa.HwaSettingsActivity}
If it is just me, I'll leave it for now, if the problem arises for other users aswell, I'll try to find the upstream code and and hunt the issue down.

HWA Stopped Working
I've tried all sorts of things here.
I note that the folder hwui.deny to which madmuffin refers has no files at all.
I've deleted associated HWA Settings data via app settings.
This error persists in spite of my flashing a new ROM update today.:silly:

@gbossley The folder was empty on my side as well.
Since I manually created these files I havent used HWA Settings, but when I wanted to show the problem to a friend this weekend, HWA Settings worked flawless.

madmuffin said:
@gbossley The folder was empty on my side as well.
Since I manually created these files I havent used HWA Settings, but when I wanted to show the problem to a friend this weekend, HWA Settings worked flawless.
Click to expand...
Click to collapse
Could I trouble you for a file please - exactly as you've loaded into the folder? I'll PM you.

gbossley said:
Could I trouble you for a file please - exactly as you've loaded into the folder? I'll PM you.
Click to expand...
Click to collapse
The files are completely empty. If you use a Unix-like O/S like Linux, you can use the touch command on the prompt. Or you can just create an empty textfile using any method you like.
I did not upload the files from anywhere, I created them on the device.
Side note: I believe that it doesn't even matter. They might as well contain something. I believe the system only reads the list of files from that folder and processes that list. It won't check the contents or open the files.

Progress!
Thanks to Madmuffin, and a bit of tenacity (?), I see progress.
When looking at HWA Settings, under each app the file name to be managed is shown.
EG. for Aero Control, the file name will be com.aero.control
For ASR (a voice-recorder app) the file name is com.nll.asr
I used ROM Toolbox because with it you can use ROM Browser, navigate to the folder /data/local/hwui.deny/ and press New to create a new blank file with the appropriate names (as for Aero Control or ASR examples above).
So I created three blank files for three of the apps that I want to turn acceleration off for.
Now HWA shows those three files as deselected! However, it still stops working after either trying to turn them back on or turn others off.
So it looks as though I need to create a new blank file for every app that I want to turn off acceleration for.
My only question is "if the app is deselected per the above process, is acceleration actually turned off?" How could I test?

As Advised by Madmuffin, HWA Settings has started working! I'd love to know what logic goes on there...

HWA Not Working (Again)
I upgraded my ROM - TO Quarx CM11 (0607). HWA now not working again.
The HWUI.Deny folder has a heap of blank files in it.
Ideas?

gbossley said:
I upgraded my ROM - TO Quarx CM11 (0607). HWA now not working again.
Click to expand...
Click to collapse
Is the HWA Settings app not working or is hardware acceleration not disabled for the apps previously deselected?
gbossley said:
The HWUI.Deny folder has a heap of blank files in it.
Click to expand...
Click to collapse
What do you mean by "blank files"? The files in the folder are empty files by design and need no content.

madmuffin said:
Is the HWA Settings app not working or is hardware acceleration not disabled for the apps previously deselected?
What do you mean by "blank files"? The files in the folder are empty files by design and need no content.
Click to expand...
Click to collapse
Sorry, I could have been more specific.
The EMPTY files are there. If I try to make any changes "Unfortunately, Hwa Settings has stopped".

220
gbossley said:
Sorry, I could have been more specific.
The EMPTY files are there. If I try to make any changes "Unfortunately, Hwa Settings has stopped".
Click to expand...
Click to collapse
Well thats the previously observed behaviour of the HWA Settings App. I guess it will start to work after a while again, just like it did before. Since I do not need to make any changes, I usually don't even open up the app.
This seems to be a bug in HWA Settings App, but to be honest, I do not really care to much.

madmuffin said:
Code:
E/AndroidRuntime( 8960): Process: com.cyanogenmod.settings.device.hwa, PID: 8960
E/AndroidRuntime( 8960): java.lang.ClassCastException: android.text.SpannableString cannot be cast to java.lang.String
E/AndroidRuntime( 8960): at com.cyanogenmod.settings.device.hwa.PackageListFragment.onItemClick(PackageListFragment.java:191)
Click to expand...
Click to collapse
Hi,
when searching for this error message I found this:
http://stackoverflow.com/questions/11041973/why-cant-i-pass-data-via-intent
It was because getText() needs to have a 'toString()' at the end. Without this 'toString()', it will crash on Android 4.x, but will work on Android 2.x.
Click to expand...
Click to collapse
According to answer #4 this should help, the patch is _not_ compile-tested:
Code:
--- a/packages/apps/HwaSettings/src/com/cyanogenmod/settings/device/hwa/PackageListFragment.java 2014-05-25 14:34:36.115629433 +0200
+++ b/packages/apps/HwaSettings/src/com/cyanogenmod/settings/device/hwa/PackageListFragment.java 2014-07-21 18:44:53.271472949 +0200
@@ -189,7 +189,7 @@
.findViewById(R.id.hwa_settings_enabled);
boolean enableHwa = !hwaCheck.isChecked();
String packageName = (String) ((TextView) view
- .findViewById(R.id.hwa_settings_packagename)).getText();
+ .findViewById(R.id.hwa_settings_packagename)).getText().toString();
Intent service = new Intent(mContext, HwaSettingsService.class);
service.putExtra(PackageListProvider.PACKAGE_NAME, packageName);
service.putExtra(PackageListProvider.HWA_ENABLED, enableHwa);

sevenrock said:
Hi,
when searching for this error message I found this:
http://stackoverflow.com/questions/11041973/why-cant-i-pass-data-via-intent
According to answer #4 this should help, the patch is _not_ compile-tested:
Code:
--- a/packages/apps/HwaSettings/src/com/cyanogenmod/settings/device/hwa/PackageListFragment.java 2014-05-25 14:34:36.115629433 +0200
+++ b/packages/apps/HwaSettings/src/com/cyanogenmod/settings/device/hwa/PackageListFragment.java 2014-07-21 18:44:53.271472949 +0200
@@ -189,7 +189,7 @@
.findViewById(R.id.hwa_settings_enabled);
boolean enableHwa = !hwaCheck.isChecked();
String packageName = (String) ((TextView) view
- .findViewById(R.id.hwa_settings_packagename)).getText();
+ .findViewById(R.id.hwa_settings_packagename)).getText().toString();
Intent service = new Intent(mContext, HwaSettingsService.class);
service.putExtra(PackageListProvider.PACKAGE_NAME, packageName);
service.putExtra(PackageListProvider.HWA_ENABLED, enableHwa);
Click to expand...
Click to collapse
Sevenrock if you posted this to assist me in some way thanks. However, I'm an ignoramus! How do I use this information? I haven't the faintest clue!:silly:

Related

** FIXED ** Browser Force Closes Every Time

Using the default browser, on JF 1.5, every time I try to open it, I get:
"The application Browser (process com.android.browser) has stopped unexpectedly. Please try again."
This is still happening after numerous reboots. I haven't done anything since this morning when it was working. I don't know what would've changed.
Can I try reinstalling the apk? Or what should I try?
Did you perform a wipe when you installed the update? If not, try that first. If it still persists, then run the update again.
Sorry, guess I should've clarified. I've been running this build since the day it came out with no issues. Then today, out of the blue, it started happening.
I tried to install Browser.apk via apk installer and was told I couldn't install it. When I tried to install via ADB, I got "[INSTALL_FAILED_ALREADY_EXISTS]"
you would have to remove it before reinstalling.... try doing logcat to see why it force crashes. just connect your phone to your computer run adb logcat then on your phone start the browser. when it crashes you should see some type of exception, see what it is complaining about.
If you have your data on sdcard then you could have a stale nfs file handle and you need to get rid of it by mounting your phone in linux and emptying your data directory. When you reboot after that your phone will redo the build the data. Just dont delete the directory. You can just make a new file on the same partition and move the contents of your data directory to the new file. The phone wont look for data in random places so that works.
Just verify this before you do it. I could be wrong. Just a guess.
I have never ran a logcat, but I think I did it correctly.
stogchris81, yes I have apps on SD.
I/ActivityManager( 61): Starting activity: Intent { action=android.intent.acti
on.MAIN categories={android.intent.category.LAUNCHER} data=#Intent;action=#Inten
t;action=#Intent;action=#Intent;action= flags=0x10000000 comp={com.android.brows
er/com.android.browser.BrowserActivity} }
I/ActivityManager( 61): Start proc com.android.browser for activity com.androi
d.browser/.BrowserActivity: pid=887 uid=10026 gids={3003}
D/dalvikvm( 61): GC freed 8835 objects / 452416 bytes in 242ms
I/ActivityThread( 887): Publishing provider browser: com.android.browser.Browse
rProvider
I/ActivityManager( 61): Displayed activity com.android.browser/.BrowserActivit
y: 1561 ms
E/Database( 887): Failure 14 (unable to open database file) on 0x19e9b8 when ex
ecuting 'BEGIN EXCLUSIVE;'
W/dalvikvm( 887): threadid=19: thread exiting with uncaught exception (group=0x
4000fe70)
E/AndroidRuntime( 887): Uncaught handler: thread WebViewCoreThread exiting due
to uncaught exception
E/AndroidRuntime( 887): android.database.sqlite.SQLiteException: unable to open
database file: BEGIN EXCLUSIVE;
E/AndroidRuntime( 887): at android.database.sqlite.SQLiteDatabase.native
_execSQL(Native Method)
E/AndroidRuntime( 887): at android.database.sqlite.SQLiteDatabase.execSQ
L(SQLiteDatabase.java:1496)
E/AndroidRuntime( 887): at android.database.sqlite.SQLiteDatabase.beginT
ransaction(SQLiteDatabase.java:413)
E/AndroidRuntime( 887): at android.webkit.WebViewDatabase.startCacheTran
saction(WebViewDatabase.java:510)
E/AndroidRuntime( 887): at android.webkit.CacheManager.enableTransaction
(CacheManager.java:231)
E/AndroidRuntime( 887): at android.webkit.WebViewCore$EventHub$1.handleM
essage(WebViewCore.java:776)
E/AndroidRuntime( 887): at android.os.Handler.dispatchMessage(Handler.ja
va:99)
E/AndroidRuntime( 887): at android.os.Looper.loop(Looper.java:123)
E/AndroidRuntime( 887): at android.webkit.WebViewCore$WebCoreThread.run(
WebViewCore.java:462)
E/AndroidRuntime( 887): at java.lang.Thread.run(Thread.java:1058)
I/Process ( 61): Sending signal. PID: 887 SIG: 3
I/dalvikvm( 887): threadid=7: reacting to signal 3
I/dalvikvm( 887): Wrote stack trace to '/data/anr/traces.txt'
I/DumpStateReceiver( 61): Added state dump to 1 crashes
D/dalvikvm( 426): GC freed 391 objects / 21904 bytes in 167ms
seems like your database file for the browser is corrupted. did you put your /data/data on sd? you should be able to delete it and reboot it should recreate. it should be in /data/data/com.android.browser. try to rename it first just in case... you will lose all your bookmarks though... but I think it's already corrupted so you probably lost it already.
adb shell mv /data/data/com.android.browser /data/data/com.android.browser.OLD
adb shell mkdir /data/data/com.android.browser
adb shell reboot
Ran the first line and got this:
failed on '/data/data/com/android.browser' - No such file or directory
you didn't copy the line correctly.
Well that would make things a little difficult wouldn't it.
Everything seems to be back in working order. Lost all my bookmarks and everything, but at least it's working!
Thank you very VERY much! I really do appreciate it. Is there anything else I need to do now? Now that I have the com.android.browser.old?
if things are working and you don't mind losing those bookmarks you can remove the .old. just do
adb shell rm -r /data/data/com.android.browser.OLD
I don't see any reason not to do it. The bookmarks are toast right? I can't recover them at all?
probably, if you really want to try to recover you can try to recover them. But its complicated, I haven't tried so I can't give you any instructions how you.
Cool, I'll just remove them. Thanks again!
did you happen to try going into application manager and clearing the browser data? i get this issue a lot, and thats real easy to do. you lose your bookmarks, but i regularly back them up with apps that you can get from the market.
That would have been a good thing to try as well. I didn't think of that.
Browser problem
Guys, I have a bit of a strange problem.. i am using JF1.5 but my browser is not working... by that i mean it opens without a problem and shows the homepage ( www.google.com ) in a second but when i open anyother address it just says " web page not available- check your internet connection " but the strange thing is that when i open a link there is no network activity as if the browser aint even trying to connect to the network ....
Now i have installed opera mini and thats working just fine .... i.e opens every page quickly ....
Any Idea whats the problem ?
Thanks

Unable to delete files or format internal sd

Hello,
I am not able to delete any file(photos/videos/apps) from my phone all deleted files reaper when i reboot the phone.
I have try hard reset and wipe everything, format the internal sd with my computer, format the sd with the phone neither of those method works, all deleted files come back when i reboot my phone. for example
1) facebook apps is installed on the phone and is working properly
2) facebook apps is removed from the phone and is removed as expected
3) reboot the phone / hard reset the phone / wipe everything
4) facebook apps is back on the phone
this applies to photos taken by me, mp3, etc...
what could be wrong?
my phone is a sgs gt-i9000 non rooted
thanks
i have the same problem didn't find a solution but i think it has something to do with the internal sd card.. tried formating from windows, from the phone and from recovery mode but all my files are still there
it is very frustrating not able to delete any file. i hope there is a solution to this problem because i can not return this phone.
I also have this problem. Trying to find sollution reading the other forums also. Now i will try the following sollution.
alexanderzxy said:
I have a bell i9000m and it's internal SD was broken though flashing a bell 2.2 rom by Odin. I flashed it by many roms and many times,nothing change. What I did that get the internal SD back is wait a day(get battery out) and then flash a full rom. What I mean is that select Re-partition,make sure pit file、PDA、Phone and CSC are in the proper place,then hit start. Hopefully it could work. I'm not sure but I use this method get my Internal SD back twice.Regardless for my "Chinglish".
Click to expand...
Click to collapse
http://forum.cyanogenmod.com/topic/21066-damaged-internal-sd-galaxy-s-i9000-mount-not-work/
Please if you find any sollution, please inform us also.
solution not found. this is worst of a bricked phone.
i tried the method i wrote. did not work
very frustrating.
I don't understand how could it be that the memory is permanently save?
it makes no sense to me.
Image if the phone has a virus/adware/etc... and it could not be deleted even with a factory reset and you have to throw away your phone. very serious bug or hardware issue.
btw i not an android hacker i used my just to make phone calls, check email, chat... i mean i did not break my phone.
The flash memory is dead or the flash controller ...
"Another limitation is that flash memory has a finite number of program-erase cycles (typically written as P/E cycles). Most commercially available flash products are guaranteed to withstand around 100,000 P/E cycles, before the wear begins to deteriorate the integrity of the storage.
After that you can only read the contents of the flash drive
A defective memory chip can have a lower P/E cycles.
thanks.
I will not do it myself but Is it possible to physically change the flash memory/the controller?
do you think the phone dead forever?
update:
when i turn on my phone i see this error message using 'adb logcat'
Code:
D/dalvikvm( 662): DexOpt: incorrect opt magic number (0xb8 da 1f 00)
W/dalvikvm( 662): Cached DEX '/data/app/com.skype.raider-1.apk' (/data/dalvik-cache/[email protected]@[email protected]) is stale and not writable
I/dalvikvm( 662): Unable to open or create cache for /data/app/com.skype.raider-1.apk (/data/dalvik-cache/[email protected]@[email protected])
D/AndroidRuntime( 662): Shutting down VM
W/dalvikvm( 662): threadid=1: thread exiting with uncaught exception (group=0x40015578)
E/AndroidRuntime( 662): FATAL EXCEPTION: main
E/AndroidRuntime( 662): java.lang.RuntimeException: Unable to instantiate application com.skype.raider.SkypeApplication: java.lang.ClassNotFoundException: com.skype.raider.SkypeApplication in loader dalvik.system.PathClassLoader[/data/app/com.skype.raider-1.apk]
E/AndroidRuntime( 662): at android.app.LoadedApk.makeApplication(LoadedApk.java:466)
E/AndroidRuntime( 662): at android.app.ActivityThread.handleBindApplication(ActivityThread.java:3264)
E/AndroidRuntime( 662): at android.app.ActivityThread.access$2200(ActivityThread.java:117)
E/AndroidRuntime( 662): at android.app.ActivityThread$H.handleMessage(ActivityThread.java:973)
E/AndroidRuntime( 662): at android.os.Handler.dispatchMessage(Handler.java:99)
E/AndroidRuntime( 662): at android.os.Looper.loop(Looper.java:123)
E/AndroidRuntime( 662): at android.app.ActivityThread.main(ActivityThread.java:3687)
E/AndroidRuntime( 662): at java.lang.reflect.Method.invokeNative(Native Method)
E/AndroidRuntime( 662): at java.lang.reflect.Method.invoke(Method.java:507)
E/AndroidRuntime( 662): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:842)
E/AndroidRuntime( 662): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:600)
E/AndroidRuntime( 662): at dalvik.system.NativeStart.main(Native Method)
E/AndroidRuntime( 662): Caused by: java.lang.ClassNotFoundException: com.skype.raider.SkypeApplication in loader dalvik.system.PathClassLoader[/data/app/com.skype.raider-1.apk]
E/AndroidRuntime( 662): at dalvik.system.PathClassLoader.findClass(PathClassLoader.java:240)
E/AndroidRuntime( 662): at java.lang.ClassLoader.loadClass(ClassLoader.java:551)
E/AndroidRuntime( 662): at java.lang.ClassLoader.loadClass(ClassLoader.java:511)
E/AndroidRuntime( 662): at android.app.Instrumentation.newApplication(Instrumentation.java:942)
E/AndroidRuntime( 662): at android.app.LoadedApk.makeApplication(LoadedApk.java:461)
E/AndroidRuntime( 662): ... 11 more
I/ActivityManager( 129): Start proc com.google.android.googlequicksearchbox for broadcast com.google.android.googlequicksearchbox/.SearchWidgetProvider: pid=691 uid=10036 gids={3003}
E/ ( 129): Dumpstate > /data/log/dumpstate_app_error
this line is interesting:
W/dalvikvm( 662): Cached DEX '/data/app/com.skype.raider-1.apk' (/data/dalvik-cache/[email protected]@[email protected]) is stale and not writable
Skype is an application that suppose to be deleted.
any help? what does 'Cached DEX' is stale and not writable means? (not literatly)
thanks
Everything is possible with proper tools ... If you know someone who can find and buy the flash chip and controller, yes! ... The rest of the process is relatively simple ...
ok thanks
i guest the phone is broken unless there is a way to mount the file system on the external sd card and ignore the internal sd card.
update:
problem seems to be located on:
/dev/block/mmcblk0
/dev/block/mmcblk0p1
/dev/block/mmcblk0p2
is there any way to point block devices file to the external memory card?
help please.
thanks
send in for repair replacement.
found any fix?
Hello,
not yet but I think the phone problem can be fixed by running android from the external sd. My knowledge of the Android OS is not good enough to make this change.
Question for the experts:
Is there anyway to run Android from the external sd card?
Is possible?
Thanks
ps. i cannot return the phone for repair/replacement.
Everything is possible ... But i don't think someone is going to make a port or something for this problem ...
Try to find the flash controller and the flash chip, and put someone to desolder the dead ones, and solder back the good ones. The last part is simple.
I think the only thing to be done is to mount /data on the external sd
Yes, that could be a possibility too ... But try to find a dead android phone that still has the flash memory and controller in good working condition, and then find someone who has the skill required to solder microchips from one phone to the other ...
I don't think sd mounting will be released soon, because the external sd is seen only as a folder in the internal storage
Hello,
Are you saying that i can take any flash chip and controller and install it on the Samsung galaxy s?
I have an old htc magic, do you think the flash chip and controller are compatible?
thanks for replying.

LogCat - findLibrary returned null, how to debug?

Hello,
I have some applicationa that crashes. I know why it crashes:
Code:
E/AndroidRuntime( 6271): FATAL EXCEPTION: main
E/AndroidRuntime( 6271): java.lang.UnsatisfiedLinkError: Couldn't load jni_hw_mosaic from loader dalvik.system.PathClassLoader[DexPathList[dexElements=[zip file "/system/framework/com.google.android.media.effects.jar", zip file "/system/app/Camera.apk"],nativeLibraryDirectories=[/vendor/lib, /system/lib]]]: findLibrary returned null
Of course, some native library not found. But I can't see most interesting thing - which library is missing. Is there any way to determine what library I need? Any debug, logcat or anything else?

[Q] Cherry-Picking help

I want to cherry-pick "custom notification led settings" from purity to my aosp build.
So I went ahead and picked up these two commits
https://github.com/KitKatPurity/pla...mmit/c85834ed460ec99e0752f1f13e58cad74abf844e
and
https://github.com/KitKatPurity/pla...mmit/b37fdf4238b11b0232b12f218294131ea77ec309
The framework part ran well and there was no conflict. The settings part returned a small conflict which I solved myself. Now as I go on compiling, everything compiled good but then at the time of Settings.apk compiling it returned this error.
Code:
packages/apps/Settings/src/com/android/settings/DisplaySettings.java:119: cannot find symbol
symbol : variable mDisplayManager
location: class com.android.settings.DisplaySettings
mDisplayManager = (DisplayManager)getActivity().getSystemService(
^
packages/apps/Settings/src/com/android/settings/DisplaySettings.java:119: cannot find symbol
symbol : class DisplayManager
location: class com.android.settings.DisplaySettings
mDisplayManager = (DisplayManager)getActivity().getSystemService(
^
packages/apps/Settings/src/com/android/settings/DisplaySettings.java:121: cannot find symbol
symbol : variable mWifiDisplayStatus
location: class com.android.settings.DisplaySettings
mWifiDisplayStatus = mDisplayManager.getWifiDisplayStatus();
^
packages/apps/Settings/src/com/android/settings/DisplaySettings.java:121: cannot find symbol
symbol : variable mDisplayManager
location: class com.android.settings.DisplaySettings
mWifiDisplayStatus = mDisplayManager.getWifiDisplayStatus();
^
packages/apps/Settings/src/com/android/settings/DisplaySettings.java:122: cannot find symbol
symbol : variable mWifiDisplayPreference
location: class com.android.settings.DisplaySettings
mWifiDisplayPreference = (Preference)findPreference(KEY_WIFI_DISPLAY);
^
packages/apps/Settings/src/com/android/settings/DisplaySettings.java:122: cannot find symbol
symbol : variable KEY_WIFI_DISPLAY
location: class com.android.settings.DisplaySettings
mWifiDisplayPreference = (Preference)findPreference(KEY_WIFI_DISPLAY);
^
packages/apps/Settings/src/com/android/settings/DisplaySettings.java:123: cannot find symbol
symbol : variable mWifiDisplayStatus
location: class com.android.settings.DisplaySettings
if (mWifiDisplayStatus.getFeatureState()
^
packages/apps/Settings/src/com/android/settings/DisplaySettings.java:124: cannot find symbol
symbol : variable WifiDisplayStatus
location: class com.android.settings.DisplaySettings
== WifiDisplayStatus.FEATURE_STATE_UNAVAILABLE) {
^
packages/apps/Settings/src/com/android/settings/DisplaySettings.java:125: cannot find symbol
symbol : variable mWifiDisplayPreference
location: class com.android.settings.DisplaySettings
getPreferenceScreen().removePreference(mWifiDisplayPreference);
^
packages/apps/Settings/src/com/android/settings/DisplaySettings.java:126: cannot find symbol
symbol : variable mWifiDisplayPreference
location: class com.android.settings.DisplaySettings
mWifiDisplayPreference = null;
^
packages/apps/Settings/src/com/android/settings/purity/notificationlight/ApplicationLightPreference.java:170: method does not override or implement a method from a supertype
@Override
^
Note: Some input files use or override a deprecated API.
Note: Recompile with -Xlint:deprecation for details.
Note: Some input files use unchecked or unsafe operations.
Note: Recompile with -Xlint:unchecked for details.
11 errors
make: *** [out/target/common/obj/APPS/Settings_intermediates/classes-full-debug.jar] Error 41
make: *** Waiting for unfinished jobs....
Here are the link of the 2 files where the error is shown:
ApplicationLightPreference.java
DisplaySettings.java
I tried the following combination to solve it:
in ApplicationLightPreference.java, I deleted the line which returned the error.
in DisplaySettings.java I deleted the line which returned the error.
The build compiles fine, boot fines but but when I select display settings, it force closes.
Any help in solving this error is appreciated.
Since this is a question why not post in the section clearly marked for questions??
Sent from my Nexus 4 using xda premium
brajesh.sharma87 said:
I tried the following combination to solve it:
in ApplicationLightPreference.java, I deleted the line which returned the error.
in DisplaySettings.java I deleted the line which returned the error.
The build compiles fine, boot fines but but when I select display settings, it force closes.
Any help in solving this error is appreciated.
Click to expand...
Click to collapse
Find the commit that added the missing variable(s) and method(s)
pull a log for the force close.
MBQ_ said:
Find the commit that added the missing variable(s) and method(s)
pull a log for the force close.
Click to expand...
Click to collapse
Not sure what to do about the first line but here's the log
Code:
I/ActivityManager( 647): Displayed com.android.settings/.Settings: +631ms
I/ActivityManager( 647): START u0 {act=android.intent.action.MAIN cmp=com.android.settings/.SubSettings (has extras)} from pid 9823
D/audio_hw_primary( 170): select_devices: out_snd_device(2: speaker) in_snd_device(0: )
D/ACDB-LOADER( 170): ACDB -> send_afe_cal
D/SubSettings( 9823): Launching fragment com.android.settings.DisplaySettings
D/AndroidRuntime( 9823): Shutting down VM
W/dalvikvm( 9823): threadid=1: thread exiting with uncaught exception (group=0x415adba8)
E/AndroidRuntime( 9823): FATAL EXCEPTION: main
E/AndroidRuntime( 9823): Process: com.android.settings, PID: 9823
E/AndroidRuntime( 9823): java.lang.RuntimeException: Unable to start activity ComponentInfo{com.android.settings/com.android.settings.SubSettings}: java.lang.NullPointerException
E/AndroidRuntime( 9823): at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2195)
E/AndroidRuntime( 9823): at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2245)
E/AndroidRuntime( 9823): at android.app.ActivityThread.access$800(ActivityThread.java:135)
E/AndroidRuntime( 9823): at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1196)
E/AndroidRuntime( 9823): at android.os.Handler.dispatchMessage(Handler.java:102)
E/AndroidRuntime( 9823): at android.os.Looper.loop(Looper.java:136)
E/AndroidRuntime( 9823): at android.app.ActivityThread.main(ActivityThread.java:5017)
E/AndroidRuntime( 9823): at java.lang.reflect.Method.invokeNative(Native Method)
E/AndroidRuntime( 9823): at java.lang.reflect.Method.invoke(Method.java:515)
E/AndroidRuntime( 9823): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:779)
E/AndroidRuntime( 9823): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:595)
E/AndroidRuntime( 9823): at dalvik.system.NativeStart.main(Native Method)
E/AndroidRuntime( 9823): Caused by: java.lang.NullPointerException
E/AndroidRuntime( 9823): at com.android.settings.DisplaySettings.onCreate(DisplaySettings.java:134)
E/AndroidRuntime( 9823): at android.app.Fragment.performCreate(Fragment.java:1678)
E/AndroidRuntime( 9823): at android.app.FragmentManagerImpl.moveToState(FragmentManager.java:859)
E/AndroidRuntime( 9823): at android.app.FragmentManagerImpl.moveToState(FragmentManager.java:1062)
E/AndroidRuntime( 9823): at android.app.BackStackRecord.run(BackStackRecord.java:684)
E/AndroidRuntime( 9823): at android.app.FragmentManagerImpl.execPendingActions(FragmentManager.java:1447)
E/AndroidRuntime( 9823): at android.app.Activity.performStart(Activity.java:5240)
E/AndroidRuntime( 9823): at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2168)
E/AndroidRuntime( 9823): ... 11 more
W/ActivityManager( 647): Force finishing activity com.android.settings/.SubSettings
W/ActivityManager( 647): Force finishing activity com.android.settings/.Settings
W/ActivityManager( 647): Activity pause timeout for ActivityRecord{41e72210 u0 com.android.settings/.SubSettings t14 f}
W/Sidekick_LocationOracleImpl( 2543): Best location was null
I/Process ( 9823): Sending signal. PID: 9823 SIG: 9
V/SearchControllerCache( 2543): creating SearchController
W/Sidekick_LocationOracleImpl( 2543): Best location was null
W/GCoreFlp( 8127): No location to return for getLastLocation()
I/ActivityManager( 647): Process com.android.settings (pid 9823) has died.
I/WindowState( 647): WIN DEATH: Window{419b9318 u0 com.android.settings/com.android.settings.Settings}
D/dalvikvm( 2543): GC_FOR_ALLOC freed 1110K, 57% free 5133K/11704K, paused 27ms, total 27ms
I/MicroHotwordRecognitionRunner( 2543): Starting hotword detection.
D/audio_hw_primary( 170): select_devices: out_snd_device(0: ) in_snd_device(34: voice-rec-mic)
E/ACDB-LOADER( 170): Error: ACDB AudProc vol returned = -8
D/dalvikvm( 2543): GC_CONCURRENT freed 6K, 51% free 5756K/11704K, paused 2ms+3ms, total 32ms
I/SearchController( 2543): #onHotwordDetectorStarted
brajesh.sharma87 said:
Not sure what to do about the first line but here's the log
Click to expand...
Click to collapse
Something is wrong in the onCreate method of DisplaySettings.java
Hi, I checked and you miss the declaration in the Android Manifest in the packages_apps_settings. Go and check my Github commits. You do not need the modifcation in the proguard.flags though.
https://github.com/GeyerA/platform_...mmit/347e74714f0c6efa2dbd3ba49b5612e1cc11bf4f
For completeness also check the commits in the frameworks_base
https://github.com/GeyerA/platform_frameworks_base/commit/a77810164cb1bcb1d449f603f31a97939d9f9b3b
Also, make sure you got these...
https://github.com/PSX-PureSpeed/an...mmit/3e29b10a377f0985ee221aaa4fe10838733ed3df
https://github.com/PSX-PureSpeed/an...mmit/2ae7fbb6134f6831fba8184d0dd1092f5bee1f7a
This should fix your issues, just let me know or PM me as I am not always checking on your thread.
Nice week to everbody. Calo
GeyerA said:
Hi, I checked and you miss the declaration in the Android Manifest in the packages_apps_settings. Go and check my Github commits. You do not need the modifcation in the proguard.flags though.
https://github.com/GeyerA/platform_...mmit/347e74714f0c6efa2dbd3ba49b5612e1cc11bf4f
For completeness also check the commits in the frameworks_base
https://github.com/GeyerA/platform_frameworks_base/commit/a77810164cb1bcb1d449f603f31a97939d9f9b3b
Also, make sure you got these...
https://github.com/PSX-PureSpeed/an...mmit/3e29b10a377f0985ee221aaa4fe10838733ed3df
https://github.com/PSX-PureSpeed/an...mmit/2ae7fbb6134f6831fba8184d0dd1092f5bee1f7a
This should fix your issues, just let me know or PM me as I am not always checking on your thread.
Nice week to everbody. Calo
Click to expand...
Click to collapse
Thanks for the answer. I discarded all the commits which I took from purity.
Started fresh and picked up the commits from your github. There was 1 conflict in DisplaySettings.java, I solved it and compiled. It then gave me error during compile about volume wake. I deleted those lines in question and compiled again. It compiled fine but after installing the output rom I still got FC when clicking on "Display Settings".
I didn't give up. I discarded all the previous commits again and this time picked up the volume wake commits first and then the LED customization commits and then from PSX commits which you advised. Everything ran well, there was not a single conflict this time. Even there was no error at the time of compilation. BUT as always on installing the rom I got the same FC on clicking Display settings.
Now I have deleted the entire out directory and this time will build fresh lets see if that can help, but for that I can only do it after 8-10 days as I am going out of station.
Thanks for all the help.
brajesh.sharma87 said:
Thanks for the answer. I discarded all the commits which I took from purity.
Started fresh and picked up the commits from your github. There was 1 conflict in DisplaySettings.java, I solved it and compiled. It then gave me error during compile about volume wake. I deleted those lines in question and compiled again. It compiled fine but after installing the output rom I still got FC when clicking on "Display Settings".
I didn't give up. I discarded all the previous commits again and this time picked up the volume wake commits first and then the LED customization commits and then from PSX commits which you advised. Everything ran well, there was not a single conflict this time. Even there was no error at the time of compilation. BUT as always on installing the rom I got the same FC on clicking Display settings.
Now I have deleted the entire out directory and this time will build fresh lets see if that can help, but for that I can only do it after 8-10 days as I am going out of station.
Thanks for all the help.
Click to expand...
Click to collapse
Hello, good that you have some progress although you might feel disappointed that it does not work. Here is one reason why I personally do not cherry-pick complex commits as it will also add the lines which are not part of that commit but part of my code.
Anyhow, I believe you missed one small thing which is in android_device_hammerhead. Sorry I forgot that one.
https://github.com/KitKatPurity/pla...mmit/217378d3e6a7a5370e7c1583fcfb4ae1e7a9ac7c
Especially this one in overlay/frameworks/base/core/res/res/values/config.xml
Code:
+ <!-- Is the battery LED intrusive? Used to decide if there should be a disable option -->
+ <bool name="config_intrusiveBatteryLed">true</bool>
+
+ <!-- Does the battery LED support multiple colors? Used to decide if the user can change the colors -->
+ <bool name="config_multiColorBatteryLed">true</bool>
+
I am sure it will work then. Please do not delete everything again when something does not work, post the question first :silly:
GeyerA said:
........I am sure it will work then. Please do not delete everything again when something does not work, post the question first :silly:
Click to expand...
Click to collapse
Thanks but as i said, i wont have access to my laptop for next 8-10 days, will continue once i come back.
Sent from my Nexus 4 using Tapatalk
@GeyerA you're a genius. I've been working on this for last 1 month and finally succeeded.
As I didnt have access to my laptop and the resolution that u you gave was also possible through apk tool, I sent the framework-res.apk to a friend and asked him to just change those two values to 'true' he did so and sent the same to me and boom it worked. Thank you so very much.
Sent from my Nexus 4 using Tapatalk
Hello. I am happy to hear; great satisfaction that I could help. But the credit is Dario's from Kitkatpurity and Martin_Ro's from PSX. They helped me a lot and I suffered much more than you. No biggie but please use the thanks button ....
Sent from my AOSP on HammerHead using xda app-developers app

[APP] chrulri's DroidTV mod [changed stream backend to MuMuDVB]

Hi!
I changed chrulri's DroidTV DVB viewer application to my needs:
1. Changed dvb stream backend from dvblast to MuMuDVB (changed udp unicast to http unicast)
2. Did not try anymore to play the channel on app, now you can choose the video player (no codec problems, Brazilian ISDB-T latm-aac/AVC support)
3. Reception status information displayed
4. Notification to rapidly stop the stream server.
What you need to run:
1. Rooted phone
2. DVB-T (ISDB-T) kernel module drivers (loaded!).
How:
1. Plug your dvb device (with a otg cable)
2. Run the program
3. Grant root access
4. Scan for channels
5. Select a channel to stream
6. Touch on "open player"
7. Select the player to use (I like bsplayer)
8. Enjoy live FTA DTV
*** All thanks to chrulri!!!
Source: https://github.com/OuNao/droidtv/tree/mumudvb
getting FC with this apk:
D/ChannelsActivity( 3136): watchChannel(0): BBC ONE Lon
I/Timeline( 3136): Timeline: Activity_launch_request id:com.chrulri.droidtv time:23860947
I/ActivityManager( 2588): START u0 {cmp=com.chrulri.droidtv/.StreamActivity (has extras)} from pid 3136
E/dalvikvm( 3136): Could not find class 'android.support.v4.app.NotificationCompat$Builder', referenced from method com.chrulri.droidtv.StreamActivity.addNotification
W/dalvikvm( 3136): VFY: unable to resolve new-instance 24 (Landroid/support/v4/app/NotificationCompat$Builder in Lcom/chrulri/droidtv/StreamActivity;
D/dalvikvm( 3136): VFY: replacing opcode 0x22 at 0x0000
D/dalvikvm( 3136): DexOpt: unable to opt direct call 0x0020 at 0x02 in Lcom/chrulri/droidtv/StreamActivity;.addNotification
D/StreamActivity( 3136): onCreate
D/AndroidRuntime( 3136): Shutting down VM
W/dalvikvm( 3136): threadid=1: thread exiting with uncaught exception (group=0x416d2ce0)
E/AndroidRuntime( 3136): FATAL EXCEPTION: main
E/AndroidRuntime( 3136): Process: com.chrulri.droidtv, PID: 3136
E/AndroidRuntime( 3136): java.lang.NoClassDefFoundError: android.support.v4.app.NotificationCompat$Builder
E/AndroidRuntime( 3136): at com.chrulri.droidtv.StreamActivity.addNotification(StreamActivity.java:212)
E/AndroidRuntime( 3136): at com.chrulri.droidtv.StreamActivity.onCreate(StreamActivity.java:94)
E/AndroidRuntime( 3136): at android.app.Activity.performCreate(Activity.java:5231)
E/AndroidRuntime( 3136): at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1087)
E/AndroidRuntime( 3136): at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2169)
E/AndroidRuntime( 3136): at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2271)
E/AndroidRuntime( 3136): at android.app.ActivityThread.access$800(ActivityThread.java:144)
E/AndroidRuntime( 3136): at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1205)
E/AndroidRuntime( 3136): at android.os.Handler.dispatchMessage(Handler.java:102)
E/AndroidRuntime( 3136): at android.os.Looper.loop(Looper.java:136)
E/AndroidRuntime( 3136): at android.app.ActivityThread.main(ActivityThread.java:5146)
E/AndroidRuntime( 3136): at java.lang.reflect.Method.invokeNative(Native Method)
E/AndroidRuntime( 3136): at java.lang.reflect.Method.invoke(Method.java:515)
E/AndroidRuntime( 3136): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:796)
E/AndroidRuntime( 3136): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:612)
E/AndroidRuntime( 3136): at dalvik.system.NativeStart.main(Native Method)
W/ActivityManager( 2588): Force finishing activity com.chrulri.droidtv/.StreamActivity
W/ActivityManager( 2588): Force finishing activity com.chrulri.droidtv/.ChannelsActivity
according to http://igordcard.blogspot.co.uk/2013/05/android-latest-sdk-javalangclassnotfoun.html To fix this, developers must now explicitly export the Android Private Libraries.
Fix:
Open the properties of your Android projects (even the ones that are included by other projects), select Java Build Path, Order and Export, and finally check Android Private Libraries.
I am new to android development, I have android studio though, is the above correct and easy to do?
well to answer my own post, I fixed that problem and rebuilt the apk, vlc and mxplayer are offered as media players when the stream starts by neither can play it. I have bsplayer installed but that is not offered as an option for some reason. I believe that dvb-t in the uk is mpeg2, so either none of the players can play the stream or the kernel modules that I built are streaming garbage. the dongle works find on my linux laptop with me-tv.
going to try some other players now, not sure how to check a valid stream is being produced though.
Could you please share your repaired apk? thank you
scote said:
well to answer my own post, I fixed that problem and rebuilt the apk, vlc and mxplayer are offered as media players when the stream starts by neither can play it. I have bsplayer installed but that is not offered as an option for some reason. I believe that dvb-t in the uk is mpeg2, so either none of the players can play the stream or the kernel modules that I built are streaming garbage. the dongle works find on my linux laptop with me-tv.
going to try some other players now, not sure how to check a valid stream is being produced though.
Click to expand...
Click to collapse
Thank you for the tip. I will change de code.
The streamActivity initiate a intent with a url of type video/mpeg, any program with intent filter set to get a http (mumudvb branch, not master!!!) url of video/mpeg type must be offered...
What kernel version you are using. I compiled the mumudvb binary with kernel 3.4 headers. Maybe the mumudvb backend used can´t work with your kernel modules...
sfortier, could you rebuild all native binaries adding to CFLAGS and LDFLAGS "-fPIE -pie", so your setup would run on any Android 5+?
I already did that for w_scan, dvblast and dvblastctl, but since you did not include instructions how to download and build MuMuDVB for android I can not do it myself.
Thanks in advance.
t_i_t_o said:
sfortier, could you rebuild all native binaries adding to CFLAGS and LDFLAGS "-fPIE -pie", so your setup would run on any Android 5+?
I already did that for w_scan, dvblast and dvblastctl, but since you did not include instructions how to download and build MuMuDVB for android I can not do it myself.
Thanks in advance.
Click to expand...
Click to collapse
Hi,
MuMuDVB repository now has instructions to build for android...
Hi,
Seeing as the version w_scan is not available to download, could someone recompile this with the latest version and create an APK?
Especially to run on a 5+ Android phone, with PIE.
Thanks,
E

Categories

Resources