yashsingh1/xdaforums huggingface dataset:
[G2 and Desire Z Android Development] Shluggity:
I restored a nandroid of CM7 #15 and tried updating to #19 via ROM Manager and the call-drop issue no longer exists. However if I run the automatcher it reoccurs. I tried comparing MD5 fingerprints for the libhtc_ril.so and libril.so files but the files installed with CM7 #19 don't seem to match any of the files in the Automatcher.apk.
[G2 and Desire Z Android Development] schaggo:
Yes. The T-Mobile US G2 is AFAIK the ONLY device codenamed "Vision" which doesn't come with Sense. HTC Sense that is ;) All other "Vision" should be delivered with Sense or a branded version of Sense, which is Sense nonetheless.

While reading your post's I was about to post this: you're suggesting CM7 should only be used with a T-Mobile US radio then...? You got there before I could finish reading ;) Playing with your thoughts a serious question came up though:

how come that an identical software constellation on allegedly identical devices can produce such varying results? I do have that feeling that G2 and Desire Z are not completely hardware identical as widely assumed. Well of course they don't have the same radio transmitters, I know that, I mean there must be even more than just that...
[G2 and Desire Z Android Development] BRad Barnett:
The thing is, it isn't that identical. That whole SenseUI thing has tons and tons of changes. And we've seen that some of those changes are supported by changes in the support libs for things like the radio -- and that, the radio is likely different too.

(That is, if the radio needs to wake for SenseUI remote wipes, tracking, etc... )

But, the hardware is the same. Even the AM/FM radio is in the Desire Z....

Anyhow, yes. I think that for things to work right, we're going to all have to migrate to the t-mobile radio + rils, as we want to ensure that we're compatible with stock android -- and, since htc_ril.so is proprietary, we can't modify it to work with standard CM.

It's just easier (rather than making CM have custom code changes for strange htc_ril.so versions).

One thing. I'm wondering if the version of htc_ril.so is from the newest t-mobile rom? I'd assume so....?
[G2 and Desire Z Android Development] schaggo:
I didn't mean stock software, I meant G2's and Desire Z's with the same radio's flashed and exactly the same CM nightly flashed behave so differently.

I didn't change any internals and had insane battery loss overnight while others, the same radio, the same nightly, were just fine. Can't be. Maybe can but shouldn't.
[G2 and Desire Z Android Development] BRad Barnett:
Ah, yes. I was thinking about that.

The screen off thing for stock android turns off lat+longitude, and updates.

I know that I was using a sense radio, and didn't see the same battery drain that you're claiming. However, I have location by cell towers turned off. I only use GPS for location.

So, if you're using the network for location, that would be set off when the screen is off on a stock rom. You wouldn't get drain from the radio constantly checking location. However, if the radio for the Sense ROM goes to sleep differently, then if you have location by network turned on, it might constantly update your location, even with screen off.

The radio would effectively not go to sleep.

That's just one change that could be the cause due to Sense UI. There could be others.
[G2 and Desire Z Android Development] schaggo:
In fact I do use the network location feature. Because of a weather widget I use, I don't want it to use GPS to update since I work indoor. It would try to get a GPS lock where definitely no lock is possible ;) Hence network location, it's accurate enough for a weather widget. But the thought is absolutely valid and does make sense. Now if only HTC wouldn't respond with "sorry proprietary" (as they did, somewhere I read a user actually emailed them about the lib...).
[G2 and Desire Z Android Development] BRad Barnett:
That's ok though. Just use a t-mobile radio. It will work with rild, htc_ril.so, and your phone will go to sleep properly.

At least, that's the fairly strong working theory, that everything points to so far.

In truth though, there have been *three* radio updates for t-mobile. One might have been to plug holes we used for gfree and such, but I'm quite willing to bet that some of those updates incorporated improvements in the radio.

And, you can be sure that any bugs will be addressed with an update, for all G2 users too. So, it could be worse. At least this way, we have a very popular carrier, that will have updated htc_ril.so and radios for us...
[G2 and Desire Z Android Development] TrueYears:
I have stock sense using victorious kernel (the basic one) with radio .27

which radio in this thread should I use?

