yashsingh1/xdaforums huggingface dataset:
[Galaxy S I9000 Android Development] accinfo:
Hey!

If you guys really really want the MOD, let's do something about it. AND I NEED ALL SUPPORT FROM EVERYONE.

Read Carefully.

I'm not sure if you've heard of PSX emulator or not. The author, zodttd, has started the project because he saw

So what I am thinking is, we should do the same thing too!

I have begun a petition. Now all I need is you guys to sign it. It's a really simple process.

Once we have enough signatures, we can show it to mods from other communities.

Petition

Thanks,

Clay
[Galaxy S I9000 Android Development] socket84:
Thanks man. Succesfull sign! Come on guys!
[Galaxy S I9000 Android Development] ZeCoder:
Thanks :)

Signed.
[Galaxy S I9000 Android Development] junglizste:
signed

000100101
[Galaxy S I9000 Android Development] NeoXTC:
signed :) need more signatures ppl
[Galaxy S I9000 Android Development] sl8125:
signed.

how many do you need?
[Galaxy S I9000 Android Development] Lenunited:
Signed, how many do we need?
[Galaxy S I9000 Android Development] jjwa:
Signed, of course :).
[Galaxy S I9000 Android Development] datagrid:
signed too :)
[Galaxy S I9000 Android Development] terrorblind:
Signed as well :)
[Galaxy S I9000 Android Development] poolcin:
Signed. Don't forget to confirm them :rolleyes: I found confirmation e-mail in the spam folder, so be careful.
[Galaxy S I9000 Android Development] Deedend:
Signed too! this could be a very good thing!
[Galaxy S I9000 Android Development] ariclung:
signed too, go go go
[Galaxy S I9000 Android Development] KaiF83:
signed too. 74 so far... We need more people!!
[Galaxy S I9000 Android Development] quangmach:
signed,its great to see
[Galaxy S I9000 Android Development] ikenley:
signed. let's get those numbers up.
[Galaxy S I9000 Android Development] Ryyuu:
Signed!

We are up to 106 Signatures!
[Galaxy S I9000 Android Development] tomolewis:
signed
[Galaxy S I9000 Android Development] Kolemar:
Signed...

Hope this is going to happen. It´s really one of those things that are missing from this super phone..
[Galaxy S I9000 Android Development] bjorkis:
Signed!
[Galaxy S I9000 Android Development] el__santo:
Signed
[Galaxy S I9000 Android Development] tschmidt84:
signed! this looks promising!!
[Galaxy S I9000 Android Development] dj_aleks:
I´m game, really useful thing!
[Galaxy S I9000 Android Development] KhaaL:
Signed :-)
[Galaxy S I9000 Android Development] fredphoesh:
please no OT petition requests

Guys, this is a bit annoying, the last 3 pages of this thread taken over by something that is totally OT... some (like me) would call it spam!

Please do not Hi-jack threads to promote your cause, it's not good forum manners and is against XDA rules.

I'm very interested in this notification backlight thing, sounds like it would be a GREAT addition... thanks to those of you that are working on that!

Tx

Mark.
[Galaxy S I9000 Android Development] soraxd:
signed

.
[Galaxy S I9000 Android Development] Andrjuhin:
Signed! I hope, it will be very soon!=) If you need testers, I'd like to be the first=)
[Galaxy S I9000 Android Development] dex1701:
I'd like to politely request that people stop posting "signed" in this thread. I keep coming back thinking there's actually something happening here, when really it's just people posting "signed."

It would be a lot more useful to add a poll to the OP rather than filling up the thread with "signed."
[Galaxy S I9000 Android Development] bladerunner0427:
I'm glad someone is already working on this. The idea came to me yesterday when I got my Samsung Vibrant for TMobile. I was looking for an LED notification light and realized the phone didn't have one. Major bummer. I'm hoping this could be an app. I don't really want to root my new phone. I have no problems with rooting. I have a rooted G1.
[Galaxy S I9000 Android Development] ash99:
Signed.

176.
[Galaxy S I9000 Android Development] xfox:
hope this works out
[Galaxy S I9000 Android Development] madmack:
Ok, I've tampered with different files to try to activate the backlights of our capacitive buttons.. I had two previous android phones, I was able to do that task in both phones by modifying a file called "brightness" to include numbers (0 for off, 1 or 255 for on) to get the backlights of these LEDs to turn on and off.

