yashsingh1/xdaforums huggingface dataset:
[Moto G General] mmims24:
https://github.com/CyanogenMod/andr...mmit/936401a6080f1eefbd0707a357b8668769c48021

This was the commit by [MENTION=5778309]luca020400[/MENTION] that changed roaming indicator off to boost mobile, maybe it can help you figure out how they did it in 12.1
[Moto G General] mmims24:
So by adding the following lines to build.prop I got rid of Roaming Indicator Off. Now Carrier Label says Boost Mobile.

ro.cdma.home.operator.numeric=311870

ro.cdma.home.operator.alpha=Boost Mobile.

Hope that helps.

P.S. I added said lines to build. Prop of cyanpop. Not sure if it will work for all cm13 ROMs or not. Will try on CM13 and AICP M when I get home.
[Moto G General] tpa-moto:
Thanks. I may have used xml-mcc310-mnc00 instead of xml-mcc310-mnc000, but it seems that they are equivalent, so probably that's not it. I can see that after some time gsm.operator.numeric is set to 31000 and maybe this is what causes the update of the labels (as long as the telephony-common.jar is used).

Since changing framework-res.apk doesn't cause the dalvik to be recreated, here attached some more of them.

Also, what happens if you set the numeric to something else while using the patched telephony-common.jar as mmims24 was saying?

PS: I still have your cm-12.1 logs.

EDIT: forgot to upload the zips. Since I'm having some issues uploading them here, I uploaded them on Mega: https://mega.nz/#F!bcBFULaZ!7_wTcvQk74Lc4GgEjKEb0Q

[MENTION=5919537]mmims24[/MENTION] yes, I know all this stuff and as I said the problem is that there's nothing that matches 310000. Setting the numeric to 311870 does the trick because as I said the overlays are still there. But if a solution requires users to touch /system, then it's not a solution. It just seems that 310000 is kind of an odd numeric that messes things up.

And by the way the fingerprint doesn't really do anything, this is the commit (the one after this actually) https://github.com/CyanogenMod/andr...mmit/3706c0e71ab828fa52466abc3d73c0b632ac3d3b.

Do you get the "No service" label in the quick settings (not sure what that is, I see nothing on my phone, so it must be something that appears in case of problems)?
[Moto G General] mmims24:
I have no idea how [MENTION=5778309]luca020400[/MENTION] did it on cm12.1 but once he had the overlays, he had the solution that did not require users to touch /system. I never get no service on quick settings unless I'm in an area where I don't get service. When I first flashed ROM I had Roaming Indicator Off, but never no service. Is there a way to use init-falcon.c or init'd to set the value to 311870 so user never has to touch /system?
[Moto G General] mmims24:
I remember a while back someone using su'd to set selinux to permissive. Could that also be used to set numeric to 311870
[Moto G General] mmims24:
" />+ <EriInfo RoamingIndicator="1" IconIndex="1" IconMode="0" EriText="Boost Mobile" CallPromptId="0" AlertId="0" DataServiceSupport="1" />+

That's what fixed it in cm12.1 I believe. Are those values the same in cm13. I'm unable to read the eri.xml on my current device. I'm just throwing ideas out there as I've been back and forth to the hospital with a very sick mother and working full time. I haven't gotten to decompile anything and really dig around. So I'm making a couple of ideas and maybe one will work.
[Moto G General] tpa-moto:
I can see that.

You probably didn't follow the thread carefully.

Short recap: I have to use 310000. The previous code (cm-12.1 or older) was assuming that every CDMA device was on Boost Mobile.

FYI I know exactly how things worked, how they got rid of the "Roaming Indicator Off" etc, I'm just trying to do things properly.

Anyway, [MENTION=5768732]amarc78[/MENTION], don't bother testing all the apks, I think the 'No service' label is due to the fact that I'm now using an empty string. I'll look better into this when I have time.

