yashsingh1/xdaforums huggingface dataset:
[Hero, G2 Touch Android Development] erasmux:
It seems I was right and the USB tethering problem is not a kernel problem and the problem is as stated on post #1025 above.

I am attaching fixes for CM6/7, compiled against the latest CM6.2 and CM7.1 sources:

The attached UsbTetherFix_LV_CM6.zip should work for CM6-based ROMs like Floyo and Elelinux Speed machine. It might also work for other Froyo ROMs.

The attached UsbTetherFix_LV_CM7.zip should work for CM7-based ROMs like Elelinux 7.1.0. It might also work for other GB ROMs, especially ASOP ROMs. (Note, I have not tested this version at all.)

Please note: This will fix the USB tethering with the .35 kernel but will break it with the .29 kernel. Push the original /system/bin/netd from your ROM to restore the .29 tethering functionality.

I have tested the UsbTetherFix_LV_CM6 update on Floyo 1.4 (pre1) with the LX 0.5f version (from the 2nd post on this thread) and tethering my wifi connection works fine - Thanks perdita for the tip about tethering wifi :D.

Please me know, if tethering mobile data is indeed fixed by this or not.
[Hero, G2 Touch Android Development] erasmux:
I don't understand. Did you try it with a netd compiled without the BOARD_USE_HTC_USB_FUNCTION_SWITCH flag? What error are you getting when compiling what?
[Hero, G2 Touch Android Development] sotux:
I think we can upload this kernel to cm7 repo as hero's default kernel.
[Hero, G2 Touch Android Development] stefpaul:
Thanks for the help:D...works on the OMFGB rom (using the tether to write on the forum:d)...and i posted your work in the support thread that i made for the OMFG & OMFGB.

Stefan
[Hero, G2 Touch Android Development] perdita2000:
Erasmux, I mean compiling LV kernel from sources (github)... see post 969... I tried change kernel config (linux..type) and then I enable usb modem settings but can't compile bacause missing headers with that configuration...

Perdita2000
[Hero, G2 Touch Android Development] perdita2000:
Erasmux... Thanks man!!!,USB tethering is working fine!!!

This kernel flies...

Perdita2000
[Hero, G2 Touch Android Development] erasmux:
I am not sure I understand whats the problem. The current compilation of the .35 kernel, supports USB tethering in the "normal" way (like it is on most other devices). From my understanding HTC used this non standard "usb function hsusb" thing for our .29 kernels (and possibly a few other devices) and the CM sources where "hacked" to support this. If you look at the source:

a) The current .35 sources we are using don't have the code for the msm_hsusb/usb_function_switch. I am not sure what you where trying to accomplish by playing with the config but, at least I, can not find the code for this.

b) I checked for example the Froyo ASOP netd sources, and it only has support for the standard "usb_composite/rndis/enable" which our .35 kernel supports.

I think the current solution of just removing the flag from the BOARD_USE_HTC_USB_FUNCTION_SWITCH and recompiling the netd is the cleanest.
[Hero, G2 Touch Android Development] elelinux:
Yes I will do that but must test it first for a while. :)
[Hero, G2 Touch Android Development] erasmux:
I agree, we should test it at least a bit more. For example the "smartassV2" code is very new :). I would also like to release a new major version - just in terms of version number. The "0.5f" was just to give some numbering to my "test" releases. I would suggest either 0.6.0 or even 1.0 :D.
[Hero, G2 Touch Android Development] elelinux:
Yes I agree, much better with major version and proper version number
[Hero, G2 Touch Android Development] perdita2000:
a) I used standard procedure to change linux kernel config ?¿?¿ make menuconfig, change whatever need to be change, and then make new kernl... I tried to enable usb modem functions but as I understand, this option is related to host usb functions and that's not tethering usage on hero. I supposed tht's why msm_husb isn't on our kernel code...

b) In fact I never compile any AOSP, just CM ... Sorry about my poor knowledge. I supposed that usb_composite is the option I should look for on .config?¿?¿

Many Thanks For Your Amazing Work Erasmux,

I will use this kernel for some days to check battery usage and all other main use functions... In fact I just missed tethering on latest versions...

Perdita2000
[Hero, G2 Touch Android Development] riddick541:
Okay, I've tryed the new kernel for a bit. And I must say smartassV2 isn't friendly with music. After a minute playing music with my screen off, the music starts lagging. When I turn my screen on again the music starts to play normal again.