The naming scheme and "brightness" file is usually easy to find by browsing through /sys/class and figuring out what folder corresponds to which device. I think the biggest candidate we have here is melfas-touchkey. Even though someone else tried to cat that file to see what it contained with no luck (Samsung might've protected them with some other method that am not familiar with, given that I couldn't cat it even with root), I actually was able to overwrite values to these files by simply echoing 0 or 1 to the file. We probably cannot read the file, but perhaps we can write to it? That however, didn't get the lights on but I think we're close.

I also ran a search in all subdirectories under /sys/class for "brightness" files and catted them all to see their values and effects. I was able to get the screen turn on and off by changing the values in "brightness" under the lcd directory.

I will keep playing around with these folders and post any findings here.

What we could also do is run a program that monitors file access on these directories/subdirectories and see what files get modified when the LEDs get turned on.

I also want to warn you guys that I had a friend who used his capacitive button's backlight as notifications and his lights went off after about a month of use. I think we should be cautious to the time values we set these LEDs to turn on/off to, they are simply not made to flash or blink continuously for prolonged periods.

Lets get this going !
[Galaxy S I9000 Android Development] madmack:
Found a bug in the drivers that might be useful.

if you cat /sys/devices/virtual/misc/melfas_touchkey/touch_version while the phone's screen is off and then go ahead and touch one of the capacitive buttons, they'll light up and stay that way until you wake the screen up. dmesg is flooded with "touchkey is not enabled.W" which I only found to exist in cypress-touchkey.c

I tried echoing numbers to enable_disable and brightness after that step to no avail. Although it might be worth mentioning that dmesg prints the numbers I echo to brightness. For example, "echo 255 > brightness" will give a dmesg "touch_led_control: 255"

I'm done for the day, will appreciate if anybody has any input on this. :)
[Galaxy S I9000 Android Development] teknx:
This point should not be overlooked. I noticed on my vibrant that the capacitive light buttons are somewhat bright and I wouldn't be surprised if they get burnt out from overuse.

With that being said, I think once the button light issue has been figured out, the buttons should not light up all at once with the regular on and off pattern. A successive pattern from left to right for example would use less battery and hopefully avoid burning them out the lights compared to lighting them up all at one time in intervals. The successive pattern would also look much cooler in my opinion.

Thanks for the helpful info madmack and for keeping us updated.
[Galaxy S I9000 Android Development] gTen:
There is also another alternative possibility for notifications:

http://xdaforums.com/showthread.php?t=727057
[Galaxy S I9000 Android Development] fabis_htc:
Great idea!!!
[Galaxy S I9000 Android Development] gTen:
NICE! Thanks a lot! I was playing around with it on the Android emulator but don't have a device to test on so it makes it harder :(

As for suggestions, we made a few more in that thread about using the proximity sensor and light sensor to conserve energy when possible...also about letting the cpu idle..

But either way great job!

You should probably make a separate thread for it so more can see it and maybe get a sticky..
[Galaxy S I9000 Android Development] Unimaginative:
A huge thanks to you madmack. This works a treat.
[Galaxy S I9000 Android Development] teknx:
Awesome job madmack. I never thought we would get an app like this so soon. It hasn't even been a week yet!

I think we need to do some extensive testing to see how much or little battery the black screen and 1 red dot uses. If it is very very minimal then maybe we can work with a few ideas to improve things in terms of presentation.

As far as testing goes, I think a good way to test it out would be to record the battery percentage before getting a msg, then have the black screen and red dot come up, and leave it there for an hour(or more, maybe even over night) and see how it affects the battery life.

Current bugs

- Does not work in vibrate mode

Suggestions

1. 1 dot for each missed message, they can be grouped together in a box like sequence so it is easy to count while the dots move to random positions on the screen.

2. Different color dots for different kinds of notifications i.e. calls. So for example, after the color red we would use the next color that drains the battery the least like blue for a missed call.

3. Keeping the random positions of the dots possibly within the first top 10 horizontal and vertical pixels , so as to give it a look of a real LED notification near the top of the phone. Hah, i just realize the super amoled screen is so black, from far away the red dot actually looks like a LED (awesome)

4. If battery life isn't too much of an issue, we can introduce periodic animations to get the user's attention better than a static dot.

5. Ensure compatibility with popular sms apps like Handcent and the No Lock app which allows people to bypass the lock screen after pressing the unlock button. (right now it seems to work with hand-cent okay)

what does everyone else think?
[Galaxy S I9000 Android Development] Pneumatic:
I am impressed that this has taken shape so quickly. You guys are amazing.

My opinions on the program (if it matters)...

I don't care about the number of messages missed (one is enough for me to check it out) so the grouping of dots would be unnecessary in my opinion.

I do like the idea of different colored dots if it has no great effect on the battery. For me a missed call takes priority over a missed email so it would be nice to be able to tell the difference.

