What's new

Script to turn off wireless

  • 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!

Uranya

New Around Here
Hi friends,
I have just finished to configure this awesome firmware for my brand new ASUS RT-AC68U

I need you to help me to create a script that turns off/on wireless
I have tried to use "wl radio off" and "wl radio on" but this doesn't work.

Please help, thank you!
 
Hi friends,
I have just finished to configure this awesome firmware for my brand new ASUS RT-AC68U

I need you to help me to create a script that turns off/on wireless
I have tried to use "wl radio off" and "wl radio on" but this doesn't work.

Please help, thank you!
What is the final goal (overall goal/plan)?
 
Dear friend, the reason is that I need to have wifi OFF from 3:00 up to 8:00, which the configuration page does not allow.

I'm using scripting through "cru" crontab agent, but I need the right command.

I have tried with this

into services-start added this line:
Code:
cru a ra0 "0 3 * * * /tmp/mnt/scripts/custom/radio_off.sh"

and radio_off.sh as below:
Code:
#!/bin/sh

log='/tmp/mnt/scripts/custom/custom.log'
NOW=$(date +"%Y.%m.%d %H:%M")

echo >> ${log} "${NOW} >>> Radio: OFF"
wl radio off

At 3:00 o'clock I can find the line into log, but wifi is still on

Do you have a way to solve this?
Thank you again!
 
Dear friend, the reason is that I need to have wifi OFF from 3:00 up to 8:00, which the configuration page does not allow.

I'm using scripting through "cru" crontab agent, but I need the right command.

I have tried with this

into services-start added this line:
Code:
cru a ra0 "0 3 * * * /tmp/mnt/scripts/custom/radio_off.sh"

and radio_off.sh as below:
Code:
#!/bin/sh

log='/tmp/mnt/scripts/custom/custom.log'
NOW=$(date +"%Y.%m.%d %H:%M")

echo >> ${log} "${NOW} >>> Radio: OFF"
wl radio off

At 3:00 o'clock I can find the line into log, but wifi is still on

Do you have a way to solve this?
Thank you again!

Hello
Here it is how it works for me on RT-N66U

You need to specify which one adapter you want to turn off

To turn off 2.4
wl -i eth1 radio off

To turn off 5.0
wl -i eth2 radio off

The same to turn them on
Hope it helps

BR
Ocram
 

Similar threads

Sign Up For SNBForums Daily Digest

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