My screen off governor is 176/518 Mhz.
[Hero, G2 Touch Android Development] ggrammer:
try IncreasIng your screen off speed 176 Is kind of low for music.
[Hero, G2 Touch Android Development] erasmux:
Thanks for the report. This should not happened, possibly, I need to tweak the sleep parameters of smartassV2.

Which ROM and music player are you using? If possible, please check also without a sleep profile (I have no idea how that is implemented, but for sure smartass handles it better, especially smartassV2).

I am using Floyo 1.4pre1, smartassV2 @ 614/176 (no SetCPU profiles or such), and playing music with meridian is almost 100% smooth - but after you reported it, I do notice that it seems to stutters for me about once every 5 mins or so :(. I will look into it.
[Hero, G2 Touch Android Development] riddick541:
I'm using OMFGB 1.3.1-r1-B2 and mixzing as musicplayer. Its also happening without a sleep governor @ 256/690Mhz
[Hero, G2 Touch Android Development] Habarug:
I thought I should just say that with Elelinux Speedmachine and the lv 0.5 kernel (riemers from op) I have to use 710/245 Smartass to get smooth music, so i don't think it's your only :)

Edit: and I use the music player ^3 (search cubed music in market) :)
[Hero, G2 Touch Android Development] perdita2000:
I don't have any problem with 264/614 playing mp3 with default player ...

Perdita2000
[Hero, G2 Touch Android Development] ZyberXDA:
This sounds like a good kernel for my HTC hero, only I can't use it because I need usb tethering. Hope it will be added in the future:)!
[Hero, G2 Touch Android Development] erasmux:
See the second post:
[Hero, G2 Touch Android Development] riemervdzee:
The idea was that when everything was working, 1.0 was released. USB tethering is still something to think about tho. Will speak to you soon eran, got a bit bussy lately I'm afraid :-/ new job with ****load of administration
[Hero, G2 Touch Android Development] erasmux:
I have updated the second post with LX 0.6.0:

I hope I don't eat my hat, labeling this release 0.6.0 as if it is somewhat stable. A more final 1.0 stable release will most likely be done by Riemer when he has time for this.

The main difference from the 0.5f version is that the scheduler parameters have been tweaked to an extreme. I have done such a change and lived to regret it (in the FlyKernel 12 release), but this time I have changed the parameters to the complete opposite direction which make more sense :D.

Seriously, I would like feedback, does the new version feel different than the previous 0.5f version mainly in terms of responsiveness.

On the way (actually this is what I sat out to do in the first place), I have hopefully fixed playing music during sleep @ smartassV2 with a minimum frequency of 176Mhz. The situation should at least be much better if not 101% fixed.
[Hero, G2 Touch Android Development] Ciprilik:
@erasmux : I didn't get the chance to listen to music on 0.5f or to test it's performance too much but now on 0.6.0 I've been listening to music for about 1 hour and a half straight on my headphones (needed to clear my mind :)) with screen off using PowerAmp and no choppiness appeared during this time.
[Hero, G2 Touch Android Development] davrave:
I first used this rom all day yesterday with the default kernel.I'm using the 3Cubed music player. I did find the music a little choppy, so I installed "smartass v2" and I had no more problems.

Have not had any issues with that setup and installed LV 0.6.0 kernel this morning.

The rom actually feels smoother now with this kernel.

So far, I must say thanks to all the developers concerned with creating this rom.

Fantastic job to you all! Changed to LPro, as I found default "Launcher" sticking at times. I have yet to find a launcher that is as smooth as the stock HTC launcher. Great job. The rom really is exceptional, so far.
[Hero, G2 Touch Android Development] Ciprilik:
@davrave : This is not a rom it's a kernel that goes into the rom :D . But you probably know that and it's just a typo. :)
[Hero, G2 Touch Android Development] davrave:
Duuuuh! Sorry dude. Meant to post it in Eles' v3.3 rom page and I DO know the difference. It's like Kentucky, right!
[Hero, G2 Touch Android Development] Ciprilik:
Is anyone else having poor battery life like I do ? Good Battery life : 1 day or 2 with normal usage ... Bad battery life like in my case = ~5 hours of light to normal use. Maybe I need to finish calibrating my battery and it's life will be better ( I started this after my phone ran completely out of power) ... but I don't think so as % showing are just battery stats and they could be wrong but actual electricity in my battery doesn't care about the phone showing me correct values. I might be wrong tho and my battery needs to be formatted again. (started first steps of charging my phone turned off to 101% :) and wiped battery stats 1 hour ago.. gonna finish calibrating and come back with a new report :P)
[Hero, G2 Touch Android Development] erasmux:
I see a lot of complains about battery life, but not too much details.

