• After 15+ years, we've made a big change: Android Forums is now Early Bird Club. Learn more here.

Root [MOD][SCRIPT] Enable/Disable soft key LEDS *6/14/12*

Looking at it now. gimme a bit; and I'll have it working.

Well, nevermind to that. Just use "Flashlight" on the market.
I tried looking through all the virtual info since logcat says it's a virtual, and still couldn't find anything that changed when the LED was off, or on...
Flashlight lets you turn it on while you do other apps, 'n shit, so that's the best option 'till playful, or shabby can take a look, because from what I'ev seen, there's not a file that controls our flash led...

Only thing I can even see in our entire rom pertaining to that LED is the actual hardware identifier info, and I don't know how to do anything with that on a shell script. I'm not even sure we can...
 
and for the record, I could very well make those folders, and put a script file in it, but ym system won't let me no matter how I'm mounted...so yeah...can't do that xD (not sure why it locked me out like that, but w/e
 
Well, nevermind to that. Just use "Flashlight" on the market.
I tried looking through all the virtual info since logcat says it's a virtual, and still couldn't find anything that changed when the LED was off, or on...
Flashlight lets you turn it on while you do other apps, 'n shit, so that's the best option 'till playful, or shabby can take a look, because from what I'ev seen, there's not a file that controls our flash led...

Only thing I can even see in our entire rom pertaining to that LED is the actual hardware identifier info, and I don't know how to do anything with that on a shell script. I'm not even sure we can...

Is there no flashlight folder inside the /sys/class/leds/ ?
On the esteem the flash folder is called "spotlight"
Also, is there no of hidden menu in the connect? With anycut I was able to access the flashlight as well using anycut
 
Is there no flashlight folder inside the /sys/class/leds/ ?
On the esteem the flash folder is called "spotlight"
Also, is there no of hidden menu in the connect? With anycut I was able to access the flashlight as well using anycut

There's a hidden menu but it wasn't included in the broken out rom lol
 
Is there no flashlight folder inside the /sys/class/leds/ ?
On the esteem the flash folder is called "spotlight"
Also, is there no of hidden menu in the connect? With anycut I was able to access the flashlight as well using anycut

no, I even went as far as scoping out the actions of the phone using logcat in debug mode, and searching for folders/files with flash, light, led, shine, cam, camera, torch, bright, abd a few other terms and couldn't find anything that even modified itself when the LED was turned on.

I've got NO clue what they did, but it seems that according to logcat the camera is an entire virtual operation, and with my experience in operating systems virtual operations, and operating systems are pretty much blocked off access wise. There's not many ways to read them.

So if the camera app (not the apk, but the PROCESS of it) is a virtual environment or controller, and all i have to go on is the actual hardware name of the LED (which I've yet to find either) I still don't know how, or if I could call on it with a shell script.

I DO know that the application "flashlight" works, and allows you to make a simple 1 click shortcut on your homescreen, so I think that's the better option than scouring for a month over something we can already do.
 
I should make this an app

It'll be complicated if you're new to app coding. You'll need to get su permission, wait for permission, reinitialize permission request, and force restart application if SU access isn't granted within the time limit applied by android. Then you code out the app making the changes, the widget, the graphics and framework res information, xml markup, etc. etc.
Not nearly as easy as what we did, and probably not worth the friggin' time.
 
followed all steps but got this:

pthVi.jpg
 
So does anyone know how the two files (brightness and max_brightness) in that sys/class/led/button-backlight folder are related?

In these scripts, we've been editing the max_brightness file. I've done some tinkering and found that the brightness isn't actually variable: it has to be either 0(off) or 15 (on). This file can be edited if the screen is on or off, and controls how the lights behave when the screen is turned on.

But what is this brightness file? When I read it with the screen on, its at 255. With the screen off, the file is at 0. It obviously is the file which records (or controls) the active brightness of the leds. However, I have found no way to edit it. When the device is on, any changes from 255 are not allowed and are instantly reverted to 255. Same for 0 when its off.

Does anyone know why this brightness file is uneditable? What is its relation to the system?

if we are able to toggle these lights with the device off, some very interesting options open up.
 
I hate to be a pest but can someone post a link for the toggle again. I got it working with two separate Widgets and I like the mod but to have a single toggle widget would be dope.
 
Back
Top Bottom