yashsingh1/xdaforums huggingface dataset:
[Nexus One Themes and Apps] britoso:
Yeah it was losing its LED paths, its fixed but my laptop BSODs when I conenct my N1... Will release 0.92 soon. For now just exit/start the app or save preferences again.
[Nexus One Themes and Apps] :
That might be the problem with mine as well? Lets hope.... I will give 0.92 a whirl when it arrives;)

JD
[Nexus One Themes and Apps] britoso:
Its not the same because your log shows the LED path it used instead of null.

For your issue I've got a couple of ideas

1) wait for about 100ms after turning on/off a LED

2) verify the LED turned off/on by reading the file.
[Nexus One Themes and Apps] :
I did another debug, i wonder, can you see anything bad in this?

JD;))
[Nexus One Themes and Apps] britoso:
Nothing wrong in that log, however I've noticed the amber/green getting stuck-on when locked.

Weird thing is that it never happens wen i'm connected via adb and monitoring the logs.
[Nexus One Themes and Apps] :
That's exactly my problem, it fixes on a colour when i lock the phone. Weird hey?
[Nexus One Themes and Apps] :
I must have a satan phone, lol
[Nexus One Themes and Apps] xanthumn:
britoso,

I have discovered a possible solution for phones with a limited number of leds to choose from.

On my Droid I only have red/green/blue to choose from, but I have seen other apps display purple/magenta, light purple, light blue, amber/orange at times.

With a little bit of testing using the command `echo 1 > ledcolor0/brightness ; echo 1 > ledcolor1/brightness` I came up with the following:

red + green = amber / orange

red + blue = purple / magenta

blue + green = light blue

red + green + blue = light purple

Root still required.

Perhaps this could enable more colors for us limited by only having a few led colors on our device.

Thanks for this wonderful app!
[Nexus One Themes and Apps] britoso:
I am aware of some of these combinations but they dont work the same on all phones. Maybe If I get time I can allow two colors to be selected for each threshhold and leave it up to the user to mix and match.
[Nexus One Themes and Apps] Andrewtst:
Thanks, :) I mean possibility to choose less than default 4 levels, example only 3 levels as I found the red is irritating due to it blinking issue.
[Nexus One Themes and Apps] leonnib4:
Too bad.

I think that was a good idea :)

Just saying... :D
[Nexus One Themes and Apps] britoso:
just configure it to do that.

0-5 blue

6-40 green

41-80 amber

81-100 amber
[Nexus One Themes and Apps] davelis828:
dont like it

i uninstalled but LEDs keep flashing

how do i stop that?

installed again to see if nothing happens,but instead LEDs flash and .apk keeps Fcing
[Nexus One Themes and Apps] britoso:
Uninstall it again since you reinstalled it.
[Nexus One Themes and Apps] davelis828:
didnt work,LEDs kept flashing

did NAND backup :mad::p
[Nexus One Themes and Apps] britoso:
if you exit the app using menu->exit and the LEDs are still flashing then maybe you have another app doing that
[Nexus One Themes and Apps] snudel:
Nope. Still fc.

I uninstalled 82 and restarted.

.91 installed after reboot. Trying to open. FC :(
[Nexus One Themes and Apps] davelis828:
nah,1st time using such an app,but thanx for your time man:)
[Nexus One Themes and Apps] britoso:
0.93 is out. Seems bug free :)
[Nexus One Themes and Apps] :
Britoso,

Still doesn't work for me, but i get new readings this time...

I get on the logcat...

I/CPUStatusLED(7204):onProgressChanged & a On Unbind reading;(

I cant understand what is not making this great app work;(
[Nexus One Themes and Apps] Mi|enko:
Awesome work man. I'd like to see anoption for signal strength via led (1 bar red, 4 bars blue, etc.). I think that'd be more useful than the cpu. Just my thoughts. :-)
[Nexus One Themes and Apps] britoso:
Well I'm monitoring my phone via wifi/adb and the LEDs are changing occasionally, but sometimes the monitoring thread does not check in (i.e prints CPU=X), after some time it starts working again.

Looking into that...
[Nexus One Themes and Apps] britoso:
Thought of that, but since the signal does not fluctuate much if you're in one place, the LED will appear stuck for long periods. Its theres more demand I'll add that as a menu choice.
[Nexus One Themes and Apps] leonnib4:
Is it me or JD has a Hell of a strange phone ? o_O

lol :)