I don't know how AMOLED works. Is it possible to "burn in" an image on the screen? If so, the placement of the dot will definitely need to be spread out and maybe even within the same notification. It might not cause a problem but having it flash all night in the same position would make me nervous.

Thanks for working on this! This is precicely why I like Android. :)

I would prefer that it does work with "no lock". :)
[Galaxy S I9000 Android Development] teknx:
We should also think of a name for this app. I'm pretty sure the vibrant isn't the first android phone without and LED and it might not be the last, so other non-vibrant users might find this helpful. Here are some names to get the ideas rolling

- NoLED

- Dark Light

- LED Dead Redemption

Perhaps if we come up with one that madmack likes, then he can start a new thread for this app with that name.
[Galaxy S I9000 Android Development] madmack:
Thanks guys for the feedback ! am glad many of you found it to be useful.

I really hacked something together really quick because I'm so used to looking at my phone to see if I missed anything and couldn't do without that feature.

I just upped a modified version that shouldn't rotate the dot when you rotate the phone.

As for the suggestions, if I get more time, I'll look more into conserving energy because so far I'm holding a lock which I believe keeps the CPU awake. More energy analysis is needed I think.

Otherwise, the notification currently will not work with missed calls. The way this app works is that it monitors the notification sound files for activity when the screen is off. If one of them is played, the notification is launched. I don't think android plays any notification sound when there is a missed call. I'll try to work around this, most likely we'll have a blue or green dot to represent missed calls, and a red dot to represent all other notifications.

I'll also look into fixing the notification not firing up when the phone is in "vibrate" mode. These audio files are not accessed in this mode, thats why the application doesn't launch the notification screen.

Thank you for the feedback. I agree that we need a nice name for this app. FoldMod is so hacked together, lol. I'll continue working on this for a day or two and then will have to stop til August (Holidays !! :))
[Galaxy S I9000 Android Development] gTen:
If your gonna go with different colors best to go with shades of RED..if not...IF IT REALLY has to be another color Green would probably be 2nd choice...

Ideally is to let the user an option to pick their own image for the notifications while having preloaded the most energy efficient ones.

As for testing..it has to be a static testing period..example: 3 hours after 100% charged.

There should be no burn in on AMOLED, well at least permanent one..
[Galaxy S I9000 Android Development] duplico:
"echo 1 > /sys/devices/virtual/misc/melfas_touchkey/brightness" will turn ALL the lights on; echoing 2 will turn them all off. Looks like the screen has to be on, however. You do not need to be root.

You can't read from the brightness attribute because a sysfs show() method for brightness is not implemented:

Line 637 of cypress-touchkey.c reads: static DEVICE_ATTR(brightness, S_IRUGO | S_IWUSR | S_IWOTH | S_IXOTH, NULL, touch_led_control); so show() is a null pointer, which obviously will not read the state of the lights.
[Galaxy S I9000 Android Development] madmack:
I came to the same conclusion, thing is, they do check whether the the softkeys are enabled before they light up with if((touchkey_driver == NULL) || !(touchkey_enable==1))

I couldn't find a way to set the enable_disable attribute although the function and driver attribute are there: "enable_disable" and "static ssize_t touchkey_enable_disable(struct device *dev, struct device_attribute *attr, const char *buf, size_t size)"

They do get enabled when the screen is on. And once it is on, I couldn't figure out a way to disable them.
[Galaxy S I9000 Android Development] fredphoesh:
AGREED!!!!

Its out of place and rude to be using a thread like this to petition for something different. Really bad manners. Please stop it!
[Galaxy S I9000 Android Development] jgclifton:
I've seen apps such as launcherpro display missed notifications in the dock bar - could the same method not be used for this? Then I'd assume there would be no issues when on vibrate etc. Great work so far!
[Galaxy S I9000 Android Development] darksnarfer:
Just found the same thing yesterday, and was going to make a little app to turn the led on/off, until I discovered it doesn't work with the screen turned off.

Also, which source file are you guys looking at? I found two files almost identical, linux-2.6.29\drivers\input\keyboard\melfas-touchkey.c and linux-2.6.29\drivers\input\keyboard\cypress\cypress-touchkey.c. I believe that the one currently used by the ROM is the cypress one. If you do a cat /sys/devices/virtual/misc/melfas_touchkey/touch_version and then take a look at dmesg, you will see it outputs touch_version_read 0xa9 (or something similar). Look at the function touch_version_read in both source files and you will see that melfas-touchkey.c doesn't "printk()" anything but cypress-touchkey.c does.

