yashsingh1/xdaforums huggingface dataset:
[Moto G Q&A, Help & Troubleshooting] homalex:
I know about the ebay unlock codes and the previously used them (with another phone). To use this code it is necessary to insert another SIM card and the phone asks for the code.

But my phone is not responding at all to SIM. when I go "settings > wireless networks > more > mobile networks" then page "mobile networks" at all not active at any SIM card. I can not make any changes to it.

I checked the IMEI number on several sites and it is not listed anywhere in the black list.
[Moto G Q&A, Help & Troubleshooting] hacktrix2006:
This is strange indeed. Does the device look liked it tampered with at all I.e the screws look like they have unscrewed?

Was you sim a micro sim to begin with or was it trimmed.
[Moto G Q&A, Help & Troubleshooting] lost101:
[MENTION=6890998]homalex[/MENTION] - I think you should try fastboot flashing one of the Firmware Images again. Provide a log (copy and paste) of what happens when you type out the fastboot commands manually.

Fastboot is not user-friendly - it can totally fail and at the same time make everything look like an amazing success.
[Moto G Q&A, Help & Troubleshooting] homalex:
Now I look attentively - there is no trace that phone disassembled. Even a fake he did not like.

It was micro SIM, not trimmed.
[Moto G Q&A, Help & Troubleshooting] hacktrix2006:
OK so that leaves the simcard was its micro sim or a standard sim trimmed to a micro sim?
[Moto G Q&A, Help & Troubleshooting] homalex:
firmware is installed well, without errors. but after each firmware in baseband version and system version added at the end O2 GB.

such as I have now after installation tesco filmware:

baseband version M8926_309101.02.03.14R O2GB_CUST

system version 23.12.17.peregrine_tescogb.tescogball.en.GB o2gb

---------- Post added at 10:28 PM ---------- Previous post was at 10:22 PM ----------

I inserted a micro sim. but I dont know what kind of card used man who sold me the phone
[Moto G Q&A, Help & Troubleshooting] hacktrix2006:
So its a micro sim in now, so that's, stumped me then.
[Moto G Q&A, Help & Troubleshooting] lost101:
[MENTION=6890998]homalex[/MENTION] - When flashing the firmware image, did you include the following commands:

mfastboot flash modem NON-HLOS.bin

mfastboot erase modemst1

mfastboot erase modemst2

mfastboot flash fsg fsg.mbn​
[Moto G Q&A, Help & Troubleshooting] homalex:
Yes, these commands were
[Moto G Q&A, Help & Troubleshooting] lost101:
I would Unlock Bootloader (if not already done) - flash TWRP and install a custom non-Stock ROM, CM12 or SlimROM.
[Moto G Q&A, Help & Troubleshooting] homalex:
OK thanks. I'm going to try now
[Moto G Q&A, Help & Troubleshooting] Jonny993:
Moto G XT1039 locked, with no root permissions, but on latest Lollipop version.. Is there a way to flash a stock KITKAT image without losing the guarantee and without unlocking the bootloader?

Thanks in advance.. reading first page of this thread made me think that I can just downgrading without problems but I may be wrong..
[Moto G Q&A, Help & Troubleshooting] Jonny993:
UP!!!!
[Moto G Q&A, Help & Troubleshooting] lost101:
[MENTION=5099466]Jonny993[/MENTION] - It may be possible to only flash the 'system.img sparsechunk' files. For example:

mfastboot flash system system.img_sparsechunk1

mfastboot flash system system.img_sparsechunk2

mfastboot flash system system.img_sparsechunk3

mfastboot erase cache

mfastboot erase userdata

mfastboot reboot​

However, it should be stated; while Downgrading might seem like a good idea, the reality could be less desirable. You will get constant nagging to download / apply the Lollipop OTA Update and you will probably never be patched for Stagefright.
[Moto G Q&A, Help & Troubleshooting] Jonny993:
first of all thank you for your answer;

however, I partially understood what you said but what I didn't understand is the Stagefright thing.. but in the end, you don't suggest a downgrade, do you?

