yashsingh1/xdaforums huggingface dataset:
[Sprint  Galaxy Note 4 Android Development] drcrimzon:
It get's the phone type from frameworks/base/telephony/java/android/telephony/TelephonyManager.java

@SystemApi
public int getCurrentPhoneType(long subId) {

try{
ITelephony telephony = getITelephony();
if (telephony != null) {
return telephony.getActivePhoneTypeForSubscriber(subId);
} else {
// This can happen when the ITelephony interface is not up yet.
return getPhoneTypeFromProperty(subId);
}
} catch (RemoteException ex) {
// This shouldn't happen in the normal case, as a backup we
// read from the system property.
return getPhoneTypeFromProperty(subId);
} catch (NullPointerException ex) {
// This shouldn't happen in the normal case, as a backup we
// read from the system property.
return getPhoneTypeFromProperty(subId);
}
}

getITelephony returns 1 (gsm) instead of 2 when the phone first comes up. If you follow the code, this causes the phone to come up as LTE/GSM (Verified by going to Settings, About Phone, Status, and you have IMEI/IMEI_SV and no MIN/MEID).

If you look at a radio logcat, the phone comes up as phone type 1.

If you change the phone's preferred network to CDMA (PRL) , and wait for it to connect to 3g, and check logcat you see it re-run radio detection and switch over to phone type 2 (CDMA) (Also populates MEID, and MIN), at that point SMS works, and the network selection works as desired. You do not have to change to CDMA to fix it, any incoming voice call will kick it over to CDMA.

We (@spleef, [MENTION=3084704]nivron[/MENTION]) have been trying to figure out how to fix this, I have even tried with the code forcing the phone to CDMA, but it still comes up as PhoneType 1/GSM until it connects to 3G/CDMA/Voice call. Doing some comparison to some other sprint UICC phones to see if any of them have overrides (Like HTC M4 has a force to LTE/CDMA in it's ril.java), and maybe try something using USC RIL blobs since their device is working fine.

We have come up with some workarounds, but they are apparently tower/device limited as they only work on some phones. My thought is the phone is connecting to the tower as 3g before LTE thus forcing the cutover to CDMA.
[Sprint  Galaxy Note 4 Android Development] spleef:
new build up all cm sources (including kernel this time)
[Sprint  Galaxy Note 4 Android Development] DruoGaby:
nice..so this should run cooler and stuff??..cant wait to hear spen jammin man...also um...what about 4k recording with cam and wifi calling?...not rushing u guys or anything but i dont know if u were really aware being that u were focused on more important stuff
[Sprint  Galaxy Note 4 Android Development] AWildColin:
I had noticed this, but was too tired to mention it last night. What I've gotten in the habit is using Phone Info to set the network type to LTE/GSM/CDMA (PRL) if I notice my signal has dropped, which seems to be happening after every reboot. I also noticed that it switched back to LTE/GSM overnight and I missed a call this morning because of it (and it didn't kick it over to CDMA -- I still had to switch it over manually).

You'd think someone must have encountered this before on at least one other phone. I wouldn't be surprised if it's related to something in the RIL blobs like you mentioned, but this is a bit beyond my current programming abilities. Least I'm not the only one that's noticed it and is working on it. Thanks for all the work so far, regardless. I'll try fixing any other bugs I find.
[Sprint  Galaxy Note 4 Android Development] shanetheclassic:
I couldnt wait to try lollipop anymore so I finally flashed recovery and then this ROM.

Everything works great except there is no subscreen for the Folio cases. I really liked having the mini display through the front when my folio case was closed. I looked everywhere and couldnt find a way to enable it. It was a big enough deal breaker for me to go back to stock.

Is there some way to enable/download it?
[Sprint  Galaxy Note 4 Android Development] TGtheImmortal:
If you're talking about Sview that is touchwiz only and won't be available on CM (at least for now who knows.)
[Sprint  Galaxy Note 4 Android Development] DruoGaby:
mani love this thing!! but man this heating up ish is killing me!!..what do ido and 4k recording works with stock cam and im also able to use stock messaging with the "calland slideup to reply with text fix"..help!!

once i reboot the phone i have to do that trick every time..lol
[Sprint  Galaxy Note 4 Android Development] AWildColin:
While trying to remain civil and passive, understand that there are some expectations in any posts requesting help.

aside from being painfully incorrect grammar, does not meet this expectation I mentioned above. At minimum, please attach a logcat (a bug report would be better) along with the top three applications using the most battery life. If you're unsure of how to do this, there are various explanations found both on this forum and on the internet with step by step instructions