Personally, I disconnected my fully charge phone last night (running Floyo 1.4pre1 w/ LX 0.6.0 @ smartassV2 614/176). Now 24hrs later, with very light usage - a few calls, about 20mins of music and some SMSes - I have 90% left. This seems like decent to excellent battery life (can't really test battery accurately over only one day).

If I am not mistaken all complains are using the Ele v3.3 ROM, I would ask that those who have very bad battery life:

a) Check their battery stats, what was using the battery the most?

b) Try to use a different kernel with the same ROM (i.e. the HeroKernel on Ele's first post or LV 0.5.0).
[Hero, G2 Touch Android Development] JieeHD:
I've actually noticed pretty bad battery drain across both of my CM7 based ROM's, reverted back to an older version of fly-kernel and it seems to have improved. So whether it's a kernel or ROM issue I'm not too sure yet. Your experiences with Floyo seem to suggest it may be a GB problem but obviously we need that tested with a wider audience.
[Hero, G2 Touch Android Development] erasmux:
Can you share the battery stats? The GB battery stats even have this very nice graph :D
[Hero, G2 Touch Android Development] JieeHD:
I'll get a graph today of my experience with CM7 and fly-kernel.
[Hero, G2 Touch Android Development] schlehdorn:
Hey erasmux,

thx for the new kernel. Responsiveness with smartassv2 is indeed better than smartass but i also get a lil worser batter drain. can get about 2 days out with writing about 200 sms per day and some facebooking :)
[Hero, G2 Touch Android Development] bharat_goku:
i seem to be getting good battery on this kernel running the speed machine v5 n i've lost about 39% battery in the last 12 hrs,wifi-bluetooth-packetdata-off,3 hrs of music+17 calls of about 2 minutes each+ninjump fr an hr+fiddling with the rom fr the rest of the time :P
[Hero, G2 Touch Android Development] DjoeN:
My battery live has gone from very good to poor since i come from Gingerbread back to Froyo. (under gingerbread i had a standby of 3 days (no calls, only checking mails 2x a day over WiFi))

100% to 40% in 7 hours standby and 1 call recieved (duration 5 minutes) and 3x checked my e-mail ((over WiFi) same settigns as under gingerbread)

Gonna do a battery reset when the battery is under 20% (never needed to do this in the past)
[Hero, G2 Touch Android Development] erasmux:
This is very weird, because some people (like me :p) are getting awesome battery life and many are getting very poor battery life :(. The differences are very extreme. Since DjoeN is also using Floyo (am I right?), or at the very least not the Ele v3.3 ROM, I think we can rule out its a ROM problem.

Now, since I do not suffer from this "problem", I need some help isolating the problem from those who do:

a) How is the battery life with FlyKernel (or HeroKernel)? How is it with LV 0.5.0? (I suggest you go back to the kernel which you last used and worked well for you and verify battery life is back to your normal)

b) Assuming you are now using smartassV2, can you test the battery using the exact same governor and settings which worked well for you with other kernels?

Thanks.
[Hero, G2 Touch Android Development] lohtse:
do we need this with 0.60 of this kernel???

Have floyo 1.4 and 0.60 kernel and as yet no issues with tethering via pdanet or wifi tethering either....

so unsure if to flash this or not!!!

also how to I activate/use smartassV2 govs??
[Hero, G2 Touch Android Development] erasmux:
Yes, if you are using any Las Venturas/x version (any .35 kernel) you need this fix. To the best of my knowledge, the two latest version from Elelinux (the GB v3.3 and the SpeedMachine v5) already include the fix, but for any other ROM you will need it if you want to do USB tethering. If USB tethering is working for you with this kernel you must have already applied the fix.

The smartassV2 governor is the default governor, so if you using version 0.6.0 and have not changed this, then smartassV2 is being used. Personally I prefer to use SetCPU to configure the governor and speed of my CPU (smartassV2 min 176/max 614 in my case), but you can also use the CPU Settings under the CM Settings -> Performance or other 3rd party apps.
[Hero, G2 Touch Android Development] lohtse:
thank you for the quick reply... As to fix nope never applied!!! And have been using floyo 1.4pre and lv 0.60 since they became available with no tethering issues!!! hmmmmm may be it works for a few days or so before issues arise or may be its a software conflict that starts it!? either way been using floyo since friday as with 0.60 of kernel and hero spends pretty much 60% of its life tethering to my netbook with no issues. Will not flash for a few days and see what happens and will report back..(have the all you can eat data plan on 3 reportedly 590gigs of data but more likely 80gig)
[Hero, G2 Touch Android Development] fancyhe:
Using Floyo1.4pre1 now, just switched from 0.5e to 0.6 yesterday. Noticed battery drain speed appears faster, while with 0.5e the battery life is perfect. Recharging now to see what happens tomorrow.