Hope you'll finally be able to use this app correctly.

No bugs for me.

Thanks for your work britoso!
[Nexus One Themes and Apps] :
You have heard of the Jesus phones....

Well I have the Satan phone;) lollol

It works fine when i have the music on and the screen is locked, just wont work when i have the screen locked on its own. It needs an app to be running for it to run when the screen is off.

JD
[Nexus One Themes and Apps] britoso:
found out something.

The service uses a Runnable thread to check the cpu usage every 3 seconds. The OS does not fire off the thread on time when the screen is off. Don't know why.

I've tried (didnt work):

1. Changing the Runnable to a TImerTask

2. Increasing the priority of the process to high.

3. Making a custom thread call the runnable instead of relying on runnable.postDelayed()

on this page it says there is no guarantee that a message on the queue will be picked up.
[Nexus One Themes and Apps] :
Oh right,

So its an OS limitation?

JD
[Nexus One Themes and Apps] britoso:
I'm sure its possible, just need someone to point me at the trick :)

I know a custom 'Looper' may work but it seems complex to use.
[Nexus One Themes and Apps] Mi|enko:
Sounds good man. Can't believe I'm the only one that's requested this. lol As for the solid light, rather than making it solid I was envisioning like a 5 second query and just display a flash for signal strength every 5 seconds in correspondence. If I knew how to code, I'd take your source and do it myself. lol
[Nexus One Themes and Apps] :
Cool mate, well at least you know the issue;))

Im sure you will fix it, this app is super cool;)

JD
[Nexus One Themes and Apps] britoso:
Try to run the 'find' command on your phone.

Whats happening is that you dont have permission to execute 'find', therefore the program tries to run it as root using 'su'. Then it finds that 'su' was not found (tried to run 'id' as root and failed).

Interesting conundrum, your LEDs dont need root but the find command does. i.e the programs auto-detection routine fails because of this.

I'm adding hard coded values for the HTC desire.. please wait for the next release.
[Nexus One Themes and Apps] snudel:
permission denied. Damn
[Nexus One Themes and Apps] britoso:
try this. 0.94 added the 3 known desire leds.

edit: link removed, posted on the project page.

http://code.google.com/p/netmeterled/downloads/list
[Nexus One Themes and Apps] snudel:
This one works. Thanks
[Nexus One Themes and Apps] firerock:
This apps looks very interesting and useful! Just wondering how does the app affecting battery life?
[Nexus One Themes and Apps] snudel:
Not noticeable, if at all
[Nexus One Themes and Apps] Adminius:
Can I mix LEDs, for example blue+orange or blue+green?
[Nexus One Themes and Apps] britoso:
not yet, possibly in the future
[Nexus One Themes and Apps] Highland3r:
Getting FC's when accessing "preferences" - seeing the same permissions error on the "find" command in logcat.

Running rooted "stock" FRF91 build.

Has anyone else seen similar?
[Nexus One Themes and Apps] britoso:
haven't seen this, you're on the latest version right?
[Nexus One Themes and Apps] Highland3r:
Yup. Installed version from http://code.google.com/p/netmeterled/downloads/list.

Logcat data:

I/ActivityManager( 82): Displayed activity com.britoso.cpustatusled/.CPUStatusLEDActivity: 17293 ms (total 17293 ms)

I/CPUStatusLED( 2045): No saved preferences found

I/CPUStatusLED( 2045): Phone Model=Nexus One

V/CPUStatusLED( 2045): canSU() su[0]: uid=0(root) gid=0(root) ;

D/CPUStatusLED( 2045): Error in detectLEDs: exec: find: permission denied