2011-01-27 26.06.02.27_M (Hutch AUS 1.85.861.3) (MD5: e699a37d4d7b9b26d5eaadf8e69be7dd)

why did this one get crossed?
[G2 and Desire Z Android Development] BRad Barnett:
I would say you want a t-mobile radio, but if you wait a few days this should all sort out...
[G2 and Desire Z Android Development] schaggo:
Well... *cough* to make things worse, GingerVillain heavily based on an older Pre-RC1-CM7 nightly runs perfectly well on any radio with or without matched libs. I did notice that GingerVillain includes a lib CM7 doesnt. Let me check real quick which one it is...

Edit: libreference-ril.so, found in GingerVillain 1.5 but not in CM7. It is among the recommended libs to exchange in the OP though...

And to make it even worse, previous nightlies, pre-#3 (the current numbering, so roughly 15+ builds ago) did all work nice as well and always have, on the stock radio my WWE-device had which interestingly was the same version the latest TMOUS radio was, 26.03.02.26...
[G2 and Desire Z Android Development] BRad Barnett:
Two things:

1) as for the screen hangup thing -- it will happen any time you use htc_ril.so from a sense rom. The only way it would not, is if CM's (and Google's!) version of the code in ril daemon (rild) was radically different in earlier versions. This is not the case, from what I see -- and in fact the problem with the hangup appeared the exact build where htc_ril.so was introduced from a sense rom, and disappeared when the old htc_ril.so was replaced

So, screen hangup problem is most certainly, 100% due to htc_ril.so from *any* Sense UI rom.

2) CM between 6.1.2 and 7.0 release is moving from one version of android, to another. There are quite a few changes. It is quite possible that older versions of Android did not as aggressively ping the network for location. There may be new 'features' of android, new reporting features, etc in Gingerbread, that .. even when you are not browsing or in Google maps, constantly updates your location and reports it to Google.

If that's the case, it would explain the difference in battery usage on older CM builds, using Sense UI radios.

--

I suggest we all run with a t-mobile radio, and see how it fares... a day or two will be a great beta test for this.

--

An additional thought. With CM 7.0:

1) new Google apps may no longer respect the OS telling them 'don't grab location info right now!'