The frequency is tuned by CM setting menu, SMARTASSV2, 176/652, scheduler latency 2ms.
[Hero, G2 Touch Android Development] erasmux:
If you still see a big difference from 0.5e, can you please try it also with the same governor you used on 0.5e (default was "smartass"), does that make any difference? Also can you share a bit more details? What is you usage? What is the usual drain and what is the drain with 0.6.0?

EDIT: Btw, why do you set "scheduler latency 2ms", do you find this better than the default of 0.1ms? If so in what scenario. I know that the GUI (in the CM Settings) of Floyo 1.4pre1 does not support these low values - it will be fixed in the next version. In the meantime you can directly access it with sysctl:

# sysctl -w kernel.sched_min_granularity_ns=100000
kernel.sched_min_granularity_ns = 100000
# sysctl kernel.sched_latency_ns
kernel.sched_latency_ns = 100000

(100000ns = 0.1ms = default of 0.6.0)

Thanks.
[Hero, G2 Touch Android Development] fancyhe:
Thanks for the reply.

I don't remember usage in previous days. Here's what I got since last recharge:

10pm yesterday - fully charged to 100%

10pm ~ 12am - light usage, minutes of some applications using data & wifi. It still show 100% @12am

12am ~ 8am - no usage. Wifi was left on. 80% @8am

8am ~ 10am - MP3 playing around 40minutes, screen off at most time. 65% @10am

10am ~ 11:30am - few usage, just some SMS & Gmail. 60% @11:30am

11:30am ~ 12pm - no usage. now is 55%.

The battery levels may not be accurate since they are not actual numbers but the picture from theme :D

With 0.5e the battery can last over entire weekend (2 days). No heavy use during weekend however the battery life appears much better to me. Plan to switch back to 0.5e at next recharge to see what happens.

As for the latency tuning, choose 2ms because don't want to be that aggressive :D

Not sure what do you mean by "does not support these low values", I see CM Performance setting menu can support latency settings from 1ms to 1ms to 60ms.

Attached screenshots of battery stat & CM CPU settings.

Numbers behind the stat picture:

- Display 33%, Time on 52m 29s

- Cell standby 14%, Time on 15h 9m 54s, Time without a signal 6%

- Phone idle 12%, Time on 14h 17m 24s