As a side note and some thoughts for the future, a detailed and grammatically correct post is more likely to elicit help. Good luck.
[Sprint  Galaxy Note 4 Android Development] DruoGaby:
oh im sorry sorry teacher..the phone is heating up upon my first boot...(raises hand) teacher?...is there some kind of fix for this...the phone is running about 60..stock runs like 32....i can deal with all the other stuff...i just never came across anyone asking about the wifi calling...and such..i only know about me..so if i offended u..im certainly not sorry..meh...just looking to see if i can look forward to this being a real daily driver...and here is the only plce to ask so..meh
[Sprint  Galaxy Note 4 Android Development] gruppe3942:
Really? Is that necessary??
[Sprint  Galaxy Note 4 Android Development] DruoGaby:
dont entertain it...just asking a few questions
[Sprint  Galaxy Note 4 Android Development] Decad3nce:
Can you guys post a full radio log from boot? I can probably ping slayher on irc as well.

What have been the effects of setting preferred network type in your device tree?
[Sprint  Galaxy Note 4 Android Development] undefined13:
First of all, thank you soooooooooo much! :good: Also, this is my first post on xda, although I have been lurking since the days of HTC 8525 and windows mobile 6. A few things I've noticed since I flashed the latest build (1/23 or 1/24 I think) had a few problems with Netflix but was able to solve it with the deleting of the DRM file mentioned a few pages back. Also had a problem with heat and battery drain. I checked the CPU freqs and my minimum range was set at 1.3 GHz so I set it to 300mhz and problem solved!

Also this was installed clean with full wipe x3.

Thank you guys again for all your hard work and dedication!
[Sprint  Galaxy Note 4 Android Development] Spark91:
After full usage from the 24th. All is stable and well. I'm not encountering any more issues now with this build.

Changed dpi to tablet mode ( 384 ) and redone capacitive keys ( backlight off, recents = back button and back button = menu ).

Now the wait for s-pen integration. A job well done, thanks everyone.
[Sprint  Galaxy Note 4 Android Development] lilmeanz:
Still using sms workaround?
[Sprint  Galaxy Note 4 Android Development] AWildColin:
http://pastebin.com/zFBjWh58. I manually toggled the network mode and radio using Phone Info a couple seconds before 19:02.

I'll leave it to drcrimzon et al. to answer the other question you had. I'm just learning you can set the preferred network type in the device tree and haven't tried building with it set yet. I'll try doing it myself tomorrow if they haven't by then and post back with an update.
[Sprint  Galaxy Note 4 Android Development] drcrimzon:
I've tried it with no real good results. I have tried at 8 (lte/CDMA) and whatever CDMA is. It would come up and never connect because android is saying the phone is gsm, so why even try connecting.

Trying a few last things tonight, then pulling all the documentation together and reaching out to slayher and other cm contacts.

The only real result I had was pulling uicc sim fixes it, but no Lte.

---------- Post added at 19:44 ---------- Previous post was at 19:38 ----------

Re: WiFi calling, its not on the radar yet, got a few other issues before we even think about looking at it. The fact I haven't seen any other aosp/cm sprint builds with it most likely means slim prospects for the time being.

Right now SMS/gsm issue and thermal / mpdecision / CPU issues are #1

Followed by spen and random reboots if thermal/mpd/CPU doesn't resolve.
[Sprint  Galaxy Note 4 Android Development] hermeticist:
For Wi-Fi calling, just use hangouts.
[Sprint  Galaxy Note 4 Android Development] malia420a:
screen record spleef?

btw, latest build has my note 4 running cool :good:
[Sprint  Galaxy Note 4 Android Development] ThatGuy94:
I just updates to the 20150124 nightly and my spen quit working on this build. It worked before on previous nightlies but it broke on this build though. I'm not sure if anybody else has had this issue, but I thought I would point it out
[Sprint  Galaxy Note 4 Android Development] hermeticist:
It doesn't work on the 12-24 liquid smooth either.
[Sprint  Galaxy Note 4 Android Development] pistolcity:
dumb question.

I saw undefined up there say he set his CPU frequency to a lower limit to reduce heat. I just installed CM the latest and it's great. device got warm while on the charger. How do I set the cpu frequency to a lower limit? I couldn't find the options myself. Thank you in advance. Everything else is perfect!! :good:
[Sprint  Galaxy Note 4 Android Development] malia420a:
Download Trickster from the play store and you can adjust it there
[Sprint  Galaxy Note 4 Android Development] pistolcity:
ok