I'm currently trying to enable the touch keyboard without waking up the entire device, but no luck so far. If you look at the cypress source you can find this function to enable the keyboard:

static ssize_t touchkey_enable_disable(struct device *dev, struct device_attribute *attr, const char *buf, size_t size)
{
#if 0
printk("touchkey_enable_disable %c \n", *buf);
if(*buf == '0')
{
set_touchkey_debug('d');
disable_irq(IRQ_TOUCH_INT);
gpio_direction_output(_3_GPIO_TOUCH_EN, 0);
gpio_direction_output(_3_GPIO_TOUCH_CE, 0);
touchkey_enable = -2;
}
else if(*buf == '1')
{
if(touchkey_enable == -2)
{
set_touchkey_debug('e');
gpio_direction_output(_3_GPIO_TOUCH_EN, 1);
gpio_direction_output(_3_GPIO_TOUCH_CE, 1);
touchkey_enable = 1;
enable_irq(IRQ_TOUCH_INT);
}
}
else
{
printk("touchkey_enable_disable: unknown command %c \n", *buf);
}
#endif
return size;
}

But unfortunately it does nothing as there is a conditional compilation comment so that code was never compiled. Odd enought, in the melfas-touchkey.c the same function is not commented :confused:

Any ideas?
[Galaxy S I9000 Android Development] Lenunited:
How can you just test, code.

I would like to go ahead trying to compile some code without acutally trying it on my phone haha
[Galaxy S I9000 Android Development] hAmpzter:
I will probably have my SGS tomorrow and I would love to test some of this..

Though I might hold on a couple of days before I root and stuff, but I think this would be a neat feature.. Though best if it would be a service/application you can install without root... But maybe isn't possible..

I have though never tried to develop for Android... Though the environment is installed at least! ^_^

Is there any SVN och GIT where I could get the current project and try to see what I can find?
[Galaxy S I9000 Android Development] pelo1986:
Hi Guys!

Any news?!

I'm waiting thi mod to buy the phone... :o
[Galaxy S I9000 Android Development] duplico:
Definitely in agreement that the code getting executed is in the cypress file, and also pretty sure that the code to support enable_disable is not compiled in.

Nevertheless, even if it's not through sysfs, *something* is enabling and disabling the touchkeys.

Also -- and I'm not particularly familiar with the Android stack yet, so stop me if this is totally off-base -- but I've noticed that every time the touchkey lights go on or off there is a message in Logcat reading "PowerManagerService ULight 3->7 f0" (for turning on) or "ULight 7->3 f0" (for turning off). I haven't found the Java code that this corresponds to, yet, though, in spite of a quick skin through PowerManagerService.java.
[Galaxy S I9000 Android Development] pocketjpaul:
Why not use the screen?

(Super) AMOLED is nice because when you show a black screen, it consumes 0w, as if it where off.

Why don't remap the off-button to an APP that shows a black screen with just little part of the screen for notifications (or a false LED) ?

(excuse my baaad english =) )
[Galaxy S I9000 Android Development] kenkiller:
Sadly, that's not true. :)
[Galaxy S I9000 Android Development] madmack:
I've created a new thread for the AMOLED notification app at http://xdaforums.com/showthread.php?p=7267348

Let's leave this thread for the ongoing efforts on getting the backlight button for these notifications.
[Galaxy S I9000 Android Development] shaneaus:
This could work for missed calls as well. It would only require the user to use an app like "missed reminder" to set an audible signal for when the call is missed....

Would that allow this to be modded to work with missed calls?
[Galaxy S I9000 Android Development] dakine:
Could we let them "breathe" like the led on a macbook when it's in sleep mode? I figure this will save energy and possibly prevent the leds from wearing out.
[Galaxy S I9000 Android Development] darksnarfer:
I searched through samsung source code and I couldn't find the "ULight" string, maybe is somewhere else at AOSP?

Another idea, we could try to write directly to the i2c bus to enable/disable the leds and brightness, but unfortunately I'm not so skilled to know how to do it. Anybody has the knowledge? :rolleyes:
[Galaxy S I9000 Android Development] leperousdust:
Has there been any headway on this, breathing/pulsing notification lights would be amazing, different speeds or flashing for different notifications. I like the idea of noLED but this implementation just seems far more polished, if it were to get off the ground :)
[Galaxy S I9000 Android Development] android53:
This is an awesome idea. Seeing as the screen still seems to use a little power even when off. Most likely because it has to activate the graphics chip to show the red dot.

This could be a much better implementation
[Galaxy S I9000 Android Development] Deedend:
Any news about this kind of notification?
[Galaxy S I9000 Android Development] neldar:
Are you sure about that?