2) CM 7.0 could have a bug (hey, it's beta, right?) that causes something to constantly try to request location

If either #1 or #2 are true, then the proper t-mobile radio + ril libs would mean that the radio would stop requesting location info with the screen off, no matter what the rest of the OS/apps wanted. However, with the Sense UI radio + libs, location would not stop with the screen off, and greedy apps / bugs would wear the battery down with screen off.

Again, the fact that the Sense UI constantly knows the location of your device, with screen off -- and, that we *know* that the sense UI htc_ril.so is different, and doesn't inform the radio the same way as stock android that the screen is off, means that it would be susceptible to excessive battery drain due to location pulls.

Of course, there are possibly OTHER Sense UI differences in the radios, that could also contribute to extra battery drain, just like this location issue!

Lastly, this could be expected behaviour!! It could be that at one point, the OS layer handled when location should be snagged by the radio. Perhaps that is handled by the radio now in Gingerbread!
[G2 and Desire Z Android Development] schaggo:
But then again, how come some do experience it and some don't? I never ever had a dropped call under any circumstances while using CM7, I did get excessive battery drain starting roughly around build 12-13-14. Others have it vice-versa, dropped calls but report fine battery usage. While being on the same radio I am and running the same lib's I do. At some point I even had lib's I extracted myself directly from a HTC Sense ROM (1.82.405) and no probs...

Don't get me wrong, no offence, but I think everybody was always talking of CM7 Gingerbread, I didn't notice anyone comparing Froyo CM6 with Gingerbread CM7 or am I wrong...? :confused:

+1! But with CM7 default libs or libs extracted from the latest T-Mobile OTA upgrade the radio came with...?

My sister runs a DesireHD, bone stock, untouched, with Sense of course. Now if you are refering to the "find my mobile" feature, it doesn't update in realtime, I think it only polls every 30 minutes or so, I'm not even sure it uses GPS, could be network only. I'd have to look into it first... Oh, and it doesn't by default, the feature has to be willingly activated and registered...
[G2 and Desire Z Android Development] rmk40:
Interesting stuff Brad, thanks for all the research.
[G2 and Desire Z Android Development] rhcp011235:
Great to see people looking into this. Its an issue for radio flashers. And who knows it might be an issue for stock radio
[G2 and Desire Z Android Development] jojo_16:
Actually this lib files fixed all my problems regarding call drop and data drop calls, the radio and lib files I was using doesn't go on the same radio, I changed it and it was all working good but I don't know where to put the libreference file I just pasted it on system/lib folder no issues tho maybe I was missing it the whole time.. question if I travel to asia do I need to change to asian radio?

EDIT: fixed domestic call drop and data drop, but international calls is still the issue
[G2 and Desire Z Android Development] schaggo:
No. The country referenced in the name means the sales region the radio is released for. It doesn't mean a device only works in X with radio X flashed... Imagine, business men flashing back and forth radios on long flights when switching continents... :rolleyes:
[G2 and Desire Z Android Development] tbalden:
Reading all the stuff related to ril and segfaults, its pretty scary to use any non official rom. Better checking logs or unnoticed battery hogs might occure.

Well, heads up, I'm currently using .17 radio and no matching ril, just vanilla cm7 libs and this is the first combo that gives me a normal wifi speed without abruptly falling back after a while (speedtest.net) till a reboot. Ill stick with this as the battery drains less to with wifi that way (using pershoots wifi module). European dz.
[G2 and Desire Z Android Development] dustrho:
Should that be the course of action going forward with flashing various radios, kernels and/or ROMs?

Thank you for working on this.
[G2 and Desire Z Android Development] martx:
So lets say I flashed the new AUS radio, flashed the matchmaker for the libhtc, radio didn't work out, and flashed back to stock radio. Would you still have the wrong libhtc?

Sent from a rock
[G2 and Desire Z Android Development] bongd:
I think it depends on where you downloaded it. If the radio has the appropriate libs then you'd be good to go. I'd run rmk40's automatic matching program just to be on the safe side. It's worked great for me.
[G2 and Desire Z Android Development] martx:
Thanks

Sent from a rock
[G2 and Desire Z Android Development] BRad Barnett:
Ok.

As a follow up to the discussion on pages 11-13.

http://code.google.com/p/cyanogenmod/issues/detail?id=3155

I would strongly suggest.. hell, I'll just say it. For all Desire Z and G2s, if you are going to be using any non-Sense UI rom (such as CM), stick with a non-Sense UI radio.

In other words, if you're using CM, on a G2 or a Desire Z install a t-mobile radio.
[G2 and Desire Z Android Development] BRad Barnett:
Please see my post. This myth needs to be dispelled. You are *not* ok switching radios, in fact, everyone needs to be running a t-mobile radio right now, with CM (and other non-Sense UI roms).
[G2 and Desire Z Android Development] rmk40:
At this point I have to agree, which leaves basically 2 radios for use with non-Sense ROMs.
[G2 and Desire Z Android Development] Vlad83:
Very interesting hypothesis, I am curious as to what Steve says (who uses/used 26.04.02.17 at one point). I've been on 06.02.27 and haven't experienced more than 2%/hr battery drain(comparable to my froyo setup), dropped calls/signal, nor any GPS issues that plagued some...
[G2 and Desire Z Android Development] EdKeys:
I've been using the AUS radio now for about a month and just recently updated the ril files with rmk's flash tool. I've had very good results so far, with stronger signal reception and faster switching between wifi, E and H networks. What "symptoms" should I look for/expect to see if your theory is correct? I'm running the latest CM7 nightly.
[G2 and Desire Z Android Development] BRad Barnett:
Hi guys,

Look, it's not theory at this point any more.

The reason I solicited a response from scotty2, is because he has ripped apart many of these radios. He's the guy that cracked the G2. None of you could even flash radios, if he hadn't managed to break the write protection on the emmc, via the radio.

So, he knows these radios inside and out...

If you still find all this strange, re-read his comments in the bug report. Re-read my comments.

There's nothing more I can do, although I hope this bug report to CM will end with a t-mobile radio install requirement.
[G2 and Desire Z Android Development] G1ForFun:
Placebo is a powerful thing.
[G2 and Desire Z Android Development] Vlad83:
I have read what you and Scotty wrote and not disputing the potential of adverse effects. However, it's not an absolute. I for one have not been adversely affected by the radio. Since we don't know the specific code of the radio nor HTC's proprietary libraries no one can state anything as fact. Don't get me wrong, I recognize the great potential of compatibility problems but once again from my personal experience the T-Mo radio takes a lot longer to switch from UMTS to HSPDA than the 26.06.02.27. Another instance would be 26.04.02.17 (which Steve uses) and up fixed majority of GPS folks experienced on CM7.

It should also be noted that Steve and Co wrote majority of the low level stuff for CM7 so that is also a variable that needs to be taken into account.
[G2 and Desire Z Android Development] EdKeys:
so is intelligence :D
[G2 and Desire Z Android Development] G1ForFun:
Which is why I feel these problems are arising.

Steve is using the Egypt radio...

Writing code that works for him on that radio.

So no wonder things are getting quirky. Seems like the CM dev team needs to all be using the same radio version for T-mobile US G2 (preferably the one that comes on the phone post ota unrooted) and a different but same radio version (again post ota unrooted) for the Desire-Z....Maybe have two seperate branches...
[G2 and Desire Z Android Development] bongd:
What did I say that was wrong? He didn't distinguish what he's running and it's not in his sig. I'm not going to write an essay about it.

But yes, it seems he will need to run a radio appropriate for the ROM he's using. Your work is appreciated, but no need to be snappy.
[G2 and Desire Z Android Development] martx:
Running the latest nightly and reverted back to the stock radio. Only ran the aus one for a day.

Sent from a rock
[G2 and Desire Z Android Development] sundar2012:
I think the solution here is - don't mess with the cm lib files on cm7. Flash wtvr radio gives us best signal/battlife but do not **** with the library files. I think that is sage advice for those on cm7.
[G2 and Desire Z Android Development] schaggo:
And again, I pose the question: what does libreference-ril.so do? Anybody has any insight on this?
[G2 and Desire Z Android Development] Vlad83:
Try searching for it in google's git.
[G2 and Desire Z Android Development] schaggo:
I'm not a programmer and do not understand code, but judging from what regular Google gave me: it's a sample implementation of a RIL lib by Google, creator of Android. Correct? The same as libhtc_ril.so but where as libreference-ril.so is the open source reference design by Google libhtc_ril.so is the proprietary closed source library written by HTC and specifically for the device it came on.

I do have a problem now. Since you are also a follower of the CM7 nightly thread, you might have already seen my latest uuhm... "contribution". I now realise that it doesn't make any sense that adding this file to a CM7 build would make the battery drain go away. What the hell does eat my battery then? And why did it get better all of a sudden? It drives me insane.
[G2 and Desire Z Android Development] Vlad83:
Yeah, you're correct about libreference-ril.so...

In regards to your battery drain, if you flash often you won't see stable battery drain. Try discharging your phone completely and recharging before use, then run it for at least 3 days to give you an accurate representation... Also, keep an eye on apps. For instance Word with Friends is a battery hog, even when running in the background...
[G2 and Desire Z Android Development] schaggo:
I am - out of personal curiosity since many years, brought to that topic especially by the, as manifested to the end user at least, poor resource management of Windows CE/Mobile since like 2002 - quite familiar with basic design principles of embedded and mobile systems. I am also a very active reader of all topics mobile IT and the likes. So I am well aware of all kind of applications which can possibly cause battery drain due to their nature. I do not run any application of that kind though, I use exclusively "static" apps without background processes (the aftermarket weather widget excused :p).

As for flashing often, I had a very good battery life a couple nightlies ago and I also flashed every night. But then there was a cut with one of the nightlies - I am trying right now to find out which one it was - and I was suddenly losing 20% an hour. Flashing over an existing nightly. Or with wiping. Completely formatting /system and /data and flashing afterwards, no, nothing helped I had consistent battery loss. And quite consistently 20% per hour. I went back to a very "old" nightly and the loss was gone. So it must be something which changed with one of the nightlies. As pointed out, I'm still trying to evaluate what it could be. My current guess: the jump from 2.3.2 to 2.3.3.

There's two reason why I'm so adamant about it: of course personal benefit :D but I also want to find out what's causing it, I don't believe I'm the only CM7 user which suffers from that.
[G2 and Desire Z Android Development] Vlad83:
Yeah, you are not alone in your assertion of worse battery life in 2.3.3 as opposed to 2.3.2 with CM7... But I've given up on any battery related discourse due to so many variable in play. There are members with identical setups but radical differences in battery consumption... Though 20% an hour would catch my attention as well.

Next time you are experiencing excessive battery drain open your terminal emulator and type

top -n 1

to see if anything is out of the ordinary...

Also, lets move this to CM7 thread so we don't highjack...
[G2 and Desire Z Android Development] Mikey:
So using the T-Mobile radio

2010-09-15 26.02.01.15_M2 (TMOUS 1.19.531.1)

would be the smartest move for T-Mo USA

or can we use the

2010-09-24 26.02.00.24_M2 (WWE 1.22.405.1)

as well.

CM7 nightlies
[G2 and Desire Z Android Development] Vlad83:
The conclusion they arrived at is the best radio to use would be T-Mo's latest which is 26.03.02.26. Though a lot of members including my self use 26.04.02.17 and 26.06.02.27 without a hitch. Some users have reported excessive drain coming from 26.06.02.27 however.
[G2 and Desire Z Android Development] Shaquiel Harris:
I as well use .17 as well with incredible battery life. Just a question, does .26 produce the same battery life if I install wipe Davik and what not? I'm willing to go back since I did arguably have better reception when using that radio. But ever since the switch to .17 I couldn't ask for better battery life.
[G2 and Desire Z Android Development] Shaquiel Harris:
Hm I haven't ran the .24 radio. Anyone else use that radio and report nice reception and battery life?
[G2 and Desire Z Android Development] Vlad83:
I am on .27 so can't compare. I have no problem with battery...
[G2 and Desire Z Android Development] Shaquiel Harris:
Ah ok I understand. Well your a lucky one. Hm I might try out .24 radio next before going back to .26. Guys I recommend that you use the auto lib matcher. It really does make a difference in battery life when you flash a Rom. Make sure to wipe dalvik cache before flashing the new radio and lib matcher.
[G2 and Desire Z Android Development] EdKeys:
I agree. I've been matching up the lib files with the auto matcher zip and its been giving me the best battery life since I've owned my phone.
[G2 and Desire Z Android Development] OFinch:
if I was to flash these libs files with my radio and tomorrow want to flash the eygt radio .17 (*I think) and the .17 radio lib files that's ok to do? I don't have to go on sdcard and remove anything? Is it just going to save over my previous? Also do I need to flash this Lib file each time I flash a nightly if I wipe cache? and dav cache? Thanks for everyones help. and thanks for creating this for users like myself :)
[G2 and Desire Z Android Development] tnpapadakos:
just an aside, but with flash 10.2 enabled, we're now able to use flash-based speed tests like these:
[G2 and Desire Z Android Development] pan_pietrek:
How do you guys match ril to radio versions? I'm asking because there are couple of users, who are experiencing exactly the same issues with CM7 nightly builds on HTC Wildfire and we haven't found a reliable fix so far (except for creating a new kernel, which may, or may not fix the problem).
[G2 and Desire Z Android Development] Vlad83:
You have to pull them from the rom/ruu the radio came with.
[G2 and Desire Z Android Development] theratdude64:
Sorry if it's been mentioned... but I've had some NASTY issues with my Radio lately, my phone heats up incredibly bad while using data, especially tethering. And just text messaging can suck my battery down 10% in 15 minutes. Can matching the RIL correct this?

I am finally able to be back on the computer and found the auto RIL matcher, THANK YOU THANK YOU, man XDA is awesome. I'm going to run that in a minute.
[G2 and Desire Z Android Development] Vlad83:
Tethering, especially through wifi will heat up and drain your phone, it's normal.