ok thank you for that!! with the text messaging fix is that something you would need to do every reboot? Also, i am experiencing another weird issue. When someone calls my phone I hear a ring but it is not allowing me to answer nor giving me a notification. It will ring until I reboot. Also when i attempt to call out nothing and when I hit disconnect it just stays at hanging up.
[Sprint  Galaxy Note 4 Android Development] spleef:
thanks for the report back will look into it and see about building it again if there is something wrong

k a brand new 1/25 built and uploaded also removed the one from earlier so if you are downloading you will only see one 1/25 please let me know how it goes..thanks
[Sprint  Galaxy Note 4 Android Development] hermeticist:
Does the 1-25 build restore the use of S-Pen?
[Sprint  Galaxy Note 4 Android Development] spleef:
the changes for spen are included now if it fixed it idk for sure im not on it right now..am on broken right now trying to fix the button settings for the menu/recents button options

https://github.com/niv71/android_de...mmit/9d4a4148b1adc7551eca3b97311a002194bcb3d6

and

https://github.com/niv71/android_de...mmit/6ba9e0ca569b210d1bcd9635d5ffed31a05255d7
[Sprint  Galaxy Note 4 Android Development] hermeticist:
Thanks, is it fixed for liquid smooth as well?
[Sprint  Galaxy Note 4 Android Development] spleef:
i would say no before we include fixes to the others we incorporate them into cm then if its fixed we add it to the rest so until we can get confirmation if is fixed or not the others dont get included...thats the case most of the time...cm gets it all first then it trickles down stream since roms like liquid are cm based...now this is a bit different for slim and broken ...broken is based off slim so in turn the same goes for it ...once works in cm gets added to slim once works in slim gets added to broken...lol...i hope im making at least a little sense
[Sprint  Galaxy Note 4 Android Development] AWildColin:
Did a previous commit change the input device number in these configuration files or did something else change the number that it is linked to?

I'm still trying to figure out the difference between the lp and broken branches and what exactly is happening in broken. I believe I know enough where I could help fix some of these bugs, but I don't know what they all are. I didn't know there was an issue with the menu/recent apps button options.

---------- Post added at 03:44 PM ---------- Previous post was at 03:18 PM ----------

Never mind. Multiple ROMs on the same device tree. I get what's happening now.
[Sprint  Galaxy Note 4 Android Development] Spark91:
S-PEN isnt working but at least on 1-25 The reboot keeps LTE/CDMA, but SMS MMS Still require the CDMA to LTE/CDMA Switch method.
[Sprint  Galaxy Note 4 Android Development] spleef:
yeah like i posted earlier cm gets the changes then as we know if they work or not i merge them into the branches based off of the cm12 branch...each rom looks for its own items...like liquid looks for liquid.mk,liquid,dependencies...so i create a branch for each rom based off the cm12 branch.. so these changes can be made without altering cm..in fact i just went through and merged a ton of stuff into each branch...lol

its difficult at times to keep track of it all cause once i alter things to a point the merges dont go automatically and i basically have to delete the branch, then remake it, and then add back the individual rom changes ( which is what i just had to do...lol ).....but by all means if you have some input on fixing things feel freee to share you can always hit me or the doc up at any time we both answer all our pm's, emails, and hangout messages...evrything we do is open sourced and totally viewable on github nothing is a private repo...and we always welcome the help.....so far as liquid and broke go..with the buttons issue is a tough one to crack...for exaple...in cm and pac both have same options for buttons and the config.xml is set to 83 for them....which works for those nps..buttons changes as intended...but in liquid and broken having it set at 83 the menu/recents/ button changes dont work...ive tried changing the numbers to various increments and still come up with it not working...so its hard to track down the actual isssue since it works in one rom but not in a nother..and as we all know all roms share code...and in fact the liquid buttons and broken buttons were grabbed from cm so in theory the same number ( 83 ) should work for all
[Sprint  Galaxy Note 4 Android Development] spleef:
what about calls ? was reported an issue with calls so i remade the rom about an hour ago due to this issue is it working again?

also BTW idk if any of you remember xenonhd but its my next project...lmao...syncing up now already made the branches for it
[Sprint  Galaxy Note 4 Android Development] pstarkey001:
How about doing a Vanir or Wicked rom? That would be awesome.
[Sprint  Galaxy Note 4 Android Development] spleef:
are they updated to lp i can look into them
[Sprint  Galaxy Note 4 Android Development] pstarkey001:
I believe Vanir is but not sure about Wicked
[Sprint  Galaxy Note 4 Android Development] spleef:
yeah vanir is am looking up wicked right now