I/CPUStatusLED( 2045): Found 0 LEDs!

I/CPUStatusLED( 2045): Shell = su

V/CPUStatusLED( 2045): canSU() su[0]: uid=0(root) gid=0(root) ;

I/CPUStatusLEDService( 2045): onCreate

I/CPUStatusLED( 2045): Phone Model=Nexus One

V/CPUStatusLED( 2045): canSU() su[0]: uid=0(root) gid=0(root) ;

D/CPUStatusLED( 2045): Error in detectLEDs: exec: find: permission denied

I/CPUStatusLED( 2045): Found 0 LEDs!

I/CPUStatusLED( 2045): Shell = su

I/CPUStatusLEDService( 2045): onBind

I/CPUStatusLEDService( 2045): onUnbind

I/ActivityManager( 82): Displayed activity com.britoso.cpustatusled/.CPUStatusLEDActivity: 3490 ms (total 3490 ms)

I/CPUStatusLEDService( 2077): onCreate

I/CPUStatusLED( 2077): Phone Model=Nexus One

V/CPUStatusLED( 2077): canSU() su[0]: uid=0(root) gid=0(root) ;

D/CPUStatusLED( 2077): Error in detectLEDs: exec: find: permission denied

I/CPUStatusLED( 2077): Found 0 LEDs!

I/CPUStatusLED( 2077): Shell = su

V/CPUStatusLED( 2077): canSU() su[0]: uid=0(root) gid=0(root) ;
[Nexus One Themes and Apps] leonnib4:
Do you have rot working AND busybox?

Seems to me find is not linked with find or root mess up
[Nexus One Themes and Apps] Highland3r:
Believe so yes. Root is working fine. Busybox (according to titanium backup anywho) is ok and version 1.16.0.

Pretty new to rooted android, so if i'm missing something or need to check elsewhere please let me know.

<edit> nvm, you were indeed correct - just installed busybox again and appears to have sorted the problem. Thank you kindly sir! </edit>
[Nexus One Themes and Apps] jullejul:
Work great on a HTC desire :)
[Nexus One Themes and Apps] teihoata:
Hey britoso maybe you can help me with a problem.

My LED light never turns off and stays a constant blue even when I do a full wipe. The light turns on immediatly when the phone turns on and is even on in the bootloader and recovery. it turns purple when it begins to charge however.

Using your app changes the color for a second but goes back to blue even when the cpu load doesn't change. I'm stumped :confused:

changing the brightness in the terminal to echo 0 doesn't seem to do anything either.
[Nexus One Themes and Apps] britoso:
Which ROM are you using?

seems like the blue LED is stuck on. do you get any other colors separately (no mixing) ?

The brightness file doesnt seem to do anything for the leds.

This app turns off all LEDs when it starts. check and see if the blue LED goes off.
[Nexus One Themes and Apps] teihoata:
I was first using enoms rom when it happened and I have now switched to the latest cyanogen nightly rom.

Yeah I've tried toggling the blue led but nothing happens. What's interesting is every 20 mins or so your app requests superuser. I don't know if that's normal lol.

I suppose I do get mixing. Can't seem to emulate a solid red anymore. Turns a cool purple.

Must be a hardware error huh. Thanks for your help
[Nexus One Themes and Apps] britoso:
Try getting a warranty replacement if its not too expensive.

Yeah whenever it loses its su shell and creates another one you get prompted. Better to check the 'always allow'
[Nexus One Themes and Apps] SiNJiN76:
Hmmm...is this app going to make me paranoid about the cpu usage? LoL! J/K I know it will. :D

using it now. Awesome!
[Nexus One Themes and Apps] snudel:
hehe no, it just makes others thinking you get constant emails/sms :)
[Nexus One Themes and Apps] SiNJiN76:
So when using this app...the charging light doesn't work anymore right? It's strictly for CPU usage?

I also get a light purple color once in while. Does that mean my phones about to take a dump?:p