Anyway, I can probably do something to detect Boost etc, but that's something additional.
[Moto G General] mmims24:
[MENTION=6937116]tpa-moto[/MENTION] your knowledge is far superior than mine. I have been following the thread, but a lot is like a foreign language to me. I'll quit wasting your time and just test whatever you may need me to. So much for trying to learn. Lol, I forget how annoying people trying to learn can be for you demigods in this field. Keep up the good work, it's much appreciated.
[Moto G General] tpa-moto:
Don't take it the wrong way, suggestion are always welcome. It's just that you were looking for a solution in cm-12.1, but things are different now and just wanted to tell you that what we used to do is not enough. You were correct though, that line was what got rid of 'Roaming Indicator Off' and it requires the right numeric.

Anyway, given what amarc78 said, it seems that the ERI text for 310000 is only taken into consideration if the SIM status is READY, which happens only with the patched telephony-common.jar. Well, who cares, I want that change merged, so this shouldn't be a problem.

The real problem is the 'No service' thing. I think that's due to a bug in SystemUI. Empty strings are allowed (https://github.com/CyanogenMod/andr...mmit/f4871b686f35aaa38bc1a088ec8845b038241e16), however SystemUI uses 'No service' when the length of the carrier name (+ another string that's always empty for CDMA) is zero.

Let's see what happens with this patched SystemUI.apk on top of http://xdaforums.com/showpost.php?p=64975899&postcount=277 (i.e. telephony-common.jar) and http://xdaforums.com/showpost.php?p=65014559&postcount=294 (i.e. framework-res.apk with 310000 eri).
[Moto G General] mmims24:
Which nightly for these zips?
[Moto G General] tpa-moto:
They should work with any somewhat recent nightly. My sources are a bit behind (2016-01-25 I think), but almost nothing changed (I can see that a new animation was added for the quick tiles editor, nothing relevant).
[Moto G General] Phrodini:
Any random reboots with any of the builds?
[Moto G General] n0ts0smart:
No. Personally I have not had any.
[Moto G General] :
Carrier label is blank in status bar and quick settings data tile. Data still works, but no MMS.
[Moto G General] tpa-moto:
Oh, now I understand where 'No service' was shown. I guess it looks ugly now and showing Sprint is probably better.

Now let me see if I can detect Boost Mobile.

What is the content of the following files, if they exist (post them if you prefer)?

/persist/prop/ro_cust.prop
/persist/prop/rw_cust.prop

I want to see if I can get the actual MVNO by reading the value

ro.home.operator.carrierid

In HandsomeOne's persist dump I found

ro.home.operator.carrierid=2012051001

and this should be for RingPlus, but I have no idea what that number is.
[Moto G General] :
Here you go.
[Moto G General] tpa-moto:
I couldn't ask for something better:

ro.home.operator.carrierid=BOOST

I can also see that there are some more props compared to RingPlus, including the right numeric 311870. Anyway, here attached a kernel (/init actually) that detects Boost Mobile.
[Moto G General] :
That made it say Boost Mobile but no sim is back along with it.
[Moto G General] tpa-moto:
01-30 11:03:58.041 D/IccCardProxy( 1530): Icc changed. Reregestering.
01-30 11:03:58.042 E/IccCardProxy( 1530): setExternalState: set mPhoneId=0 mExternalState=ABSENT
01-30 11:03:58.042 D/TelephonyManager( 1530): setTelephonyProperty: success phoneId=0 property=gsm.sim.state value: ABSENT propVal=ABSENT
01-30 11:03:58.042 D/IccCardProxy( 1530): broadcastIccStateChangedIntent: QuietMode NOT Broadcasting intent ACTION_SIM_STATE_CHANGED value=ABSENT reason=null

You are not using the patched telephony-common.jar, am I right?
[Moto G General] :
Nope, I was using it. That kernel would in boot with multirom, so I installed CM as primary and tried the kernel with and without the other zips. Unless I screwed up, those logs were after all were installed.

Edit:I also had the same result with the kernel alone and with the patches.
[Moto G General] tpa-moto:
OK, this is maybe caused by some additional props I added, props that are normally automatically set once the connection has been established.

