Page 1 of 2

Blinking LED

PostPosted: Tue Feb 18, 2014 9:39 pm
by vempire
Hi,

Is there anything I can do to turn off the blue LED? It is blinking constantly and it will create an effect as if the cops are invading my living room!

Otherwise no complaints so far!

Cheers,
vma

Re: Blinking LED

PostPosted: Tue Feb 18, 2014 10:33 pm
by fvdw
in the system menu there is an option to switch off the led, but I am not sure that it will work already for cloudbox

otherwise you could put a piece of adhesive tape over it for the time being

Re: Blinking LED

PostPosted: Wed Feb 19, 2014 5:05 pm
by vempire
Hi,

The menu does not work and yes, I already covered the LED... :lol: -> That is a hardware mod, complimentary to the software mod!

Cheers,
vma

Re: Blinking LED

PostPosted: Fri Apr 18, 2014 3:48 pm
by drixon
Hi Vempire,

For you it like the cops will invade you living room, but me, it's like a night club in my hall :lmao , neighbors will soon come knock at my door to spend some time :beer: :beer:

but I trust the genius of this project will come up with a solution soon ;)

Thanks to them in advance

Re: Blinking LED

PostPosted: Fri Apr 18, 2014 6:41 pm
by fvdw
I never looked at in detail yet

If you connect via ssh and list the content of the folder /sys/class/leds

There should be a list of leds defined, please post the content here
I think it will only mention familybox:red:fail

The blue led is set blink on in the kernel I think I can adapt it but also provide a input in the folder mentioned above
But it should already be visible in /sys/devices/platform/leds-ns2l with name familybox:blue:sata
The default trigger is set to timer

this can be changed by writing default-on to the "trigger" file in /sys/devices/platform/leds-ns2l/familybox:blue:sata
after that you should be able to switch it on or of by writing 1 or 0 to the "brightness" file in that same sub folder
To write to these file use the command "cat", for example
Code: Select all
echo default-on > /sys/devices/platform/leds-ns2l/familybox:blue:sata/trigger
echo 1 > /sys/devices/platform/leds-ns2l/familybox:blue:sata/brightness
or
echo 0 > /sys/devices/platform/leds-ns2l/familybox:blue:sata/brightness

Re: Blinking LED

PostPosted: Fri Apr 18, 2014 9:08 pm
by fvdw
if "default-on" doesn't do it try "none" as trigger

Re: Blinking LED

PostPosted: Sat Apr 19, 2014 3:04 pm
by drixon
Hi Fvdw,

thanks for your quick response.

Here is the result of the command as you requested :

Code: Select all
ls -l /sys/class/leds
total 0
lrwxrwxrwx  1 root root 0 2014-04-19 09:57 familybox:blue:sata -> ../../devices/platform/leds-ns2l/leds/familybox:blue:sata
lrwxrwxrwx  1 root root 0 2014-04-19 09:57 familybox:red:fail -> ../../devices/platform/leds-gpio/leds/familybox:red:fail


here is what I found on the file /sys/devices/platform/leds-ns2l/leds/familybox:blue:sata/trigger

Code: Select all
none nand-disk [timer] heartbeat backlight gpio default-on


and on the file /sys/devices/platform/leds-ns2l/leds/familybox:blue:sata/brightness

Code: Select all
255


So What I've done is just to change the value on the 'brightness' file to '0' and the LED went off like magic :-)
(I didn't touch the 'trigger' file)

However, when I powered off the NAS and powered it on again the LED was flashing again.
when I checked the 'brightness' file the value of '0' was still there, and when I changed it to '1' and then back to '0' the LED went off again.

The trick is working well, but what do you think I need to change to keep the LED off even after a reboot?

Thanks again

Re: Blinking LED

PostPosted: Sat Apr 19, 2014 3:40 pm
by fvdw
what you could for the moment is use the feature "boot-jobs". This lets you execute user made scripts at boot time
It is available in the Cron scheduler menu (taskplanner).
See screen shot. There is a help menu available for this page how to use .
boot-jobs.JPG

You will need a command file file with contains the command to switch off the led
For instance make a shell command file with name pledon.sh it should contain
Code: Select all
#!/bin/sh
echo 0 > /sys/devices/platform/leds-ns2l/familybox:blue:sata/brightness

To make it easy for you I attached the example script file.(unpack the zip file to get it)

ps if you make your own shell scripts read also the part in the help menu on "supported scripts" and which formats must be used (unix).

Re: Blinking LED

PostPosted: Sat Apr 19, 2014 10:21 pm
by drixon
Dear fvdw,

I know I can't thank you enough but as I've told you before Your efforts and contributes are making this world a better place to live in. :thumbup

It works like a charm

Thank you very much. :hail

Re: Blinking LED

PostPosted: Mon Dec 22, 2014 9:30 pm
by twiikker
Newbie here :)
I have this blinking problem myself.
How do i get that .sh file to boot jobs menu?