What can I do to make this phone goes faster? It lags as hell, and lollipop only worsened the situation.. maybe this is an OT question but please, help.. and I don't consider the factory reset more than a placebo side effect.. so I won't take it in consideration as a "valid option to take to make it goes faster".. please help, thanks in advance
[Moto G Q&A, Help & Troubleshooting] lost101:
[MENTION=5099466]Jonny993[/MENTION] - Since you are unwilling to unlock bootloader, I can only suggest the following:

1) mfastboot erase cache and mfastboot erase userdata

2) Make Animations faster in Developer Options
[Moto G Q&A, Help & Troubleshooting] Jonny993:
so the factory reset thing ("(...) erase userdata") remains the only thing to do eh? ok.. thank you anyway
[Moto G Q&A, Help & Troubleshooting] lost101:
Maybe if you are using an external SDCARD that is causing lag. Test without it inserted.
[Galaxy S II Q&A, Help & Troubleshooting] intoxicated.mad:
What is the possibility of porting sweet Lollipop to our little monster?? Edit : so the ans is somework has been done by quietly for I9100G you can learn about it in 2nd page!! and for I9100 there port has been started.
[Galaxy S II Q&A, Help & Troubleshooting] mosespl:
Probably the same as cm11. There is lack of drivers GPU for cm11 and same will be with cm12. So forget about flawly interface if would be drivers for mali from sgs2 it should be fine

Wysłane z mojego D5503 przy użyciu Tapatalka
[Galaxy S II Q&A, Help & Troubleshooting] amjath:
So all smoothness of material design will have hiccups?
[Galaxy S II Q&A, Help & Troubleshooting] maxmara2:
when will have it on our devices?

i've heard that the difficiulty of root lolipop....
[Galaxy S II Q&A, Help & Troubleshooting] mosespl:
Cm 12 will be when lollipop full code will be relased by google for now android lollipop is in final developer stage so in November should be official relaese but for s2 who knows

Wysłane z mojego D5503 przy użyciu Tapatalka
[Galaxy S II Q&A, Help & Troubleshooting] Hopper8:
Seriously? :rolleyes: we don't even have the source yet, but you want to know when you'll have the software on your device. Well, no one here is a prophet, so you're gonna have to wait and see how it pans out.
[Galaxy S II Q&A, Help & Troubleshooting] vinay.habib:
We're gonna have to wait for some good amount of time.

The Android L will be given to the flagship models first, and then us.

But I'm sure that teams like NeatRom will definitely have something in store for us a little sooner as S2 is still an active device for them.

Let's hope we get the lollipop sooner.
[Galaxy S II Q&A, Help & Troubleshooting] Saber:
Knowing cyanogenmod, they will release builds (monthly snapshots) months after they release the first m snapshot for nexus devices.

---------- Post added at 08:13 AM ---------- Previous post was at 08:12 AM ----------

True true.

---------- Post added at 08:14 AM ---------- Previous post was at 08:13 AM ----------

Most definitely by early next year we will see early builds for cm12.
[Galaxy S II Q&A, Help & Troubleshooting] intoxicated.mad:
I m talking abt ports not build from source .... Can it be done a bit earlier than frm source?? Everyone wants to lick ASAP, don't they??
[Galaxy S II Q&A, Help & Troubleshooting] Muthzer the One:
I read cyanogenmod won't bother much about android 5, and wait for it to be completely finished by Google before making new rom. In the meantime they would continue with KitKat in order to make it more stable.

Nevertheless they wanna keep an eye on Android 5 and get some good features from it.
[Galaxy S II Q&A, Help & Troubleshooting] JoMaNDye:
I'm using Samsung Galaxy S 2 and I have riffbox and some programming knowledge although my native language is Spanish. I would like to bring aid to the construction of a custom rom for the mentioned mobile.

If anyone needs me, I will gladly help yours.
[Galaxy S II Q&A, Help & Troubleshooting] klubbpaulo:
Great to hear from you! Welcome to this community!

Lollipop, we r waitin' 4 ya!
[Galaxy S II Q&A, Help & Troubleshooting] PS_TechGeek:
SGS II (GT - I91000 ) : No CM 11 M12 ?

Well as of now the chances look bleak, the nightlies seem to have stopped from 08th Nov and today we did not have a M12 build. Hoping against hope that this is not the end of road for GT-I9100. :angel:
[Galaxy S II Q&A, Help & Troubleshooting] hengsheng120:
hope for i9100G