wicked not ready yet as far as i can tell https://github.com/Wicked-ROM/wicked_manifest/tree/lollipop
[Sprint  Galaxy Note 4 Android Development] pstarkey001:
yeah I see Vanir is credited on PAC
[Sprint  Galaxy Note 4 Android Development] AWildColin:
Is there a way I can add your device tree to a local manifest while keeping the CM project so I can cherry pick code changes without getting a fatal: duplicate path device/samsung/trlte-common error?

I'm more interesting in developing CM. As far as I'm aware, the kernel is what sets button numbers. I'd expect that there's a difference between the kernel running on liquid and broken compared to CM and pac that is causing the number the buttons are associated with to change between ROMs.

---------- Post added at 04:54 PM ---------- Previous post was at 04:47 PM ----------

I should note I was able to workaround this by editing the .git/config file under ./device/samsung/trlte-common and adding a separate remote. I'm wondering if there's a more accepted way of doing this.
[Sprint  Galaxy Note 4 Android Development] spleef:
im not sure if thats possible without renaming them so for instance can download both trhough roomservice..but redirect the path to one being kernel/samsung/cm_trlte and the other kernel/samsung/spleef_trlte..but once you build will have to rename it from cm_trlte/spleef_trlte to just trlte...also the kernel in my github thats labebled spleef/android_kernel_samsung_trlte is forked from cm but the one labeled spleef/android_kernel_samsung_trlte-zion is the kernel found in cmremix i do believe so basically that one is a custom kernel with lots of features

