[ROM][CM12][TEST][falcon_cdma][xt1028/xt1031][INACTIVE]

Search This thread

mightysween

Senior Member
Feb 18, 2011
1,561
1,293
Maine/USA
Moto G Stylus
CM12 for XT1028 (Verizon) and XT1031 (Boost Mobile)
aka, the devices forgotten about by Motorola and CyanogenMod :)

tapatalk_1426622786069.jpeg
(screenshot c/o SykkNyzz)

UPDATE: 04-02-2015

With the goal of this thread having been solely to get 3g data working, it is "mission accomplished"!

There will no longer be a build posted here...please use individual build threads to download and discuss.

Thanks to everyone who helped bring working calls and data to the CDMA Moto G!

-----


VOICE: Working
SMS: Working (stock app broken)
3G DATA: Working


CONTRIBUTORS, LOGGERS, CODE JUNKIES, HACK N' SLASHERS & TESTERS
@Meticulus (data fix)
@crouse(original outgoing call fix)
@mightysween
@leeisme
@CodyF86
@amarc78
@SykkNyzz
@Awesomeslayerg
@russ722
@mbj731
@starkly_raving
@mistercheese
@hhp_211
@sugarbuger70
@classic757
 
Last edited:

mightysween

Senior Member
Feb 18, 2011
1,561
1,293
Maine/USA
Moto G Stylus
This is the workaround that @crouse came up with.

The original boolean values were changed so that we no longer need a SIM for the phone to initiate a call.

location:

/home/dev/android/system1/packages/services/Telephony/src/com/android/servic
es/telephony/TelecomAccountRegistry.java


Code:

*** // If we did not list ANY accounts, we need to provide a "default" SIM
account

******* // for emergency numbers since no actual SIM is needed for dialing
emergency

******* // numbers but a phone account is.

******* if (mAccounts.isEmpty()) {

*********** mAccounts.add(new AccountEntry(PhoneFactory.getDefaultPhone(),
false /* emergency */,

******************* false /* isDummy */));

******* }



******* // Add a fake account entry.

******* if (DBG && phones.length > 0 &&
"TRUE".equals(System.getProperty("cdma_sim"))) {

*********** mAccounts.add(new AccountEntry(phones[0], false /* emergency */,
false /* isDummy */));

******* }
 
Last edited:
  • Like
Reactions: tire_007

crouse

Senior Member
Jan 13, 2015
120
36
This is the workaround that @crouse came up with.

The original boolean values were changed so that we no longer need a SIM for the phone to initiate a call.

location:

/home/dev/android/system1/packages/services/Telephony/src/com/android/servic
es/telephony/TelecomAccountRegistry.java


Code:

oh good you found it, after that i got smarter and just made the subscription manager check if the phoneid and subid were >= -1 which did the same thing. everything does seem to actually work, but for whatever reason the code isnt finished / is missing what makes a cdma only phone ok. with a sim everything checks if the id's are >= 0 when with a cdma only its set to -1 .. idk if it makes any sense but thats what got it going

And in TelecomAccountRegistry.java in the setup accounts function check if the subscription id is >= -1 i instead of zero
 
Last edited:

mightysween

Senior Member
Feb 18, 2011
1,561
1,293
Maine/USA
Moto G Stylus
oh good you found it, after that i got smarter and just made the subscription manager check if the phoneid and subid were >= -1 which did the same thing. everything does seem to actually work, but for whatever reason the code isnt finished / is missing what makes a cdma only phone ok. with a sim everything checks if the id's are >= 0 when with a cdma only its set to -1 .. idk if it makes any sense but thats what got it going

And in TelecomAccountRegistry.java in the setup accounts function check if the subscription id is >= -1 i instead of zero


I noticed in looking through old logs that ConnectivityService seems to look for phoneid of -1000 when trying to bring up the network. Wonder why that is... shouldn't it be the same globally?