I also found "ULight 3->1 f0", " ULight 1->0 f0" and "ULight 0->7 f0".

And i discovered that the "touchkey_enable==1"-check in the i2c_touchkey_write-function should only prevent the leds to go on before the IRQ_TOUCH_INT gets enabled.

This means we dont need the enable_disable-function, only the correct i2c commands should be enough to switch the leds on/off.

So is here anyone who knows how we can write an i2c command directly to the i2c-bus?
[Galaxy S I9000 Android Development] elbasso:
I read that the samsung captivate source code has been released. Won't this help in getting the back lit buttons to work as a notification means?
[Galaxy S I9000 Android Development] neldar:
@elbasso: We have already source code of the i9000.

Atm, i'm testing if it is possible to get access to the i2c bus via the dev-interface from userspace.

If that works, i'll try to find the correct addresses.
[Galaxy S I9000 Android Development] elbasso:
I sincerely hope you can get it to work. I would be happy to do some testing.
[Galaxy S I9000 Android Development] neldar:
Today i got a dump of the i2c bus, but i have been to optimistic about the interrupt. It has to be enabled to set the button-leds.

So here is the dump:

i2cdump -f -y 10 0x20
No size specified (using byte-data access)
0 1 2 3 4 5 6 7 8 9 a b c d e f 0123456789abcdef
00: 00 01 02 03 04 05 06 07 08 09 0a 0b 0c 0d 0e 0f .???????????????
10: 10 11 12 13 14 15 16 17 18 19 1a 1b 1c 1d 1e 1f ????????????????
20: 20 21 22 23 24 25 26 27 28 29 2a 2b 2c 2d 2e 2f !"#$%&'()*+,-./
30: 30 31 32 33 34 35 36 37 38 39 3a 3b 3c 3d 3e 3f 0123456789:;<=>?
40: 40 41 42 43 44 45 46 47 48 49 4a 4b 4c 4d 4e 4f @ABCDEFGHIJKLMNO
50: 50 51 52 53 54 55 56 57 58 59 5a 5b 5c 5d 5e 5f PQRSTUVWXYZ[\]^_
60: 60 61 62 63 64 65 66 67 68 69 6a 6b 6c 6d 6e 6f `abcdefghijklmno
70: 70 71 72 73 74 75 76 77 78 79 7a 7b 7c 7d 7e 7f pqrstuvwxyz{|}~?
80: 80 81 82 83 84 85 86 87 88 89 8a 8b 8c 8d 8e 8f ????????????????
90: 90 91 92 93 94 95 96 97 98 99 9a 9b 9c 9d 9e 9f ????????????????
a0: a0 a1 a2 a3 a4 a5 a6 a7 a8 a9 aa ab ac ad ae af ????????????????
b0: b0 b1 b2 b3 b4 b5 b6 b7 b8 b9 ba bb bc bd be bf ????????????????
c0: c0 c1 c2 c3 c4 c5 c6 c7 c8 c9 ca cb cc cd ce cf ????????????????
d0: d0 d1 d2 d3 d4 d5 d6 d7 d8 d9 da db dc dd de df ????????????????
e0: e0 e1 e2 e3 e4 e5 e6 e7 e8 e9 ea eb ec ed ee ef ????????????????
f0: f0 f1 f2 f3 f4 f5 f6 f7 f8 f9 fa fb fc fd fe ff ???????????????.

If you set bit 0x01 you can enable both leds and at 0x02 you can disable the leds, but only if the touchkeys are enabled. I accomplished this by pressing the home key.

This command activate the leds:

i2cset -f -y 10 0x20 0x01 1

and this will deactivate the leds:

i2cset -f -y 10 0x20 0x02 1

The i2c-bus may be different on your device.

And you need to be root to write to the i2c-bus.

I have attached the i2c-tools.
[Galaxy S I9000 Android Development] Karupan:
^^ Nice work! Even though I'm only getting started with Android development, let me see if I can help in someway.
[Galaxy S I9000 Android Development] pelo1986:
I belong to you! :o

:D
[Galaxy S I9000 Android Development] designgears:
Very nice, one problem tho, it wont work with the screen off, over ADB at least.

Guess I could try a looping script turning them off and on and see what happens.

edit, nope, doesnt work while the screen is off :(
[Galaxy S I9000 Android Development] darksnarfer:
What about enabling the IRQ from userspace, is it possible?

I was thinking about making a little .c program with the code from cypress-touchkey.c but it might interfere with the kernel driver itsel, and maybe screw things up.