What's new

Power led successfully disabled on r7800 with openwrt

  • SNBForums Code of Conduct

    SNBForums is a community for everyone, no matter what their level of experience.

    Please be tolerant and patient of others, especially newcomers. We are all here to share and learn!

    The rules are simple: Be patient, be nice, be helpful or be gone!

routine

Occasional Visitor
I have been looking for a way to disable the power LED for a while..
I succeeded with openwrt simply by going to the led configuration menu and adding the r7800:white:power to the configuration by deactivating it..
or manually adding these lines to

/etc/config/system :

config led 'led_power'
option name 'Power'
option sysfs 'r7800:white:power'
option default '0'

I think there is no way to do it on the stock/Voxel firmware or am I wrong?
 
I have been looking for a way to disable the power LED for a while..
I think there is no way to do it on the stock/Voxel firmware or am I wrong?

The way to do it on the stock/Voxel is to run the command:

Code:
/sbin/ledcontrol -n power -c green -s  off

To turn it back ON:

Code:
/sbin/ledcontrol -n power -c green -s  on

I use init script to disable the power LED after reboot automatically. Part of the script:

Code:
. . .
start() {
    echo "Turn off Power LED..."
    /sbin/ledcontrol -n power -c green -s  off
    }
stop() {
    echo "Turn on Power LED..."
    /sbin/ledcontrol -n power -c green -s  on
    }
case "$1" in
    start)
        start
        ;;
    stop)
        stop
        ;;
    *)
        echo "Usage: $0 (start|stop)"
        exit 1
        ;;
esac

Voxel.
 
The way to do it on the stock/Voxel is to run the command:

Code:
/sbin/ledcontrol -n power -c green -s  off

To turn it back ON:

Code:
/sbin/ledcontrol -n power -c green -s  on

I use init script to disable the power LED after reboot automatically. Part of the script:

Code:
. . .
start() {
    echo "Turn off Power LED..."
    /sbin/ledcontrol -n power -c green -s  off
    }
stop() {
    echo "Turn on Power LED..."
    /sbin/ledcontrol -n power -c green -s  on
    }
case "$1" in
    start)
        start
        ;;
    stop)
        stop
        ;;
    *)
        echo "Usage: $0 (start|stop)"
        exit 1
        ;;
esac

Voxel.

How, and where, should I put this script? I'm thinking it would make sense to be in init.d as it's a startup script, but I don't know into which one I should place it or if I should create a new one just for this?
 
Need to enable telnet under 192.168.1.1\debug.htm.
Then you need a telnet program to access the router and enter in the command given by Voxel.
 
I'm thinking it would make sense to be in init.d as it's a startup script, but I don't know into which one I should place it or if I should create a new one just for this?
New script in /etc/init.d is more correct way IMO. Or just add

/sbin/ledcontrol -n power -c green -s off

command to /etc/rc.local script. Current /etc/rc.local is:

Code:
# Put your custom commands here that should be executed once
# the system init finished. By default this file does nothing.
exit 0

change it to

Code:
# Put your custom commands here that should be executed once
# the system init finished. By default this file does nothing.
/sbin/ledcontrol -n power -c green -s  off
exit 0

Voxel.
 
Need to enable telnet under 192.168.1.1\debug.htm.
Then you need a telnet program to access the router and enter in the command given by Voxel.
Already done that. Used putty each time I had to restart the router. Was hoping to find a way to make it permanent.


New script in /etc/init.d is more correct way IMO. Or just add

/sbin/ledcontrol -n power -c green -s off

command to /etc/rc.local script. Current /etc/rc.local is:

Code:
# Put your custom commands here that should be executed once
# the system init finished. By default this file does nothing.
exit 0

change it to

Code:
# Put your custom commands here that should be executed once
# the system init finished. By default this file does nothing.
/sbin/ledcontrol -n power -c green -s  off
exit 0

Voxel.

Thank you very much. :)
 
My rc.local file now looks like this.

Code:
# Put your custom commands here that should be executed once
# the system init finished. By default this file does nothing.
/sbin/ledcontrol -n power -c green -s  off
exit 0

But it's not working. Have tried rebooting and waiting up to five minutes. I've tested the command directly:
Code:
/sbin/ledcontrol -n power -c green -s  off
So there's nothing wrong with that.

I know how to make a new file in init.d folder, but now how to make it start at boot. Sorry, Windows is my strong side, Linux, not so much.
 

Similar threads

Latest threads

Sign Up For SNBForums Daily Digest

Get an update of what's new every day delivered to your mailbox. Sign up here!
Top