Need to pull some recent radio logs...

Sent from my XT1032 using XDA Free mobile app
 

crouse

Senior Member
Jan 13, 2015
120
36
I noticed in looking through old logs that ConnectivityService seems to look for phoneid of -1000 when trying to bring up the network. Wonder why that is... shouldn't it be the same globally?

Need to pull some recent radio logs...

Sent from my XT1032 using XDA Free mobile app

yeah, -1000 is invalid for phone id and some other things changing that makes the phone break completely
 

mbj731

Senior Member
Sep 13, 2014
215
54
I can confirm calls and SMS working on xt1031. I'll try to get some logs soon if that will help.
 

mightysween

Senior Member
Feb 18, 2011
1,561
1,293
Maine/USA
Moto G Stylus
Also, it may be helpful when taking logs to make sure WiFi is OFF so that the 3g network is attempting to connect. Then toggle airplane mode on, wait 10 seconds, and toggle airplane mode off and let it try again to connect. This may help expose more for us to examine.
 

kijp15

Senior Member
Sep 14, 2010
931
136
Hawai'i
I apologize, but how is someone able to send SMS if 3g data don't work or are you guys sending it threw WiFi?
 

mightysween

Senior Member
Feb 18, 2011
1,561
1,293
Maine/USA
Moto G Stylus

Great, thanks.

Right after RIL bringup we get SIM_COUNT=1

And then we end up with a bunch of failed inits and nulls because of incorrect subID.

I think we need a convenient way to "crowdsource" searching through source. Anyone able to upload raw telephony/ connectivity folder trees somewhere that everyone can participate in looking for relevant code?


Sent from my XT1032 using XDA Free mobile app
 

mbj731

Senior Member
Sep 13, 2014
215
54
Great, thanks.

Right after RIL bringup we get SIM_COUNT=1

And then we end up with a bunch of failed inits and nulls because of incorrect subID.

I think we need a convenient way to "crowdsource" searching through source. Anyone able to upload raw telephony/ connectivity folder trees somewhere that everyone can participate in looking for relevant code?


Sent from my XT1032 using XDA Free mobile app

I don't know anything about how this all works. But the "unexpected number of modems 0" line seems odd. Also, there's a lot of references to CDMA in the logs so it's somewhat detecting a CDMA device, maybe?
 

mightysween

Senior Member
Feb 18, 2011
1,561
1,293
Maine/USA
Moto G Stylus
I don't know anything about how this all works. But the "unexpected number of modems 0" line seems odd. Also, there's a lot of references to CDMA in the logs so it's somewhat detecting a CDMA device, maybe?

Yes, but it also thinks that this CDMA device is an LTE device... Because of the SIM issue.

The unexpected number of modems also reflects that it is requiring a SIM to establish a network socket.

if we can tell it not to look for or require SIM in the first place, these errors will resolve and we should end up with a connection

Alternately, we may be able to trick the system into thinking there is a SIM and then directing it to use NV manually... Probably a more likely fix right now.
 
Last edited:
  • Like
Reactions: russ722 and mbj731

mightysween

Senior Member
Feb 18, 2011
1,561
1,293
Maine/USA
Moto G Stylus
Notes, mostly to help keep track of what I have looked at:

Looking around here...this is where we need to be able to provide correct subid and introduce the possibility of there being no SIM at all. As noted earlier "sim count" is being returned as "1".

https://github.com/CyanogenMod/andr...nmod/setupwizard/setup/ChooseDataSimPage.java

So, before the Setup Wizard gets this far, we need to have established correct subscription and set simcount to 0 (even if it needs to be done manually for purposes of testing). Then call new function that takes proper info to establish data connection


This is probably where it will take place:

https://github.com/CyanogenMod/andr...ogenmod/setupwizard/setup/MobileDataPage.java


This shows that the only option right now for data is to either have one or two SIM cards, and if absent to route to a missing Sim page. Need to now look closely at Telephony Manager where SIM count is actually established.