Galaxy Nexus just got AOSP lollipop, so there's hope for i9100G which uses the same soc
[Galaxy S II Q&A, Help & Troubleshooting] intoxicated.mad:
Hope

omni rom is searching for an active maintainer for the devices which they are supporting now if some devs are interested from our side there's a good chance ... Fingers crossed
[Galaxy S II Q&A, Help & Troubleshooting] intoxicated.mad:
PROGRESS

here is what has been done to our little monster .... xdaforums.com/galaxy-s2/development/gt-i9100g-omnirom-4-4-nightly-builds-t2527350/page79 jiyangyi is rocking!! and from ryuinferno's post we can guess he will be back to development after his exams.... now it seems that i9100g is far ahead than i9100 .... http://imgur.com/2dxtqpH you can see ril and wifi already working!!
[Galaxy S II Q&A, Help & Troubleshooting] bob_dobbs:
I have to ask something - are you all so happy with KitKat builds for the S2 that you want Lollipop? The last stable Cyanogenmod build is 10.1.3 (JB 4.2.2) from September 2013, which is what I am running now, and am finally happy with the way my S2 is working - have got almost 36 hours out of it with light to moderate use (and a new original battery). Before that I tried various more recent builds of CM, Paranoid Android and maybe some others, which all suffered from the same problems: drastically increased battery use (including with the new battery) and frequent crashes (random resets and crashes, particularly problems with the camera). Now I have rolled back to 4.2.2 it's all fixed - it's too much of a coincidence.

So what is to say Lollipop won't have the same problems on S2, or have others not had these issues running Android versions above 4.2.2 on the S2?
[Galaxy S II Q&A, Help & Troubleshooting] efex09:
Omni Rom 5.0 Unofficial Build released for gt i9100g

here it is...http://xdaforums.com/galaxy-s2/development/gt-i9100g-omnirom-5-0-unofficial-builds-t2947772
[Galaxy S II Q&A, Help & Troubleshooting] Aditya Ladwa:
When i flash gapps on my i9100 i get a status 1 error .Due to insufficient space.

Waiting for micro gapps :crying:
[Galaxy S II Q&A, Help & Troubleshooting] aksh2001:
good
[Android Q&A, Help & Troubleshooting] skivnit:
I have a 64gb SanDisk that went bad, I can read but can't write to it. Problem is I had few pics on my internal then tried to copy to the external sd card it worked but after a reboot, I didn't find them in any of the cards. Those are very important pics and I would like to recover. I tried recovering from the external using various software, none found those pics. So I'm only left with hope to recover them from my phone but don't know how.
[Xposed General] shnapsi:
Hello,

I want to hook a method in com.android.commands.pm.PM but i fail to load this class (i get class not found exception)

I tried both using initZygote approach and handleLoadPackage approach, both with the same result..

what am i doing wrong?

Thanks!
[Xposed General] shnapsi:
Maybe [MENTION=4775688]GermainZ[/MENTION] can help? :)
[Xposed General] GermainZ:
Can you post the relevant Xposed code and exact error, please?
[Xposed General] shnapsi:
Hi,

Thanks.

Yes, here are my both tries...

public class XPm implements IXposedHookZygoteInit, IXposedHookLoadPackage {

[MENTION=439709]override[/MENTION]
public void initZygote(StartupParam startupParam) throws Throwable {
String methodName = "installFailureToString";
XC_MethodHook hookMethod = new XC_MethodHook() {
[MENTION=439709]override[/MENTION]
protected void beforeHookedMethod(final MethodHookParam param)
throws Throwable {
int result = (Integer) param.args[0];
switch (result) {
case 1:
param.setResult("BLA");
break;
case 2:
param.setResult("BLA BLA");
break;
}
}
};

final Class<?> clsPMS = XposedHelpers.findClass(
"com.android.commands.pm.Pm$1", XPm.class.getClassLoader());

XposedHelpers.findAndHookMethod(clsPMS, methodName, int.class,
hookMethod);

}

[MENTION=439709]override[/MENTION]
public void handleLoadPackage(LoadPackageParam lpparam) throws Throwable {
String methodName = "installFailureToString";

if (!lpparam.packageName.equals("com.android.commands.pm"))
return;
Log.d(TAG, "com.android.commands.pm is loaded...");
XC_MethodHook hookMethod = new XC_MethodHook() {
[MENTION=439709]override[/MENTION]
protected void beforeHookedMethod(final MethodHookParam param)
throws Throwable {
int result = (Integer) param.args[0];
switch (result) {
case 1:
param.setResult("BLA");
break;
case 2:
param.setResult("BLA BLA");
break;
}
}
};

final Class<?> clsPMS = XposedHelpers.findClass(
"com.android.commands.pm.Pm", XPm.class.getClassLoader());

XposedHelpers.findAndHookMethod(clsPMS, methodName, int.class,
hookMethod);

}

}
[Xposed General] GermainZ:
Well, there is no android.commands.pm. Not sure what you're trying to hook, but you should get the correct class name first. :)

