maemo.org - Talk

maemo.org - Talk (https://talk.maemo.org/index.php)
-   Maemo 5 / Fremantle (https://talk.maemo.org/forumdisplay.php?f=40)
-   -   (N900) Possible to change the colour of the notification light??? (https://talk.maemo.org/showthread.php?t=37691)

codeMonkey 2009-12-23 15:04

Re: (N900) Possible to change the colour of the notification light???
 
I'm not sure. It's probably being constrained by the fremantle hildon-toolbar in the name of finger-friendliness.

munky261 2009-12-24 02:34

Re: (N900) Possible to change the colour of the notification light???
 
Ahh..gotcha. Is there any way to override that for just one particular app?

Devil 2009-12-26 22:37

Re: (N900) Possible to change the colour of the notification light???
 
first question. what if you have missed a call, and got an im for example..

could it blink green and red through each other for example? red, off, green, off, red, off etc

furthermore, could someone post a '1-post guide' for an entire n00b with all the steps to change the led notification for calls/ims/sms/emails ? i know i actually should try to figure it all out by myself instead of asking someone this.. but.. asking wont hurt anyone i hope :)

Devil 2009-12-26 23:50

Re: (N900) Possible to change the colour of the notification light???
 
cant find an editor for mce.ini.

cant open as root.

i think more people than just me want this?

codeMonkey 2009-12-27 07:12

Re: (N900) Possible to change the colour of the notification light???
 
Quote:

Originally Posted by munky261 (Post 439893)
Ahh..gotcha. Is there any way to override that for just one particular app?

I won't say no, but I haven't seen a way just yet.

Quote:

Originally Posted by Devil (Post 442460)
first question. what if you have missed a call, and got an im for example..

could it blink green and red through each other for example? red, off, green, off, red, off etc

Currently there are only a limited number of led patterns:
Code:

PatternError=0;5;0;r;9d8040007f007f0040ff7f007f000000;9d800000
PatternDeviceOn=254;0;0;rgb;9d804000422043207f100000;9d800000
PatternDeviceSoftOff=253;0;0;rg;9d804000423f433f7f100000;9d800000
PatternPowerOn=9;3;0;rgb;9d80400042ff02ffc000;9d800000
PatternPowerOff=10;3;0;rgb;9d80400001ff43ff7f007f00c000;9d800000
PatternCommunicationCall=30;1;0;b;9d80400002ff03ff02ff03ff71080000;9d800000
PatternCommunicationIM=30;1;0;b;9d80400002ff03ff02ff03ff71080000;9d800000
PatternCommunicationSMS=30;1;0;b;9d80400002ff03ff02ff03ff71080000;9d800000
PatternCommunicationEmail=30;1;0;b;9d80400002ff03ff02ff03ff71080000;9d800000
PatternCommonNotification=30;1;0;b;9d80400002ff03ff02ff03ff71080000;9d800000
PatternWebcamActive=20;1;0;r;9d80400004ffc0000000;9d800000
PatternBatteryCharging=50;4;0;rg;9d804000427f0d7f7f007f0042000000;9d800000
PatternBatteryFull=40;4;0;g;9d80407f0000;9d800000

Adding new patterns to the list would be easy enough - but getting other applications to use them would be more tough.

Quote:

Originally Posted by Devil (Post 442460)
furthermore, could someone post a '1-post guide' for an entire n00b with all the steps to change the led notification for calls/ims/sms/emails ? i know i actually should try to figure it all out by myself instead of asking someone this.. but.. asking wont hurt anyone i hope :)

I'll see if I can help out shortly - can't guarantee anything today, though.
First off, you'll need to ignore practically everything we've said to Munky - he's using an n810.

Devil 2009-12-28 03:39

Re: (N900) Possible to change the colour of the notification light???
 
proposing an app for this would be done in brainstorm wouldnt it?

Blinde 2010-01-04 20:07

Re: (N900) Possible to change the colour of the notification light???
 
Some handyman could really make app for this one.

Or could someone help me how to access that mce.ini file and change those values? What apps do I need?

synca 2010-01-12 23:32

Re: (N900) Possible to change the colour of the notification light???
 
To do this you need some stuff that needs disclaimers and warnings all over the place, as stated before, it's should be very easy to brick your device using and changing any of these apps/repositories/files,...

First you need root access on xterminal
You can get this by installing rootsh from extras/devel IIRC. (help on this topic in other treads on this forum!)

Then you need a program to edit the file
I like to use leafpad as I'm used to notepad on windows.
Leafpad is also in one of the extras repositories.

Now for the real work:
Open Xterm
type:
Code:

root
from now on you have root access (notice the # at the end of the current line instead of the $) so don't do stupid things!

For safety measures copy the mce.ini file.
how I go about this is by making a directory in the same one the file is in and then copy the file to that directory. To do that:

Code:

cd /etc/mce/
mkdir MceIniOld
cp mce.ini MceIniOld/mce.ini.old

Now open the file with leafpad
Code:

leafpad /etc/mce/mce.ini
and make the changes you'd like to make. Double check your input before choosing save from the statusbar menu! Close Leafpad.

To get the changes you made they have to be reloaded. Force this with this command in xterm as root:

Code:

killall mce
This way you don't have to restart after every change.

Offtopic:
Have to say I learned all this from trailing this forum and great community, makes my N900 experience one of the best yet in phones as well as computer.

Hint:
Googling "linux commands" can teach allot about how to do things the linux way from xterm. move, rename, list content, the use of flags (eg.: -a) and mutch more.
Some general rules: spaces Capitals and symbols matter!!!
One last disclaimer: All in this post I found out by trial and, thankfully very little, error. I don't have a clue about Linux so don't thake this as the right way to do things!!

codeMonkey 2010-01-13 08:27

Re: (N900) Possible to change the colour of the notification light???
 
Quote:

Originally Posted by synca (Post 467397)
To get the changes you made they have to be reloaded. Force this with this command in xterm as root:
Code:

killall mce
This way you don't have to restart after every change.

If you kill/stop the mce process more than (rough estimate) 4 times in approx 2 minutes the service doesn't restart.
You're best off using something like
Code:

initctl stop mce; sleep 2; initctl start mce
because it gives feedback - so will tell you if it hasn't been able to start or stop it.

I've also put a guide to the n900 led patterns here in case anyone wants to play around further with colours etc.

codeMonkey 2010-01-13 08:35

Re: (N900) Possible to change the colour of the notification light???
 
And a useful script for testing led patterns without having to receive sms/email:

Code:

#!/bin/sh
pattern=PatternCommunicationSMS
dbus-send --system --type=method_call --dest=com.nokia.mce /com/nokia/mce/request com.nokia.mce.request.req_led_pattern_activate string:$pattern
sleep 10
dbus-send --system --type=method_call --dest=com.nokia.mce /com/nokia/mce/request com.nokia.mce.request.req_led_pattern_deactivate string:$pattern

which will activate the sms pattern, let it run for 10 seconds and then deactivate it.

djlucklu 2010-01-18 18:42

Re: (N900) Possible to change the colour of the notification light???
 
Quote:

Originally Posted by codeMonkey (Post 467844)
If you kill/stop the mce process more than (rough estimate) 4 times in approx 2 minutes the service doesn't restart.
You're best off using something like
Code:

initctl stop mce; sleep 2; initctl start mce
because it gives feedback - so will tell you if it hasn't been able to start or stop it.

I've also put a guide to the n900 led patterns here in case anyone wants to play around further with colours etc.

i seriously need help.. i did the kill mce before a read your post but i did your instructions to start the mce again. i rebooted and now my phone doesnt have any light notifications.. any suggestions?

codeMonkey 2010-01-18 19:38

Re: (N900) Possible to change the colour of the notification light???
 
On reboot mce should start again.
You can check to see if it's running by typing:
Code:

ps | grep mce
Iget the following output
Code:

  741 root      5312 S <  /sbin/mce --force-syslog
 1750 user      2092 R    grep mce

which shows mce is running.

If mce is running then it might be that some changes you've made have done wrong.
If it isn't then you should be able to restart mce by typing
Code:

rootsh initctl start mce
Let us know what happens.

ossipena 2010-01-20 07:49

Re: (N900) Possible to change the colour of the notification light???
 
http://wiki.maemo.org/Customizing_maemo_for_power_users

feel free to help.

codeMonkey 2010-01-20 09:23

Re: (N900) Possible to change the colour of the notification light???
 
Quote:

Originally Posted by ossipena (Post 483717)

It looks like there's quite a bit of cross-over with this.

ahynes1 2010-01-30 15:54

Re: (N900) Possible to change the colour of the notification light???
 
Working off of codeMonkey's comments, I've added new patterns to my N900 and used them in new scripts. A few things to keep in mind in adding a new pattern to the N900:

Be sure to add the pattern to the LEDPatterns in mce.ini. Also, be sure to add the LED pattern to the [LEDPatternLystiRX51] section. Initially, it wasn't clear to me which section to use.

Finally, using the dbus commands that codeMonkey provided you can add your new patterns to any application you are creating or modifying.

For more details, check out my recent blog post about controlling the status LED on the N900

rocky272727 2010-02-26 18:33

Re: (N900) Possible to change the colour of the notification light???
 
http://www.mynokiaworld.com/2010/01/...cation-lights/

Did mine....looks great

blue_led 2010-02-26 19:19

Re: (N900) Possible to change the colour of the notification light???
 
more in the last 3-4 pages
http://talk.maemo.org/showthread.php?t=42201

raedn900 2010-06-13 12:45

Re: (N900) Possible to change the colour of the notification light???
 
Quote:

Originally Posted by Corwin (Post 437531)
I just fired up my good old trusty N810 to check ;) It seems to have a different controller with a different notation:

Code:

[LEDPatternNJoyRX44]

# Patterns used if the device has an RGB LED connected to an NJoy controller
# Please prefix pattern names with Pattern to avoid name space clashes
#
# Priority (0 - highest, 255 - lowest)
# ScreenOn - 0 only show pattern when the display is off
#            1 show pattern even when the display is on
#            2 only show pattern when the display is off, including acting dead
#            3 show pattern even when the display is on, including acting dead
#            4 only show pattern if the display is off, or if in acting dead
# Timeout in seconds before pattern is disabled, 0 for infinite
# R-channel pattern in NJoy format (16 commands at most)
# G-channel pattern in NJoy format (16 commands at most)
# B-channel pattern in NJoy format (16 commands at most)
#
# 0000 -- Jump to the start of the pattern for the channel
# 40xx -- Set channel brightness
# xxyy -- Increment/decrement
#      xx determines the speed;
#        01-3f -- short step time (granularity 0.49ms)
#        41-7f -- long step time (granularity 15.6ms)
#      yy determines the increment/decrement steps
#        00-7f -- increment steps 00 = 0 steps, 7f = 127 steps
#        80-ff -- decrement steps 80 = 0 steps, ff = 127 steps
#
#        Use 0 steps to create pauses
#        Two consecutive increment/decrement sequences are needed
#        to cover the entire range from 0-255
# c000 -- End pattern execution
# e002 -- Send red trigger
# e004 -- Send green trigger
# e008 -- Send blue trigger
# e080 -- Wait for red trigger
# e100 -- Wait for green trigger
# e200 -- Wait for blue trigger
PatternError=0;1;0;40002000200040ff200020000000;0000;0000
PatternDeviceOn=254;0;0;4000205f20df7f007f007f007f000000;4000205f20df7f007f007f007f000000;4000205f20df7f007f007f007f000000
PatternDeviceSoftOff=253;0;0;4000203f20bf7f007f007f007f007f000000;4000203f20bf7f007f007f007f007f000000;0000
PatternPowerOn=10;3;0;4000207f207f01ff01ffc000;4000207f207f01ff01ffc000;4000207f207f01ff01ffc000
PatternPowerOff=9;3;0;4000017f017f36ff36ff7f00c000;4000017f017f36ff36ff7f00c000;4000017f017f36ff36ff7f00c000
PatternCommunicationCall=30;1;0;0000;0000;40007f00017f017f050001ff01ff0000
PatternCommunicationChat=30;1;0;0000;0000;40007f00017f017f050001ff01ff0000
PatternCommunicationEmail=30;1;0;0000;0000;40007f00017f017f050001ff01ff0000
PatternCommonNotification=30;1;0;0000;0000;40007f00017f017f050001ff01ff0000
PatternWebcamActive=20;1;0;4000027f027fc000;0000;0000
PatternBatteryCharging=50;4;0;0000;4000257f06ff7f0041000000;0000
PatternBatteryFull=40;4;0;0000;407f0000;0000
PatternPsychedelia=250;1;0;4000167f167f17ff17ff0000;40001300197f197f15ff15ff0000;4000237f237f130022ff22ff13000000

# This example pattern has a priority of 42 (all patterns with a *lower*
# priority value will have precedence), and will flash in yellow
# This pattern will be visible even when the display is on.
PatternExample=42;1;30;4000167f167f17ff17ff0000;4000167f167f17ff17ff0000;0000


The explaination in the upper part corresponds to the lines below. The bold part seems to be for the color:

Code:

# R-channel pattern in NJoy format (16 commands at most)
# G-channel pattern in NJoy format (16 commands at most)
# B-channel pattern in NJoy format (16 commands at most)


This means the underlined part:

Code:

PatternCommunicationCall=30;1;0;0000;0000;40007f00017f017f050001ff01ff0000

Call is also blue on the N810, right? This is because we have 0000 for Red, 0000 for Green and 'something' for Blue.

You could search for patterns with red ('PatternError') or green ('PatternBatteryFull') and copy the underlined part I mentioned above responsible for the color from the pattern with the color you want to the pattern you wish to change. Do not copy the other parts of the line as they determine rythm and priority and you only want to change the color! This way you should be able to change the colors.

This should do what you want, although I am giving no warranties whatsoever. It is the whole 'Pattern' block, changed call to red, chat to green. Not sure, though, why green is so short:
Code:

PatternError=0;1;0;40002000200040ff200020000000;0000;0000
PatternDeviceOn=254;0;0;4000205f20df7f007f007f007f000000;4000205f20df7f007f007f007f000000;4000205f20df7f007f007f007f000000
PatternDeviceSoftOff=253;0;0;4000203f20bf7f007f007f007f007f000000;4000203f20bf7f007f007f007f007f000000;0000
PatternPowerOn=10;3;0;4000207f207f01ff01ffc000;4000207f207f01ff01ffc000;4000207f207f01ff01ffc000
PatternPowerOff=9;3;0;4000017f017f36ff36ff7f00c000;4000017f017f36ff36ff7f00c000;4000017f017f36ff36ff7f00c000
PatternCommunicationCall=30;1;0;40002000200040ff200020000000;0000;0000
PatternCommunicationChat=30;1;0;0000;407f0000;0000
PatternCommunicationEmail=30;1;0;0000;0000;40007f00017f017f050001ff01ff0000
PatternCommonNotification=30;1;0;0000;0000;40007f00017f017f050001ff01ff0000
PatternWebcamActive=20;1;0;4000027f027fc000;0000;0000
PatternBatteryCharging=50;4;0;0000;4000257f06ff7f0041000000;0000
PatternBatteryFull=40;4;0;0000;407f0000;0000
PatternPsychedelia=250;1;0;4000167f167f17ff17ff0000;40001300197f197f15ff15ff0000;4000237f237f130022ff22ff13000000


BUT:
Be REALLY careful! I am really, really not being nasty here, but maybe you should not edit the file.

Best regards,
Corwin

Here is the most NOOB question ever here? Plz where do i copy and paste those stuff (Not joking RELLy dnt know!)??

raedn900 2010-06-13 12:46

Re: (N900) Possible to change the colour of the notification light???
 
plzz where do i copy & paste those codes??! Really DONT know at all :D?

blwthompson 2010-06-13 14:49

Re: (N900) Possible to change the colour of the notification light???
 
you dont copy it just open mce with leafpad and change them manually its rather simple reread the thread and youll get it

Saturn 2010-06-13 15:07

Re: (N900) Possible to change the colour of the notification light???
 
Quote:

Originally Posted by raedn900 (Post 713086)
Here is the most NOOB question ever here? Plz where do i copy and paste those stuff (Not joking RELLy dnt know!)??

Just a comment; the specific post you quote is for the N810 and not for the N900.

If you want to experiment in your N900 and you don't mind possibly reflashing your device if something goes wrong, you can try the Led pattern editor application.

raedn900 2010-06-14 12:50

Re: (N900) Possible to change the colour of the notification light???
 
can i just tweak in it(changing colours graphically mainly) & just restart the phone and ignore the warnings and copying and pasting % those stuff cuz i aint understand any of them!...so nothing will happen if so?!?!

Saturn 2010-06-14 22:20

Re: (N900) Possible to change the colour of the notification light???
 
Quote:

Originally Posted by raedn900 (Post 714387)
can i just tweak in it(changing colours graphically mainly) & just restart the phone and ignore the warnings and copying and pasting % those stuff cuz i aint understand any of them!...so nothing will happen if so?!?!

http://maemo.org/downloads/product/M...attern-editor/

raedn900 2010-06-15 10:13

Re: (N900) Possible to change the colour of the notification light???
 
soryy 4 being such a noob? but wt is mce? is it safe to tweak with!!


All times are GMT. The time now is 02:15.

vBulletin® Version 3.8.8