Some people prefer to have their wifi turned off at night. DD-wrt already provides out of the box reprogrammability of the WPS button so you can use that button to turn the wifi off/on.
If you want to use a cron job to automate this process, you need to know the command line. I tried using the wl command:
wl radio off
Unfortunately this doesn’t do much. We might need to specify the network interface on which to apply the command. List the network interfaces using the ip addr command:
root@DD-WRT:~# ip a 1: lo: <LOOPBACK,MULTICAST,UP,10000> mtu 16436 qdisc noqueue link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00 inet 127.0.0.1/8 brd 127.255.255.255 scope host lo 2: eth0: <BROADCAST,MULTICAST,UP,10000> mtu 1500 qdisc pfifo_fast link/ether c0:c1:c0:ab:6c:70 brd ff:ff:ff:ff:ff:ff 3: eth1: <BROADCAST,MULTICAST,UP,10000> mtu 1500 qdisc pfifo_fast link/ether c0:c1:c0:ab:6c:72 brd ff:ff:ff:ff:ff:ff 4: teql0: mtu 1500 qdisc noop link/void 5: tunl0: mtu 1480 qdisc noop link/ipip 0.0.0.0 brd 0.0.0.0 6: gre0: mtu 1476 qdisc noop link/gre 0.0.0.0 brd 0.0.0.0 7: vlan1@eth0: <BROADCAST,MULTICAST,UP,10000> mtu 1500 qdisc noqueue link/ether c0:c1:c0:ab:6c:70 brd ff:ff:ff:ff:ff:ff 8: vlan2@eth0: <BROADCAST,MULTICAST,UP,10000> mtu 1500 qdisc noqueue link/ether c0:c1:c0:ab:6c:71 brd ff:ff:ff:ff:ff:ff inet 178.117.xxx.xxx/20 brd 178.117.xxx.255 scope global vlan2 9: br0: <BROADCAST,MULTICAST,PROMISC,UP,10000> mtu 1500 qdisc noqueue link/ether c0:c1:c0:ab:6c:70 brd ff:ff:ff:ff:ff:ff inet 192.168.1.1/24 brd 192.168.1.255 scope global br0 inet 169.254.255.1/16 brd 169.254.255.255 scope global br0:0 10: etherip0: <BROADCAST,MULTICAST> mtu 1500 qdisc noop link/ether f6:1f:60:c5:50:bf brd ff:ff:ff:ff:ff:ff
I’m no network expert so I checked the MAC address of the wifi interface in the web admin Status > Wireless page ( http://192.168.1.1/Status_Wireless.asp ) and figured eth1 must be the wifi interface.
And indeed, using the following command it worked!
wl -i eth1 radio off
You can check whether radio state changes in the wireless status page mentioned above. For automation, put these commands in a cron job on the Administration > Management page ( http://192.168.1.1/Management.asp ).