PS. Please wrap your code in [CODE][/CODE] tags next time.
[Xposed General] shnapsi:
Hi,

sure, Sorry.

one of the things android.commands.pm.Pm is doing is to print the ADB installation message like "Failure [INVALIED_APK]"

my goal is to print my own message, so it's either by hooking the method i tried or by hooking PackageManager.class.getFields() and add my own fields.

this is the code from Pm.Java

/**
* Converts a failure code into a string by using reflection to find a matching constant
* in PackageManager.
*/
private String installFailureToString(int result) {
Field[] fields = PackageManager.class.getFields();

for (Field f: fields) {
if (f.getType() == int.class) {
int modifiers = f.getModifiers();
// only look at public final static fields.
if (((modifiers & Modifier.FINAL) != 0) &&
((modifiers & Modifier.PUBLIC) != 0) &&
((modifiers & Modifier.STATIC) != 0)) {
String fieldName = f.getName();
if (fieldName.startsWith("INSTALL_FAILED_") ||
fieldName.startsWith("INSTALL_PARSE_FAILED_")) {
// get the int value and compare it to result.
try {
if (result == f.getInt(null)) {
return fieldName;
}
} catch (IllegalAccessException e) {
// this shouldn't happen since we only look for public static fields.
}
}
}
}
}

// couldn't find a matching constant? return the value
return Integer.toString(result);
}

If it's not possible to hook this method, i understand i should add my own fields to packageManager

Thanks!
[Xposed General] GermainZ:
So we're talking about this? You haven't pasted the exact error but I'm guessing it's failing because you're using the wrong classloader. In initZygote, you shouldn't normally pass a classloader — just pass "null". In handleLoadPackage, use the hooked process' classloader (lpparam.classLoader).

EDIT: You can change/get a method's return value using param.setResult/param.getResult. Check the wiki for some more info.
[Xposed General] shnapsi:
Hi,

First of all thanks a lot!

this is the exception I'm getting when trying to initZygote and pass null as classloader:

de.robv.android.xposed.XposedHelpers$ClassNotFoundError: java.lang.ClassNotFoundException: com.android.commands.pm.Pm
I/Xposed ( 8491):	at de.robv.android.xposed.XposedHelpers.findClass(XposedHelpers.java:52)
I/Xposed ( 8491):	at com.myapp.Hooks.XPm.initZygote(XPm.java:29)
I/Xposed ( 8491):	at de.robv.android.xposed.XposedBridge.loadModule(XposedBridge.java:437)
I/Xposed ( 8491):	at de.robv.android.xposed.XposedBridge.loadModules(XposedBridge.java:386)
I/Xposed ( 8491):	at de.robv.android.xposed.XposedBridge.main(XposedBridge.java:120)
I/Xposed ( 8491):	at dalvik.system.NativeStart.main(Native Method)
I/Xposed ( 8491): Caused by: java.lang.ClassNotFoundException: com.android.commands.pm.Pm
I/Xposed ( 8491):	at java.lang.Class.classForName(Native Method)
I/Xposed ( 8491):	at java.lang.Class.forName(Class.java:204)
I/Xposed ( 8491):	at external.org.apache.commons.lang3.ClassUtils.getClass(ClassUtils.java:823)
I/Xposed ( 8491):	at de.robv.android.xposed.XposedHelpers.findClass(XposedHelpers.java:50)
I/Xposed ( 8491):	... 5 more
I/Xposed ( 8491): Caused by: java.lang.NoClassDefFoundError: com/android/commands/pm/Pm
I/Xposed ( 8491):	... 9 more
I/Xposed ( 8491): Caused by: java.lang.ClassNotFoundException: Didn't find class "com.android.commands.pm.Pm" on path: DexPathList[[zip file "/data/data/de.robv.android.xposed.installer/bin/XposedBridge.jar"],nativeLibraryDirectories=[/system/lib]]