https://github.com/CyanogenMod/andr...nmod/setupwizard/setup/CMSetupWizardData.java

subid relies directly on SIM and will not be set if SIM is unavailable:

https://github.com/CyanogenMod/andr...id/internal/telephony/SubscriptionHelper.java
 
Last edited:

crouse

Senior Member
Jan 13, 2015
120
36
Sim count coming back as one might be because of the changes I made, try an unmodified one and see what it comes back as
 

crouse

Senior Member
Jan 13, 2015
120
36
One thing I keep thinking would help is if someone with the first gen 4g version ( single sim ) posts their logs , with sim, without sim and with sim starting up and then removed. Someone posted at one point that if they started up with the sim in and then removed it everything worked fine with just the 3g CDMA radio but if started up without it they had the same issues we do.

---------- Post added at 09:55 PM ---------- Previous post was at 09:47 PM ----------

Here http://xdaforums.com/showthread.php?p=58766201
 

mightysween

Senior Member
Feb 18, 2011
1,561
1,293
Maine/USA
Moto G Stylus
Looking back at that thread, it seems that we never confirmed whether his phone was actually registering as CDMA and not LTE.

Mine correctly sets the radio technology as CDMA, but CellInfo shows that it is registered on the network as LTE, but without MCC...sorta like a 4g device with no SIM. This may be the root of why data fails, or just a symptom of the problem.

Since we can confirm that the network is in a ready state, perhaps preventing LTE registration may be a solution, but I am not sure there is a way to do that as long as the device thinks there is a SIM.
 

Top Liked Posts

  • There are no posts matching your filters.
  • 25
    CM12 for XT1028 (Verizon) and XT1031 (Boost Mobile)
    aka, the devices forgotten about by Motorola and CyanogenMod :)

    tapatalk_1426622786069.jpeg
    (screenshot c/o SykkNyzz)

    UPDATE: 04-02-2015

    With the goal of this thread having been solely to get 3g data working, it is "mission accomplished"!

    There will no longer be a build posted here...please use individual build threads to download and discuss.

    Thanks to everyone who helped bring working calls and data to the CDMA Moto G!

    -----


    VOICE: Working
    SMS: Working (stock app broken)
    3G DATA: Working


    CONTRIBUTORS, LOGGERS, CODE JUNKIES, HACK N' SLASHERS & TESTERS
    @Meticulus (data fix)
    @crouse(original outgoing call fix)
    @mightysween
    @leeisme
    @CodyF86
    @amarc78
    @SykkNyzz
    @Awesomeslayerg
    @russ722
    @mbj731
    @starkly_raving
    @mistercheese
    @hhp_211
    @sugarbuger70
    @classic757
    5
    Gave up on Drive... Uploading to Mega.


    Sent from my XT1028 using XDA Free mobile app
    5
    Data fixed! again... :good:
    @CodyF86: Your kernel changes are in there too... :highfive:

    Wooo! Lesgoooo! lol. Was starting to think we'd never see data on Falcon with CM12.

    No one has posted the obligatory NASA gif yet, so let me do it... =)

    2lxbih2.gif


    p.s. If anyone from XDA is actually reading this thread...this thread is the kind of stuff XDA is suppose to be about. I feel this thread deserves an XDA front page story. lol =)
    5
    If you don't mind, since it's Sunday and i'm sure everyone is bored...lol

    I can build cm12 real fast with that config overridden in the falcon device tree and we'll see what happens.

    Will be about an hour-1.5, someone else will have to test.

    Looks promising. :)
    5
    Data fixed! again... :good:
    @CodyF86: Your kernel changes are in there too... :highfive:
    I don't have a cdma device but happy to see great developer like you coming forward to help us to keep the development alive and i hope all these changes will be merged to other custom Rom's too so that cdma users enjoy every roms as per their taste. Good job sir and thanks for everything