Anyway, for those of you guys using this...what color do you see usually? I hardly ever see RED. Blue...a lot of Green...and mostly Amber...is what I see.
[Nexus One Themes and Apps] andi86:
Doesn't work, and force close when entering to changing parameters :(

Logcat when Enabling LED's:

Error in detectLEDs!

Shell = su

and Logcat when entering Preferences:

Shutting down VM

thred exiting with uncuaght exception (group=0x4001d7f0)

Device: Nexus One (Rooted with 1-click Root http://xdaforums.com/showthread.php?t=747598)
[Nexus One Themes and Apps] britoso:
can you launch 'su' in a shell/terminal?

Send me the stacktrace or some more of the locat.
[Nexus One Themes and Apps] andi86:
Thank you for your answer, attached you find a detailed log

su command in ConnectBot is accepted.
[Nexus One Themes and Apps] britoso:
Interestingly you did not have permission to execute 'find' even as superuser.
[Nexus One Themes and Apps] andi86:
So you think it's a problem of the 1-click-root?
[Nexus One Themes and Apps] jimbobalu:
I get the same denied permission and I also used 1-Click. Could it be the version of SuperUser V2.2.2?

Also, no custom ROM installed.
[Nexus One Themes and Apps] Highland3r:
Try re installing busybox.
[Nexus One Themes and Apps] jimbobalu:
Got Superuser 2.3.3 to install from the market on my 1-click rooted N1.

I had to first un-root my phone and then re-root with no superuser, I then went to the market and installed Superuser 2.3.3.

Looks like it is working as my root apps are working with no issues, even the startup apps like autokiller and setcpu work on boot. But the superuser app only gives me a blank screen when I open it.

I am still getting permission denied.
[Nexus One Themes and Apps] Highland3r:
Is that permission denied on "find" as per the log output above? If yes, try installing (or re-installing) busybox
[Nexus One Themes and Apps] britoso:
you probably need to install busybox, on my ROM find is linked to busybox.

Otherwise try to run 'find --help' in a shell and see if it runs.

# which find
which find
/system/xbin/find
# ls -l /system/xbin/find
ls -l /system/xbin/find
lrwxrwxrwx 1 root root 7 Aug 4 21:27 /system/xbin/find -> busybox
[Nexus One Themes and Apps] jimbobalu:
After un-rooting and re-rooting with 1-click 1.6.1 I got SU 2.3.1 installed and working but I still get find permission denied. I am a newbie so I haven't really delved into the deeper stuff.

I have re-installed busybox 1.16.0 using TI Backup, not sure if there is a newer version or how to install it manually.
[Nexus One Themes and Apps] RogerPodacter:
I've been having a problem lately with this bps. It works normal with the screen on. As soon as the phone sleeps with screen off the led stays green forever and does not update. When I wake the phone it starts working again. Any ideas?
[Nexus One Themes and Apps] britoso:
Yes I am aware of that. In sleep mode the OS does not reliably honor my 3 second timer. Probably a mechanism to save the battery. If I find a way around this I will update.
[Nexus One Themes and Apps] RogerPodacter:
Ok I thought it was something I did messing around with kernels. I'm on stock cyan 6 release now however. I wonder what significant changes were made that could have broken sleep mode. That's too bad cause this app is most useful to me to quickly see my CPU activity when the phone's sitting idle on my desk!
[Nexus One Themes and Apps] poochie2:
Feature suggestion: instead of changing color based on CPU usage alone, it could be based on average cpufreq of the last x seconds or a combination of both. What do you think?
[Nexus One Themes and Apps] snudel:
he is not doing something currently. seems he is satisfied and not adding new features.

still a great tool.
[Nexus One Themes and Apps] britoso:
hehe just yesterday I got an idea on how to make the LEDs change color when the phone is in deep sleep mode.
[Nexus One Themes and Apps] helterrskelter:
it doesnt work on my nexus one 2.2 froyo rooted, without custom firm
[Nexus One Themes and Apps] britoso:
Can you send me the stacktrace from your log?
[Nexus One Themes and Apps] stiCk.E:
very useful app. thanks heaps! lookin forward to updates :)
[Nexus One Themes and Apps] britoso:
v1.0 is out!