BTW, i also tried this approach:

final Class<?> clsPm = XposedHelpers.findClass("android.content.pm.PackageManager", XPm.class.getClassLoader());
XposedHelpers.setAdditionalStaticField(clsPm, "MY_MESSAGE", 1000);

But it doesn't seem to work either...
[Xposed General] GermainZ:
As I said, you're using the wrong class loader. :)
[Xposed General] shnapsi:
Yes, i understand that, but which class loader should I use?

actually, which approach is better for this case? use initZygote or handleLoadPackage?

this how i did it this time:

final Class<?> clsPMS = XposedHelpers.findClass("com.android.commands.pm.Pm", null);
XposedHelpers.findAndHookMethod(clsPMS, methodName,int.class, hookMethod);
[Xposed General] GermainZ:
I'd use initZygote since it's more readable/shorter.

As for which class loader to use, please see post #7.
[Xposed General] shnapsi:
I tried that (please see post #10), is that what you meant? since i got the same exception as in post #8
[Xposed General] GermainZ:
You didn't indicate anything was wrong in post #10, I assumed that had worked. As usual, you should post the full code (including the initZygote/handleLoadPackage part so we know which you're using) and the exact error. :)

This is how you'd do it in initZygote:

public void initZygote(StartupParam startupParam) throws Throwable {
findAndHookMethod("full.class.Name", null, "methodName",
SomeArgument.class, new XC_MethodHook() {
[PLAIN]@Override[/PLAIN]
protected void afterHookedMethod(final MethodHookParam param) throws Throwable {
// Do something.
}
}
);
}

And in handleLoadPackage:

public void handleLoadPackage(final XC_LoadPackage.LoadPackageParam lpparam) throws Throwable {
if (!lpparam.packageName.equals("some.package.name"))
return;

findAndHookMethod("full.class.Name", lpparam.classLoader, "methodName",
SomeArgument.class, new XC_MethodHook() {
[PLAIN]@Override[/PLAIN]
protected void afterHookedMethod(final MethodHookParam param) throws Throwable {
// Do something.
}
}
);
}
[Xposed General] shnapsi:
Hi,

Strange since i do see in #10 an example (not full code...) of how i tried to do it.

anyway, I don't think that this is my problem. here is my code:

public class XPm implements IXposedHookZygoteInit {

@Override
public void initZygote(StartupParam startupParam) throws Throwable {
String methodName = "installFailureToString";
XC_MethodHook hookMethod = new XC_MethodHook() {
@Override
protected void beforeHookedMethod(final MethodHookParam param) throws Throwable {
int result = (Integer) param.args[0];
switch(result) {
case 1:
param.setResult("BLA");
break;
case 2:
param.setResult("BLA BLA");
break;
}
}
};

final Class<?> clsPMS = XposedHelpers.findClass("com.android.commands.pm.Pm", null);

XposedHelpers.findAndHookMethod(clsPMS, methodName,int.class, hookMethod);

}

}
[Xposed General] GermainZ:
Not the initZygote/handleLoadPackage part, though, so I couldn't know which you're using.