The kernel attached will only set the usual 'ro.*' props.
[Moto G General] :
That seems to have done it. Boost Mobile all around and no sim is gone. I had to delete Setup Wizard from recovery though because of constant force close right after boot.
[Moto G General] mrfeh:
anybody else trying to use the CM nightlies?

I installed the CM nightly from last Wednesday (1/27), and my XT1031 cannot access mobile data.

Anybody else having success or a similar issue?
[Moto G General] :
Try the 2/1 nightly. It should be fine.
[Moto G General] tpa-moto:
That shouldn't happen. Please post some logs (radio/modem logcat and logcat). Also, which carrier do you use?
[Moto G General] mrfeh:
Sprint.

I'm gonna install the 2/1 nightly and see if that makes a difference.
[Moto G General] :
No sim came back on the 2/1 nightly. It says Boost Mobile, but no sim also. I'll post some logs later if you want to check it out.
[Moto G General] tpa-moto:
The needed commit is still in review: https://review.cyanogenmod.org/#/c/129884/
[Moto G General] mrfeh:
Makes sense. The 2/1 nightly also does not work for me.
[Moto G General] tpa-moto:
No, moble data shouldn't deped on that. Can you grab some logs? logcat, radio logcat and dmesg. Right after a reboot possibly. I suspect the problem is the lack of a proper numeric.
[Moto G General] mrfeh:
Can you point me at a howto for grabbing these logs? I haven't done that before.
[Moto G General] tpa-moto:
I usually use adb, so I looked for some app on the play store. This looks good: https://play.google.com/store/apps/details?id=com.tortel.syslog