- akmd 9%, CPU total 17m 22s (what's this?)

- Mediaserver 9%, CPU total 15m 54s

- Wi-Fi 7%, Time on 5h 32m 51s

- Android System 5%, CPU total 8m 45s, CPU foreground 1m 3s, Data sent 110.06KB, Data received 184.35KB

- XDA 5%, CPU total 8m 4s, CPU foreground 47s, Data sent 19.70KB, Data received 241.17KB

- Android OS 4%, CPU total 7m 56s, Data sent 7.46KB, Data received 189.55KB

View attachment 705552 View attachment 705553
[Hero, G2 Touch Android Development] waqasr:
have a Question!

I am coming from hero CDMA forums, We unfortunately do not have much

activity in our forums section for this kernel verison. Still waiting on some

one to port this over to CDMA Heroc kernel, I have asked a few people for

help but no avail yet. I am my self not savy enough to do it. I was wondering

if this updated kernel has fixed the gps and camera issues we are having

with our .35 kernel which is kind of out dated.

Thank you in advance.
[Hero, G2 Touch Android Development] jonathanljs:
On Elelinux 3.3 with 0.6 and despite checking the box to keep my CPU settings (176/710, smartassv2) on reboot, it resets to phone default every time (264/576, Ondemand) - and as soon as that goes to sleep, it won't wake up and it's pull the battery time! This was never a problem with the original kernel. A manual reset and all is well.

I suppose I'll try SetCPU, but I thought this should be brought up here anyway...
[Hero, G2 Touch Android Development] DjoeN:
Problem solved

- 100% to 91% in 6 hours standby with mail checking

Somehow i missed the brightness settings, it stood on full this whole time

and according to my infotool it uses 40% of the battery power in this mode.
[Hero, G2 Touch Android Development] erasmux:
The original .35 kernel which Riemer worked on, which I believe is the one the hero CDMA has, had some camera instabilities for us. As far as I know GPS worked fine with it. In any case, both camera and GPS work very well for us now. Do note that the camera driver between the hero GSM and CDMA is totally different.

Regarding, the "set on boot" not working, I assume that this is a ROM problem, as it works fine on Floyo 1.4pre1 (also w/ LX 0.6.0).

The "pull the battery time" problem seems much more troubling. Whether you are using ondemand, smartassV2 or any other governor you should not have such an extreme wake up issue. Can you revert to your previous kernel and test it there? What about LV 0.5.0 or LX 0.5f?
[Hero, G2 Touch Android Development] nscxp2005:
Hi erasmux,

With the latest version of the kernel am I able to use app2sd?

Thanks

NSCXP2005
[Hero, G2 Touch Android Development] erasmux:
Yes. The kernel supports ext2/3/4 so app2sd should work if your ROM supports and activates it.
[Hero, G2 Touch Android Development] erasmux:
Small updated posted:

I doubt you will feel any dramatic difference from the previous version (0.6.0), still I always prefer to run code which I didn't find it's bugs yet :p

I would appreciate any feedback about smartassV2, especially in this 0.6.1 version where I hope its code has finally matured. smartassV2 is the default governor, but you change it and compare with different governors, either using 3rd party programs like SetCPU (my personal preference), or when using a CM7-based ROM (or Floyo 1.4 or Speedmachine) you can also change it from the CM Settings -> Performance -> CPU Settings.
[Hero, G2 Touch Android Development] nscxp2005:
Thanks.

Do you know if there is a way to activate app2sd on CM7 Nightlies?

All the best,

NSCXP2005
[Hero, G2 Touch Android Development] jonathanljs:
I've been working my way through the Elelinux GB versions and LV0.5 was always a little unstable for me, so I would always switch back to Herokernel 12a (Ele kindly provides a zip to flash). I never had the set on boot not working before from CM settings - and now I've discovered that 3rd party apps don't hold the setting, either. On boot, I have to adjust the settings quickly before the phone goes to sleep and won't wake up..!

Anyway, I was using the old kernel till yesterday and never had this sleep problem - nor with my trials of LV 0.5. (Though of course I didn't go back to 264/576 Ondemand.)

No-one in the Ele GB forum has said they have this problem, but I don't know how many are trying LVx...

Anyway, I'll try the new version of LVx and see if it makes any difference. If it's still happening, I"ll try the Herokernel at lower speeds and see if it goes bye-bye as well.
[Hero, G2 Touch Android Development] erasmux:
It seems I have messed up a bit with the 0.6.0 release (and consequently with the 0.6.1 release which was pulled shortly after release because of this): My scheduler tweaks in that version seem quite awful - at least in terms of responsiveness with ADW launcher which I use.

Am I the only one who noticed this? :eek:

Another great "success" in this area, is that I went to a decent effort to add support for the HRTICK (in the 0.6.0 release) but never actually activated it....

0.6.2 fixes this, and I believe is much more responsive, possibly even the most responsive I have ever seen my hero.

Is it all in my head? Any feedback will be welcome :)
[Hero, G2 Touch Android Development] JieeHD:
We shall see.. :)
[Hero, G2 Touch Android Development] nscxp2005:
I keep having issues with connecting to my WiFi network.

It seems to have happened since I flashed the kernel.

Does anybody know how to fix this?

All the best,

NSCXP2005

[EDIT]

When I go to WiFi Settings, it says my WiFi is Disabled and Remembered.

It's very strange.

Please can somebody help
[Hero, G2 Touch Android Development] erasmux:
Describe the issues? What errors are you getting? logcat? Does it work if you restore the original kernel?

EDIT: You should be able to enable the wifi. If it gives you an error when trying to enable the wifi, try to reflash the kernel.
[Hero, G2 Touch Android Development] nscxp2005:
I reflashed the CM7 Nightly and the kernel and it seems to work now.

Does your kernel activate app2sd on CM7 Nightlies?
[Hero, G2 Touch Android Development] elelinux:
@Erasmux

v 0.6.2 It is really nice, can probably agree with you " is much more responsive I have ever seen my hero " :)
[Hero, G2 Touch Android Development] jonathanljs:
OK, have flashed 0.61 then 0.62... CPU now sets itself, and yes - everything is very, very responsive. Best I have known since purchase! :) Assuming all is stable from now on, I recommend Ele to incorporate in his next version of his GB version, to create the ultimate ROM!

Thanks for all the work!