That looks correct to me. What's the error you're getting?
[Xposed General] shnapsi:
The same exception as i posted in #8
[Xposed General] GermainZ:
I think this might be your problem (see post #2): http://xdaforums.com/xposed/xposed-api-changelog-developer-news-t2714067
[Xposed General] shnapsi:
So, I'm not sure I understand, can i hook it or not?

I didn't find IXposedHookCmdInit under XposedHelpers...

Thanks!
[Xposed General] GermainZ:
Also check post #4 in the same thread.

Basically, you could do it, but you probably don't want to since it's deprecated and disabled by default. I guess you'll want to look into hooking PackageManager instead.
[Xposed General] shnapsi:
I agree, so if this the method I wanted to hook (under PM):

private String installFailureToString(int result) {
Field[] fields = PackageManager.class.getFields();

for (Field f: fields) {
if (f.getType() == int.class) {
int modifiers = f.getModifiers();
// only look at public final static fields.
if (((modifiers & Modifier.FINAL) != 0) &&
((modifiers & Modifier.PUBLIC) != 0) &&
((modifiers & Modifier.STATIC) != 0)) {
String fieldName = f.getName();
if (fieldName.startsWith("INSTALL_FAILED_") ||
fieldName.startsWith("INSTALL_PARSE_FAILED_")) {
// get the int value and compare it to result.
try {
if (result == f.getInt(null)) {
return fieldName;
}
} catch (IllegalAccessException e) {
// this shouldn't happen since we only look for public static fields.
}
}
}
}
}

// couldn't find a matching constant? return the value
return Integer.toString(result);
}

I now need to hook this part:

Field[] fields = PackageManager.class.getFields();

which as i understand means to add more fields under PackageManager. is this the right way to do it? (since it didn't work for me)

final Class<?> clsPMS = XposedHelpers.findClass("android.content.pm.PackageManager", XPm.class.getClassLoader());
XposedHelpers.setAdditionalStaticField(clsPMS, "MY_KEY", 1000);

Thanks!
[General Questions and Answers] NoobHTCEVOShiftGuy:
Hello all I am on a sm-n900v Galaxy Note 3 32gb on Stock Android 4.4.2 with towelroot, and I came across this link http://xdaforums.com/xposed/modules/mod-pictures2sd-v1-0-6-makes-camera-t2408880 and I do have some questions my first one is does anyone have an knowledge if this is working on 4.4.2 and do I need to install the rom version for this to work along with the xposed framework or what. Any guidance I can be given would be great about this thank you.
[General Questions and Answers] ishaang:
I think it might work, no harm in trying it out and seeing?

Also I think you will get more meaningful replies if you just post your question on that same thread
[General Questions and Answers] NoobHTCEVOShiftGuy:
I will give that a try thank you.
[One (M8) Q&A, Help & Troubleshooting] GaelForce:
Morning all,

Is there anyway (native, mod or otherwise) to change the default state of this option to 'on'?

I find that I use it more often than not.

I tried saving a Custom Camera with it on, but those settings are saved.

Thanks

GF
[Galaxy Y GT-S5360 and Duos 6102 Q&A, Help & Troubl] QA Bot:
Q&A for [ROM] Hyperion 9 GM Final Build Final Rev + Update-01

Some developers prefer that questions remain separate from their main development thread to help keep things organized. Placing your question within this thread will increase its chances of being answered by a member of the community or by the developer. Thanks for understanding and for helping to keep XDA neat and tidy! :smile:
[Galaxy Y GT-S5360 and Duos 6102 Q&A, Help & Troubl] Cosmitron V:
this roms UI is pretty smooth..clean and ofc transparent...though the sound quality lags a bit behind...as for bugs..i found that wifi toggle bug still being there..ut thats fine as far as im getting a stable performance...overall i liked this rom :cowboy:

just get the Cwm provided there and flash the rom...with everything mounted...if you are getting imei probs. then flash the hyperion gm08 Ril Fix...that helps for sure...
[Galaxy Y GT-S5360 and Duos 6102 Q&A, Help & Troubl] –NigthFury–:
whats the wifi toggle problem
[Galaxy Y GT-S5360 and Duos 6102 Q&A, Help & Troubl] Cosmitron V:
well if u touch the wifi logo in the toggle bar then at times it shows an error (only to shut down the wifi)....long pressing the symbol will get you directly to the wifi settings menu where u have to manually shut it down....other than this this Rom by Sir Carl has no bugs at all...and is THE BEST for sgy When overclocked by merruk 2.5 to 1.25 Ghz and undervolted to say -120mV with bacem tweak along with V6 Supercharger and Kickass kernelizer scripts(Latest versions of both) ,Bravia engine 3 ,beats Audio and Fly On Mod used....it runs like an Alien Device...i had a nice experience with it