LEDs work even when the phone is in deep sleep mode.

http://code.google.com/p/netmeterled/downloads/
[Nexus One Themes and Apps] android01:
This app is brilliant! thank you so much for it ! Ive never seen my nexus go blue before. Would it be possible to modify it to flash random colors of the spectrum when a new text message or call is received perhaps? I know others apps do these sorts of things, i guess im looking for an excuse to keep you developing it =-) :D edit. or perhaps a bandwidth monitor mode
[Nexus One Themes and Apps] serg2k9:
One word, awesome!
[Nexus One Themes and Apps] britoso:
There are other apps for that, like blinker.

If you have more than one function tied to the LEDs then it can get confusing.

New messages and calls can use the trackball LED without any apps.
[Nexus One Themes and Apps] britoso:
TY, its something I needed and make maximum use of. Android is great :P
[Nexus One Themes and Apps] Mr.BUG:
Is it possible to add the choice between the processor load and gsm signal strength to your application? It will be great, if LED could blink in accordance with gsm signal strength.
[Nexus One Themes and Apps] britoso:
I could add that as its not too difficult.

Try this and see if it works for you, you can switch back to this app when you need to monitor the CPU.

http://xdaforums.com/showthread.php?t=744138

Personally I dont worry about the network strength as it changes pretty randomly ;)
[Nexus One Themes and Apps] Mr.BUG:
Thanks for the link, but that application is very buggy... Trackball blinks with the charging LED and with dissonance =))). It's impossible to change blink color and displayed buttons doesn't work, described functional doesn't work too. My request about your application is actual =). If you have some free time and some wish - it will be a great addon to your application. Best wishes.
[Nexus One Themes and Apps] britoso:
Deleted ...
[Nexus One Themes and Apps] android01:
I think traffic load pulses based on amount of traffic like router lights do would be a sweet addition for this. Think linksys LEDs

Awesome app thanks!
[Nexus One Themes and Apps] S_Dot:
Thanks.. how about disabling the graph pt option to? Seems like that would take a lot of CPU in the background.. also blink interval option would be nice too, thanks

Sent from a mobile device using Tapatalk.. from the future
[Nexus One Themes and Apps] britoso:
The graph is only displayed when the main activity is on-screen.

I think you mean the cpu polling rate (3 seconds at the moment), I'll put that in my list :)
[Nexus One Themes and Apps] Mr.BUG:
I've thought that it will be great if power LED blink in accordance with network signal and there is no necessity for add any functional to customize blinking colours. Let it blink with colours of cpu load, just change blinking frequency. It would be simple and useful.
[Nexus One Themes and Apps] arminsoyka:
Is it correct, that the App overwrites the red/green light from charging the phone? Im sorry if it said it in the past 30 pages, I didnt have the time to read it all.
[Nexus One Themes and Apps] britoso:
yes it shares/overwrites, so sometimes while charging you see colors like pink, light blue...

it turns off all the leds when starting and exiting.
[Nexus One Themes and Apps] britoso:
tested, works fine on gingerbread :cool:
[Nexus One Themes and Apps] omniwolf:
i seem to be experiencing this behaviour - when the phone is on the LED is usually blank unless i'm doing something, which makes sense. but as soon as i turn the screen off the LED will be blue, green, or amber. I have an HTC desire. What could the phone be doing? if i plug it into a charger and turn the screen off, then the LED will mostly stay off (which is expected). So it seems something strange is happening if the screen is off and the phone is not being charged.

My only thought is could it have something to do with how the phone will underclock the CPU when the screen is off (i assume that if the CPU is forced to run at 128MHz, then 100% usage is less meaningful than 100% usage at 998MHz). i did some testing and i can't seem to substantiate this - if i use SetCPU and force the CPU to min 128MHz and max 128MHz, the LED will still turn off when the phone is charging with the screen off, and if i unplug it with the screen off the LED will mostly stay lit.