from what i gather about the buttons liquid and broken are using the cm kernel i listed above but the overlay/frameworks in trlte-common config.xml regulate that which the setting it has works n pac and cm but doesnt in liquid and broken which is strange so iv been p[laying around with broken in different ways which is why trlte-common broken branch looks totally different and has been altered to my attempts in fixing those buttons
[Sprint  Galaxy Note 4 Android Development] Spark91:
Ah yes, it has been fixed. And also don't push yourself too much whahahha. -thumb up-
[Sprint  Galaxy Note 4 Android Development] AWildColin:
That's what the consensus seems to be. Manually editing the .git/config file seems to work well enough.

[core]
repositoryformatversion = 0
filemode = true
[remote "github"]
url = https://github.com/CyanogenMod/android_device_samsung_trlte-common
review = review.cyanogenmod.org
projectname = CyanogenMod/android_device_samsung_trlte-common
fetch = +refs/heads/*:refs/remotes/github/*
[remote "public"]
url = https://github.com/spleef/android_device_samsung_trlte-common
projectname = spleef/android_device_samsung_trlte-common
fetch = +refs/heads/*:refs/remotes/public/*
[remote "private"]
url = git@github.com:AWildColin/android_device_samsung_trlte-common
projectname = AWildColin/android_device_samsung_trlte-common
fetch = +refs/heads/*:refs/remotes/private/*
[branch "github"]
remote = github
merge = refs/heads/cm-12.0
rebase = true
[branch "private"]
remote = private
merge = refs/heads/cm-12.0
rebase = true
[branch "spleef"]
remote = public
merge = refs/heads/cm-12.0
rebase = true

You can use that as a template if you want. If there's a bug tracker anywhere, that'd help me start. Otherwise, I'll just start looking at logcat errors and comments left by people here.
[Sprint  Galaxy Note 4 Android Development] AWildColin:
I don't know if it's worth mentioning, but I ended up trying to work on this today and after setting ro.ril.def.preferred.network to 10, it seems to have made some progress.

Initially, upon rebooting the first time after pushing the new boot image to my phone, I had a signal. I later noticed that I had left an erroneous space between the property name and the leading ". I removed the space, rebuilt the boot image, pushed it, only to find myself encountering the original problem again. After making sure what I encountered wasn't a fluke, I've noticed that it seems to have made some sort of difference. Once the phone has booted up and everything is still starting up, I still don't have a signal. However, I've noticed that after several seconds passes, the signal bar turns white for a few seconds, indicating I have a signal. Then it goes back to not having a signal.

Without knowing what exactly I'm looking for in the radio log, I can't say what is happening. I can take one from boot and attach it, if you want.

https://github.com/AWildColin/andro...mmit/68669fccf1aba3609cf06adfeb306473c671a789, for reference.
[Sprint  Galaxy Note 4 Android Development] frozeninferno:
Beautiful beautiful freaking ROM. I just can't get the data fix to stick, every time i reboot my phone or connect to the wifi i can no longer send text messages. Also, when I open the Play Store it constantly tells me that background data is disabled. Even though it is not. I am using the -spr version.

I also cannot update superSU wondering if that may be an issue because it is saying that root check has failed. Still trying to do anything and everything i can think of but i am no master at this, just doing things i have tried on other phones that have worked. I would love to continue running this but i don't how much longer i can keep doing this.

Maybe I have the wrong one DL'ed and it wasn't supposed to be the -spr one

Every time i connect to wifi it changes over to cdma/gsm Auto (prl)

Just trying to list any info i can that will help
[Sprint  Galaxy Note 4 Android Development] pbedard:
Data fix ?? I don't have data issues

---------- Post added at 07:25 PM ---------- Previous post was at 07:24 PM ----------

I don't have data or text issues on sprint
[Sprint  Galaxy Note 4 Android Development] frozeninferno:
I have data and text issues on sprint
[Sprint  Galaxy Note 4 Android Development] justinsch03:
s pen?

Does this release include the spend features or will we need to layer galaxy/TouchWiz on it?
[Sprint  Galaxy Note 4 Android Development] TGtheImmortal:
Same. Never had data issues.
[Sprint  Galaxy Note 4 Android Development] AWildColin:
I'm not sure if this has been previously reported, but I just missed a call even though I have signal.

Most of my calls come from Google Voice My laptop starts ringing before my phone does. In this case, my phone never rang and the call ended up going to voicemail. This could be unrelated to this ROM, but I still felt it was worth reporting.
[Sprint  Galaxy Note 4 Android Development] rwright64:
Nightlies are up on cm's site!
[Sprint  Galaxy Note 4 Android Development] Spark91:
Downloaded via cm updater, and 3 extra downloads on PC, flashed all 4 I downloaded and all had telephony and call/text issues so can't be a bad download, so I'll wait for the next nightly or to see if it'll get updated later today.
[Sprint  Galaxy Note 4 Android Development] rwright64:
Same here. Bummer.
[Sprint  Galaxy Note 4 Android Development] pbedard:
Bump lol sorry
[Sprint  Galaxy Note 4 Android Development] drcrimzon:
This mirrors what I have encountered in my quest to fix this issue. If you pull a radio logcat, you should see the phone type = 1, which is GSM. However, the phone is trying to connect to CDMA, without reading the MIN/MEID it cannot. I'm not sure what about letting it connect to LTE/GSM first and then kicking it over to CDMA does about getting android to re-evaluate the phone and switch over to Phone type = 2 and pulling the MEID/MIN.

I have tried fixing many different ways. I have tried setting the default network to CDMA, with preferred LTE/CDMA, and LTE/CDMA/GSM with no luck. I have hacked TelephonyManager to only bring the phone up as CDMA with no luck.

Another radio log would be great if you can post it. Can't get enough of those. Some people have no issues with this, which drives me crazy.
[Sprint  Galaxy Note 4 Android Development] AWildColin:
Ask and ye shall receive.

http://pastebin.com/iqJJ1PAf
[Sprint  Galaxy Note 4 Android Development] raregtp:
I also have not had any problems with data, texts, or calls. If a comparison helps I'll be happy to pull logs and share.
[Sprint  Galaxy Note 4 Android Development] AWildColin:
As a suggestion, you mentioned pulling the UICC card sets the phone type correctly (2). Perhaps it's being mistaken as a GSM SIM card, which is why the phone is identifying as a GSM phone? Given my slightly beyond mediocre programming abilities, you will probably be able to confirm this quicker than I can.

---------- Post added at 10:18 AM ---------- Previous post was at 10:14 AM ----------

I found this in that radio log before I switched it over to LTE/CDMA manually (@ 10:05)

01-27 10:02:50.957 E/RILD ( 326): First Ril

01-27 10:02:50.957 E/RILD ( 326): LoadLogLevel: Log level is 3.

01-27 10:02:50.961 E/RILD ( 326): RIL_Init: version(7)

01-27 10:02:50.961 E/RILC ( 326): RIL_register: RIL version 7

01-27 10:02:51.061 E/RILD ( 326): LazyRilInit

[B]01-27 10:02:51.061 E/RILD ( 326): LoadModelType() - phoneType: 2[/B]

01-27 10:02:51.061 E/RILD ( 326): SecRil(): ModelType: 4

01-27 10:02:51.061 E/RILD ( 326): Read esoc info /dev/subsys_esoc0 : HSIC
[Sprint  Galaxy Note 4 Android Development] pbedard:
U guys had it all perfect cm screwed it up ??