Grab everything and (modem and kernel logs are the ones I'm mostly interested in)
[Moto G General] mrfeh:
I know how to use adb, if that makes things simpler. If not, I'll grab the app.
[Moto G General] tpa-moto:
adb shell "logcat -b radio -d > /sdcard/logcat-radio"
adb shell "logcat -d > /sdcard/logcat"
adb shell "dmesg > /sdcard/dmesg"

Using the apps should be the same, so do as you prefer.
[Moto G General] mrfeh:
Files attached:
[Moto G General] tpa-moto:
It could be that you need IPV4V6 as protocol for the APN. I can see you have a dummy APN profile, which I guess is there because you flashed CM before it became official for CDMA. So run the following commands to clear the APN database.

adb root
adb shell stop
adb shell "rm /data/data/com.android.providers.telephony/databases/telephony.db /data/data/com.android.providers.telephony/databases/telephony.db-journal"
adb reboot
[Moto G General] mrfeh:
Still no mobile data (after running above commands).
[Moto G General] tpa-moto:
Could you give me again the output of

adb shell "logcat -d > /sdcard/logcat"

Did it work before the update to 27-01-2016 nightly?
[Moto G General] mrfeh:
Log attached.

I can't say if things were working before last week. I usually have mobile data off, because I have wifi 99% of the time.
[Moto G General] tpa-moto:
Sorry, I wrote the wrong command.

adb shell "logcat -b radio -d > /sdcard/logcat-radio"

But did it ever work or you've never tried it?
[Moto G General] mrfeh:
I never tried it, so I can't say if mobile data was functioning or not.
[Moto G General] tpa-moto:
I'm trying to figure out what's wrong. What happens if you toggle airplane mode, if you haven't tried it already? (I'm thinking about this: http://review.cyanogenmod.org/#/c/129698/)
[Moto G General] mrfeh:
No mobile data after toggling airplane mode.
[Moto G General] tpa-moto:
Thanks for trying. I can't find the cause of the problem, I found this in the log

DcActivatingState onSetupConnectionCompleted result=ERR_RilError SetupResult.mFailCause=ERROR_UNSPECIFIED

(this is a small part of a long line: http://pastebin.com/raw/23NPZRWv) which isn't really helpful. It just says something's wrong, but not what is wrong.

A minor difference between cm-13.0 and cm-12.1 is that you are not detected as Boost Mobile user, which caused the following props to be set:

ro.mot.build.customerid=sprint
ro.cdma.home.operator.alpha=Boost Mobile
ro.cdma.home.operator.numeric=311870

I really doubt these have any effect. The only important prop is ro.mot.build.customerid, but in theory that should be set to sprint already. Just to double check, could you run

getprop ro.mot.build.customerid

and see if it returns sprint?

In case it doesn't, could you try to add the above props to the build prop (even though only one should be needed)?

adb root
adb remount
adb shell 'echo "#####" >> /system/build.prop'
adb shell 'echo ro.mot.build.customerid=sprint >> /system/build.prop'
adb shell 'echo ro.cdma.home.operator.alpha=Boost Mobile >> /system/build.prop'
adb shell 'echo ro.cdma.home.operator.numeric=311870 >> /system/build.prop'
# and reboot
[Moto G General] mrfeh:
Yes, this does return "sprint".

FWIW - this phone was purchased in a Boost box, but I've always used Ting as my service provider (Sprint network).
[Moto G General] tpa-moto:
Oh, could you try to add the props above then? I'm not sure if gsm.sim.operator.numeric is set to the same value of gsm.operator.numeric, but I can see that "/vendor/lib/libril-qc-qmi-1.so" uses that prop for something.
[Moto G General] mrfeh:
Done; no difference.

Thanks for your help, by the way! :D
[Moto G General] tpa-moto:
How about the following commands?

adb root
adb shell
restorecon -Rv /pds
# reboot
adb shell 'dmesg > /sdcard/dmesg' #and post this

I see some denials in your kernel log. I honestly don't know what you, CDMA users, have in /pds, but I can see /pds/omadm/ in mine, and that's something related to Sprint. restorecon should fix those. Again, I doubt this is of any help, but who knows, I'm really at a loss here, I can't find any obvious error.
[Moto G General] mrfeh:
Here's the log (still no data).

I'm leaving my "mobile phone debugging" machine for the day, so if you have other suggestions, I can try them tomorrow.
[Moto G General] tpa-moto:
At least the denials disappeared.

The following prop can maybe do something, but since it wasn't needed before, I can't see why it should be needed now.

adb root
adb shell setprop persist.telephony.oosisdc false
# reboot
[Moto G General] mrfeh:
No difference.

Are other folks using CM nightlies and have mobile data?
[Moto G General] :
Yes, on xt1031 with Boost Mobile.
[Moto G General] mrfeh:
Did you do a factory reset when you moved to CM 13?

I did a dirty flash from CM 12.1.
[Moto G General] :
Yes, I also usually install it as a secondary rom with Multirom, but do get data when installed normally as primary.
[Moto G General] n0ts0smart:
I would certainly recommend a clean flash to rule it out as being the issue.
[Moto G General] mrfeh:
I was going to do just that, when I discovered I can't execute a backup.

https://code.google.com/p/android-developer-preview/issues/detail?id=2836
[Moto G General] :
I would recommend a complete wipr and flash stock firmware with adb, let it boot, wipe again and then try flashing CM13 again.
[Moto G General] mrfeh:
Yes, except I don't want to restore all my apps and settings by hand.

I'm gonna wait for a CM13 that lets me back it up.
[Moto G General] :
That may not happen. I don't think CM13 is your problem. If you have a corrupt partition, which is very likely if you have been dirty flashing for a while, you may have no choice but to wipe everything. Have you been dirty flashing different roms on top of each other? If so, I guarantee your data is corrupted.
[Moto G General] tpa-moto:
I'm not sure a wipe would help. And for what is worth, adb backup works just fine here. I haven't tried to restore the backup though.

Anyway, I found this in your log:

02-01 14:48:27.666 1612 1612 D DCT : [0]getAnyDataEnabled(true) = false

The documentation of getAnyDataEnabled() says:

/**
* Report on whether data connectivity is enabled
*
* @return {@code false} if data connectivity has been explicitly disabled,
* {@code true} otherwise.
*/

So... is mobile data enabled? There might be other reasons for that to return false, but having mobile data disabled is one of them.
[Moto G General] mrfeh:
Yes, mobile data is enabled
[Moto G General] tpa-moto:
Umm, I think something went wrong with the APNs. You updated to cm-13.0 using an unofficial build, right? I'm asking this because I want to know if doing an update via the official channel could cause similar problems.

Anyway, try this:

adb root
adb shell sed -i "s:MMB29U:MMB29T:g" /data/data/com.android.providers.telephony/shared_prefs/build-id.xml
# reboot

This should make the telephony part of Android think that a new major upgrade was installed and hopefully fix what needs to be fixed.
[Moto G General] mrfeh:
When I first upgraded to cm13, I took one of the nightlies and applied the changes described in this thread. Over the last week, I've been installing cm nightlies, as folks have reported that those changes have been rolled into the cm13 downloads.

Thanks for the attempt! Didn't correct the problem, however.
[Moto G General] tpa-moto:
Damn, I hope the cm-12.1 -> cm-13.0 upgrade is not messing things up....

Anyway, I suspect that the preferred APN, if set, has no corresponding entry in the database. You can check that by running:

adb root
adb shell stop
adb shell cat /data/data/com.android.providers.telephony/shared_prefs/preferred-apn.xml

which should return something like:

<?xml version='1.0' encoding='utf-8' standalone='yes' ?>
<map>
<long name="apn_id1" value="[COLOR=RED]100[/COLOR]" />
</map>

Then you can see if there's a corresponding entry in the database with

adb shell 'sqlite3 /data/data/com.android.providers.telephony/databases/telephony.db "SELECT * FROM carriers WHERE _id=[COLOR=RED]100[/COLOR]"'

(Note the red colored numbers, they must match).

If the last command doesn't return anything, try with

adb shell rm /data/data/com.android.providers.telephony/shared_prefs/preferred-apn.xml
adb reboot

If this doesn't work, we can manually set the correct value of the preferred APN.

I wonder why you don't have access to the database settings, that would allow you to do all of this simply pressing few buttons.
[Moto G General] mrfeh:
That map is empty on my phone. Here's the output:

<?xml version='1.0' encoding='utf-8' standalone='yes' ?>
<map />
[Moto G General] tpa-moto:
Oh...

well, I wonder what happens if you try to make it look like mine. To get the value to use, run:

adb shell 'sqlite3 /data/data/com.android.providers.telephony/databases/telephony.db "SELECT _id FROM carriers WHERE numeric=310000"'

Here I used 310000 as numeric, but maybe you have something else now, because of some changes I suggested. So run the following to get your current numeric.

adb shell getprop ro.cdma.home.operator.numeric

The first command can return more lines (I think you'll get 2 lines), just pick one value.
[Moto G General] HandsomeOne:
after, "adb shell getprop ro.cdma.home.operator.numeric" i get 310000 flashed clean 02/01/16 nightly
[Moto G General] mister november:
I hope your Mother finds better health and relief for both of you, thank you for your hard work on this phone.
[Moto G General] mrfeh:
My numeric is 310000. So, the select statement above returns:

1
2

So - what do I do with that info?
[Moto G General] tpa-moto:
Put it in preferred-apn.xml. I'm not sure this will work, there's a chance Android will ignore it and restore the empty map, but try these commands:

adb root
adb shell
stop
echo "<?xml version='1.0' encoding='utf-8' standalone='yes' ?>\n<map>\n <long name=\"apn_id1\" value=\"1\" />\n</map>" > /data/data/com.android.providers.telephony/shared_prefs/preferred-apn.xml
reboot
[Moto G General] mrfeh:
Not sure what you mean by this. Are you saying the contents of the file should be this?:

<?xml version='1.0' encoding='utf-8' standalone='yes' ?>
<map>
<long name="apn_id1" value="1" />
</map>
[Moto G General] tpa-moto:
Yes, the commands I posted do exactly that.
[Moto G General] HandsomeOne:
After reboot "value=0" ,also made manual edit to preferred-apn.xml on reboot back to "value=0"
[Moto G General] mrfeh:
Ah, yes. Sorry - I didn't look closely at the commands you specified.

Contents of that file are retained after reboot - still no mobile data, however.
[Moto G General] tpa-moto:
If you have working mobile data, you don't need this.

Ummm. Could you upload a new logcat, after a reboot possibily?

adb logcat -b radio -d > /sdcard/logcat-radio.txt
[Moto G General] HandsomeOne:
Here is mine
[Moto G General] mrfeh:
Here you go:
[Moto G General] tpa-moto:
Didn't you have working data? I remember you did.

Wild guess. Could you try to disable data roaming?
[Moto G General] inyourface09:
Ive got a build in the oven that will eliminate any "boring" fixes such as adding eri.xml for version and boost apns, etc.

radio log is basically identical to working log of 5.1
[Moto G General] mmims24:
So you added all of the boost overlays? Sounds like you may have it fixed. Will you share it with me when it comes out of the oven?
[Moto G General] inyourface09:
It takes me awhile to upload things, currently phone crashes cause it tries to reverselookup the incoming or outgoing phone number but no data so you get an NPE. Voice Works and data "should" be working but wont attach itself. Not getting any IP but full data registration from RIL and telephony. If the simple fixes dont work Im going to start looking into dataconnection in telephony frameworks.
[Moto G General] mmims24:
I just had telephony frameworks pulled up earlier. I may dig back in.
[Moto G General] mightysween:
I just cant get it to install on my G... even with 0x3 added to the script, it fails. Probably need to start fresh.

Anyhow, making it not require a SIM should get a proper SUB... the rest should fall into place.

With 12.x we went off on many tangents, but in the end it was that single fix that did the trick.

---------- Post added at 09:51 AM ---------- Previous post was at 09:30 AM ----------

just to be clear, that log above is with all of these (or corresponding) changes?

---------- Post added at 09:51 AM ---------- Previous post was at 09:51 AM ----------

https://github.com/CyanogenMod/andr...mmit/3c019b06a3f479c1e9691295f058108b120b533d
[Moto G General] :
If I remember correctly, you have an XT1028. I believe the radio is 0x2 and 0x3 is for XT1031. Try removing all lines added for the radios or just change the 0x1 line to 0x2 and it should work. I've had no trouble with my XT1031. By the way, I'm glad to see you here trying to fix data again, I was wondering where everyone who helped on CM12 was!
[Moto G General] mightysween:
I have the xt1031... was running xt1028 firmware on it.

No radio assert error... just the E: error executing binary. Tried changing filesystems, different TWRP versions... bah. So much easier on non-motorola devices :)

I will figure it out eventually
[Moto G General] mmims24:
All I did was change radio 0x4 to 0x3, since you're running xt1028 just trying changing 0x4 to 0x2. Or I could send you a corrected zip file
[Moto G General] mmims24:
I want to take cm13 as is, from official thred and just add the one commit you linked to, however I don't have a build environment. Maybe [MENTION=4785615]inyourface09[/MENTION] try that cause the main point I've been making since cm team released official cm13 for falcon is that the siminfo that was present in /data/data/com.android.providers.telephony/databases/telephony.db on cm12.1 is blank in cm13. And I believe the commit [MENTION=3683732]mightysween[/MENTION] linked us to is what put the siminfo there.
[Moto G General] mightysween:
I will have my build environment set up as soon as I have a working device to look at. :)

Seems to be booting now...though been at the CM logo for a looong time. We shall see

---------- Post added at 02:13 PM ---------- Previous post was at 02:13 PM ----------

BTW, just delete the radio assert totally...much easier :)

---------- Post added at 02:15 PM ---------- Previous post was at 02:13 PM ----------

I am up and running... will try to get a build going before I head out the door. If not, it will be late tonight
[Moto G General] mmims24:
[MENTION=3683732]mightysween[/MENTION] if changing updater script doesn't work you will have to modify board-info.txt
[Moto G General] mmims24:
What do I need to set up build environment?