i tried the opposite too - making set CPU have min 768MHz and max 998MHz, and with the screen off and the phone unplugged the LED will still light up a lot (a lot more than when the phone is plugged in with the screen off anyway).

i guess this might be a bit off topic (?), but this behaviour seems a bit weird. why would charging the phone make a difference? maybe if you're charging with the screen off it's not actually in sleep? but even then.. if i turn the screen on the LED will stay unlit. it's only almost always on when the screen is off (and not charging).

sorry about the long windedness of this post, it just seems that my phone is doing things it shouldn't and i wanted to get to the bottom of it :)
[Nexus One Themes and Apps] britoso:
When you plug in your phone the OS turns on the orange LED, CPUStatusLED will only turn it off when the CPU load reaches that threshold again and then drops down below it.

Good TODO to add.... listen for battery/charge events and turn off the charging LED soon after. thanks.
[Nexus One Themes and Apps] omniwolf:
hmm, i'm not sure if you understood my issue. my problem happened when the phone was NOT on the charger.

i'm not sure if it's related, but my phone also used up 24% battery over night last night, and it usually uses 11-12%. could be a coincidence, i'll try and do some tests to confirm.
[Nexus One Themes and Apps] britoso:
Are you on the latest version? there was a bug in the older versions where the app would not run once the phone entered deep sleep mode.

I've not seen my LED get stuck after that, only see occasional activity. At lower clock rates I imagine the cpu load will be a high (50%+) even for small tasks.
[Nexus One Themes and Apps] omniwolf:
yeah i'm definiely running the latest, i only discovered this app after v1 was out.

i disabled it (by opening it, then selecting exit from the menu options.. that disables it altogether (until you reopen or reboot), right?), and left my phone overnight, and i still used up 20% battery, so it must be something else draining it. sorry for pointing fingers :)
[Nexus One Themes and Apps] econwatch:
Kudos & Enhancement Request

Thank you for this great app (CPUStatusLEDv1.0) - am enjoying the clean interface and CPU profiling. No issues running on N1 w/ GB.

TIL - Have recently discovered the joys of battery calibration (N1 Battery Calibrator) and battery longevity re Current(mA) flow. Trying to get more than 6hrs b/w charges.

Read somewhere that GB reduced mA consumption overall but not seeing remarkable improvements so being able to view consumption on an app level would help narrow down the suspects. Currently at 140-160mA (min brightness, 2G, 2-3% CPU load).

Wondering if there's any traction for graphing mA per service through this app (or is there one avail already)?

N1 - update-cm-7.0.0-RC0-signed_010411_190413

a2sd - apps, dalvik
[Nexus One Themes and Apps] britoso:
thanks.

Doesnt GB provide a nice battery monitoring interface?

Battery graph shows a nice graph but it doesnt break it up by app/service.

Its not hard to add additional data sources and graph them, just need to know where to get that data from :p
[Nexus One Themes and Apps] timmyhxc:
is there anyway to make this app start at boot? also when i try to download the source i get errors. i may be doing it wrong though im new to all of this stuff.
[Nexus One Themes and Apps] britoso:
its supposed to start on boot, and has always worked for me. Any startup killers?
[Nexus One Themes and Apps] timmyhxc:
No startup killers or task killers here.

Im on a nexus one running cm7 nightlys

Im sorry, Silly me. App works great forgot i had it installed on the sd card, thus causing it not to start at boot.
[Nexus One Themes and Apps] britoso:
Ok cool, I had a similiar prob with widgets on the sdcard. (accidentaly set app preference to sdcard)
[Nexus One Themes and Apps] nucentury08:
Working great On Atrix 4G
[Nexus One Themes and Apps] britoso:
thanks, good to know.

If you see any LEDs not working let me know.
[Nexus One Themes and Apps] britoso:
bump, its now on the market:

https://market.android.com/details?id=com.britoso.cpustatusled

:)
[Nexus One Themes and Apps] tobyax:
nice app... works perfect on my N1 with cm7 stable