ps: I moved this request to installation and use Openwrt, because unless you want to create a lighting package for managing LEDs it's not a real additional feature
Thanks, but I am talking about something like inverted default LED state. Like if I want an LED to blink, I want to make it blink in a negative state or a positive state, which can't be done through brightness file of LED which just permanently turns on or shuts off LED which I don't want to happen.
Blinking postively means default state without activity is ON (1) for LED and during activity it gets OFF (0) and then ON (1) when no activity, and this oscillation continues.
Blinking negatively means default state without activity is OFF (0) for LED and during activity it gets ON (1) and then OFF (0) when no activity, and this oscillation continues.
I am talking about changing that default state as I described above.
What: /sys/class/leds//inverted
Date: January 2011
KernelVersion: 2.6.38
Contact: Richard Purdie rpurdie@rpsys.net
Description:
Invert the LED on/off state. This parameter is specific to
gpio and backlight triggers. In case of the backlight trigger,
it is useful when driving a LED which is intended to indicate
a device in a standby like state.
ps: I moved this request to installation and use Openwrt, because unless you want to create a lighting package for managing LEDs it's not a real additional feature
And how did you moved the thread to other category as I had no access to do that ?
open a new thread to understand which kernel module or opkg package allows you to make the LEDs work inverted (please, since it is not a new feature you are requesting, put it between installation and Openwrt configuration)
I got this somewhere in response for doing sudo update-rc.d led-control defaults after adding a new initscript in OpenWrt :
OpenWrt typically uses the procd init system, which is different from SysV init. Procd does not use the traditional runlevel system, and its configuration is often handled differently. The update-rc.d command might not be applicable in an OpenWrt environment.
So this : sudo update-rc.d led-control defaults is not required ?
Fortunately, thank god, I didn't mark this thread as solved because earlier I was thinking that if initscript doesn't work then I will use Startup subsection's Local Startup tab (which controls /etc/rc.local file) to execute the LED-turn-off script file to turn off LEDs as suggested by @maurer and @elbertmai but when I used rc.local and the executed script sends LED off commands to all 5 LEDs (lan, wan, power, wlan-2, wlan-5) after reboot, only lan and wan LEDs turn off but no effect on power, wlan-2 and wlan-5 LEDs (they remain on).
When I explicitly execute the script from ssh then all LEDs turn off but not if the script gets executed after reboot automatically as defined by me in rc.local.
Neither rc.local file worked nor initscript is getting enabled permanently. Now what should I do ? Someone please guide me.
Tested multiple times but didn't work. So this thread is still unsolved. Good that I didn't close this as solved.
Most likely only lan and wan are software leds and the other ones are "hardwired" to the cpu somehow.
It would help if you would "dig" through the gpl tarball of your vendor firmware to check how the implemented full led off
Thanks for replying. I am new and not experienced yet but I don't think so because Initscript is successful in turning off all LEDs (which did not happen with startup script in local.rc) but only issue is that symlink of the Initscript fails to create in rc.d folder on tapping Enabled button. The Enabled button turns back to Disabled button on just if I refresh LUCI web UI page.
Also can you please suggest me where should I start in GPL tarball as i am just starting to understand how to interpret and manipulate linux code and environment.