Currently translated at 7.1% (3 of 42 strings) Translation: OpenWrt/LuCI/applications/ser2net Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationsser2net/cs/ Signed-off-by: Pavel Borecki <pavel.borecki@gmail.com> Translated using Weblate (Czech) Currently translated at 3.8% (1 of 26 strings) Translation: OpenWrt/LuCI/applications/vnstat2 Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationsvnstat2/cs/ Signed-off-by: Pavel Borecki <pavel.borecki@gmail.com> Translated using Weblate (Czech) Currently translated at 4.6% (3 of 65 strings) Translation: OpenWrt/LuCI/applications/yggdrasil Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationsyggdrasil/cs/ Signed-off-by: Pavel Borecki <pavel.borecki@gmail.com> Translated using Weblate (Chinese (Simplified)) Currently translated at 13.3% (13 of 98 strings) Translation: OpenWrt/LuCI/applications/vpn-policy-routing Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationsvpn-policy-routing/zh_Hans/ Signed-off-by: Kiki Kiki <kikinj@gmail.com> Translated using Weblate (Czech) Currently translated at 4.1% (4 of 98 strings) Translation: OpenWrt/LuCI/applications/vpn-policy-routing Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationsvpn-policy-routing/cs/ Signed-off-by: Pavel Borecki <pavel.borecki@gmail.com> Translated using Weblate (Czech) Currently translated at 22.5% (9 of 40 strings) Translation: OpenWrt/LuCI/applications/https-dns-proxy Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationshttps-dns-proxy/cs/ Signed-off-by: Pavel Borecki <pavel.borecki@gmail.com> Translated using Weblate (Czech) Currently translated at 31.2% (5 of 16 strings) Translation: OpenWrt/LuCI/applications/omcproxy Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationsomcproxy/cs/ Signed-off-by: Pavel Borecki <pavel.borecki@gmail.com> Translated using Weblate (Czech) Currently translated at 21.1% (4 of 19 strings) Translation: OpenWrt/LuCI/applications/nextdns Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationsnextdns/cs/ Signed-off-by: Pavel Borecki <pavel.borecki@gmail.com> Translated using Weblate (Czech) Currently translated at 100.0% (48 of 48 strings) Translation: OpenWrt/LuCI/applications/ttyd Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationsttyd/cs/ Signed-off-by: Pavel Borecki <pavel.borecki@gmail.com> Translated using Weblate (Czech) Currently translated at 17.0% (8 of 47 strings) Translation: OpenWrt/LuCI/applications/mjpg-streamer Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationsmjpg-streamer/cs/ Signed-off-by: Pavel Borecki <pavel.borecki@gmail.com> Translated using Weblate (Czech) Currently translated at 100.0% (33 of 33 strings) Translation: OpenWrt/LuCI/applications/wifischedule Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationswifischedule/cs/ Signed-off-by: Pavel Borecki <pavel.borecki@gmail.com> Translated using Weblate (Chinese (Simplified)) Currently translated at 100.0% (139 of 139 strings) Translation: OpenWrt/LuCI/applications/adblock Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationsadblock/zh_Hans/ Signed-off-by: Kiki Kiki <kikinj@gmail.com> Translated using Weblate (Czech) Currently translated at 97.1% (135 of 139 strings) Translation: OpenWrt/LuCI/applications/adblock Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationsadblock/cs/ Signed-off-by: Pavel Borecki <pavel.borecki@gmail.com> Translated using Weblate (Czech) Currently translated at 100.0% (24 of 24 strings) Translation: OpenWrt/LuCI/applications/wireguard Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationswireguard/cs/ Signed-off-by: Pavel Borecki <pavel.borecki@gmail.com> Translated using Weblate (Czech) Currently translated at 20.3% (15 of 74 strings) Translation: OpenWrt/LuCI/applications/shadowsocks-libev Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationsshadowsocks-libev/cs/ Signed-off-by: Pavel Borecki <pavel.borecki@gmail.com> Translated using Weblate (Czech) Currently translated at 100.0% (64 of 64 strings) Translation: OpenWrt/LuCI/applications/dnscrypt-proxy Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationsdnscrypt-proxy/cs/ Signed-off-by: Pavel Borecki <pavel.borecki@gmail.com> Translated using Weblate (Czech) Currently translated at 100.0% (6 of 6 strings) Translation: OpenWrt/LuCI/applications/squid Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationssquid/cs/ Signed-off-by: Pavel Borecki <pavel.borecki@gmail.com> Translated using Weblate (Czech) Currently translated at 100.0% (12 of 12 strings) Translation: OpenWrt/LuCI/applications/shairplay Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationsshairplay/cs/ Signed-off-by: Pavel Borecki <pavel.borecki@gmail.com> Translated using Weblate (Czech) Currently translated at 100.0% (11 of 11 strings) Translation: OpenWrt/LuCI/applications/bcp38 Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationsbcp38/cs/ Signed-off-by: Pavel Borecki <pavel.borecki@gmail.com> Translated using Weblate (Czech) Currently translated at 100.0% (104 of 104 strings) Translation: OpenWrt/LuCI/applications/banip Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationsbanip/cs/ Signed-off-by: Pavel Borecki <pavel.borecki@gmail.com> Translated using Weblate (Czech) Currently translated at 24.7% (39 of 158 strings) Translation: OpenWrt/LuCI/applications/mwan3 Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationsmwan3/cs/ Signed-off-by: Pavel Borecki <pavel.borecki@gmail.com> Translated using Weblate (Czech) Currently translated at 16.3% (28 of 172 strings) Translation: OpenWrt/LuCI/applications/aria2 Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationsaria2/cs/ Signed-off-by: Pavel Borecki <pavel.borecki@gmail.com> Translated using Weblate (Czech) Currently translated at 100.0% (16 of 16 strings) Translation: OpenWrt/LuCI/applications/udpxy Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationsudpxy/cs/ Signed-off-by: Pavel Borecki <pavel.borecki@gmail.com> Translated using Weblate (Czech) Currently translated at 100.0% (19 of 19 strings) Translation: OpenWrt/LuCI/applications/ltqtapi Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationsltqtapi/cs/ Signed-off-by: Pavel Borecki <pavel.borecki@gmail.com> Translated using Weblate (Czech) Currently translated at 9.6% (17 of 177 strings) Translation: OpenWrt/LuCI/applications/unbound Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationsunbound/cs/ Signed-off-by: Pavel Borecki <pavel.borecki@gmail.com> Translated using Weblate (Czech) Currently translated at 20.0% (6 of 30 strings) Translation: OpenWrt/LuCI/applications/dynapoint Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationsdynapoint/cs/ Signed-off-by: Pavel Borecki <pavel.borecki@gmail.com> Translated using Weblate (Czech) Currently translated at 99.2% (123 of 124 strings) Translation: OpenWrt/LuCI/applications/privoxy Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationsprivoxy/cs/ Signed-off-by: Pavel Borecki <pavel.borecki@gmail.com> Translated using Weblate (Czech) Currently translated at 39.1% (9 of 23 strings) Translation: OpenWrt/LuCI/applications/lxc Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationslxc/cs/ Signed-off-by: Pavel Borecki <pavel.borecki@gmail.com> Translated using Weblate (Czech) Currently translated at 5.5% (3 of 55 strings) Translation: OpenWrt/LuCI/applications/dump1090 Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationsdump1090/cs/ Signed-off-by: Pavel Borecki <pavel.borecki@gmail.com> Translated using Weblate (Czech) Currently translated at 100.0% (1 of 1 strings) Translation: OpenWrt/LuCI/applications/attendedsysupgrade Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationsattendedsysupgrade/cs/ Signed-off-by: Pavel Borecki <pavel.borecki@gmail.com> Translated using Weblate (Czech) Currently translated at 11.1% (6 of 54 strings) Translation: OpenWrt/LuCI/applications/nft-qos Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationsnft-qos/cs/ Signed-off-by: Pavel Borecki <pavel.borecki@gmail.com> Translated using Weblate (Czech) Currently translated at 100.0% (2 of 2 strings) Translation: OpenWrt/LuCI/applications/olsr-viz Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationsolsr-viz/cs/ Signed-off-by: Pavel Borecki <pavel.borecki@gmail.com> Translated using Weblate (Czech) Currently translated at 31.4% (37 of 118 strings) Translation: OpenWrt/LuCI/applications/travelmate Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationstravelmate/cs/ Signed-off-by: Pavel Borecki <pavel.borecki@gmail.com> Translated using Weblate (Czech) Currently translated at 14.8% (17 of 115 strings) Translation: OpenWrt/LuCI/applications/nlbwmon Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationsnlbwmon/cs/ Signed-off-by: Pavel Borecki <pavel.borecki@gmail.com> Translated using Weblate (Czech) Currently translated at 93.2% (165 of 177 strings) Translation: OpenWrt/LuCI/applications/ddns Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationsddns/cs/ Signed-off-by: Pavel Borecki <pavel.borecki@gmail.com> Translated using Weblate (Czech) Currently translated at 26.2% (16 of 61 strings) Translation: OpenWrt/LuCI/applications/ocserv Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationsocserv/cs/ Signed-off-by: Pavel Borecki <pavel.borecki@gmail.com> Translated using Weblate (Czech) Currently translated at 10.5% (2 of 19 strings) Translation: OpenWrt/LuCI/applications/fwknopd Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationsfwknopd/cs/ Translated using Weblate (Czech) Currently translated at 80.2% (81 of 101 strings) Translation: OpenWrt/LuCI/applications/transmission Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationstransmission/cs/ Translated using Weblate (Czech) Currently translated at 100.0% (46 of 46 strings) Translation: OpenWrt/LuCI/applications/minidlna Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationsminidlna/cs/ Translated using Weblate (Czech) Currently translated at 100.0% (45 of 45 strings) Translation: OpenWrt/LuCI/applications/upnp Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationsupnp/cs/ Translated using Weblate (Czech) Currently translated at 41.2% (80 of 194 strings) Translation: OpenWrt/LuCI/applications/olsr Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationsolsr/cs/ Translated using Weblate (Czech) Currently translated at 100.0% (11 of 11 strings) Translation: OpenWrt/LuCI/applications/watchcat Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationswatchcat/cs/ Translated using Weblate (Czech) Currently translated at 96.9% (31 of 32 strings) Translation: OpenWrt/LuCI/applications/ahcp Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationsahcp/cs/ Translated using Weblate (Czech) Currently translated at 38.4% (28 of 73 strings) Translation: OpenWrt/LuCI/applications/tinyproxy Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationstinyproxy/cs/ Translated using Weblate (Czech) Currently translated at 100.0% (187 of 187 strings) Translation: OpenWrt/LuCI/applications/openvpn Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationsopenvpn/cs/ Translated using Weblate (Czech) Currently translated at 13.8% (8 of 58 strings) Translation: OpenWrt/LuCI/applications/uhttpd Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationsuhttpd/cs/ Translated using Weblate (Czech) Currently translated at 84.6% (11 of 13 strings) Translation: OpenWrt/LuCI/applications/wol Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationswol/cs/ Translated using Weblate (Czech) Currently translated at 100.0% (31 of 31 strings) Translation: OpenWrt/LuCI/applications/commands Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationscommands/cs/ Translated using Weblate (Czech) Currently translated at 100.0% (10 of 10 strings) Translation: OpenWrt/LuCI/applications/p910nd Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationsp910nd/cs/ Translated using Weblate (Czech) Currently translated at 41.1% (86 of 209 strings) Translation: OpenWrt/LuCI/applications/firewall Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationsfirewall/cs/ Translated using Weblate (Czech) Currently translated at 12.5% (14 of 112 strings) Translation: OpenWrt/LuCI/applications/radicale2 Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationsradicale2/cs/ Translated using Weblate (Czech) Currently translated at 100.0% (57 of 57 strings) Translation: OpenWrt/LuCI/applications/polipo Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationspolipo/cs/ Translated using Weblate (Hungarian) Currently translated at 100.0% (235 of 235 strings) Translation: OpenWrt/LuCI/applications/statistics Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationsstatistics/hu/ Translated using Weblate (Czech) Currently translated at 96.1% (1278 of 1330 strings) Translation: OpenWrt/LuCI/modules/luci-base Translate-URL: https://hosted.weblate.org/projects/openwrt/luci/cs/ Signed-off-by: Pavel Borecki <pavel.borecki@gmail.com> |
||
---|---|---|
.. | ||
luasrc | ||
po | ||
Makefile | ||
README.md |
wifischedule
Turns WiFi on and off according to a schedule on an openwrt router
Components
- wifischedule: Shell script that creates cron jobs based on configuration provided in UCI and does all the other logic of enabling and disabling wifi with the use of
/sbin/wifi
and/usr/bin/iwinfo
. Can be used standalone. - luci-app-wifischedule: LUCI frontend for creating the UCI configuration and triggering the actions. Depends on wifischedule.
Use cases
You can create user-defined events when to enable or disable WiFi. There are various use cases why you would like to do so:
- Reduce power consumption and therefore reduce CO2 emissions.
- Reduce emitted electromagnatic radiation.
- Force busincess hours when WiFi is available.
Regarding 1: Please note, that you need to unload the wireless driver modules in order to get the most effect of saving power. In my test scenario only disabling WiFi saves about ~0.4 Watt, unloading the modules removes another ~0.4 Watt.
Regarding 2: Think of a wireless accesspoint e.g. in your bedrom, kids room where you want to remove the amount of radiation emitted.
Regarding 3: E.g. in a company, why would wireless need to be enabled weekends if no one is there working? Or think of an accesspoint in your kids room when you want the youngsters to sleep after 10 pm instead of facebooking...
Configuration
You can create an arbitrary number of schedule events. Please note that there is on sanity check done whether the start / stop times overlap or make sense. If start and stop time are equal, this leads to disabling the WiFi at the given time.
Logging if enabled is done to the file /var/log/wifi_schedule.log
and can be reviewed through the "View Logfile" tab.
The cron jobs created can be reviewed through the "View Cron Jobs" tab.
Please note that the "Unload Modules" function is currently considered as experimental. You can manually add / remove modules in the text field.
The button "Determine Modules Automatically" tries to make a best guess determining regarding the driver module and its dependencies.
When un-/loading the modules, there is a certain number of retries (module_load
) performed.
The option "Force disabling wifi even if stations associated" does what it says - when activated it simply shuts down WiFi.
When unchecked, its checked every recheck_interval
minutes if there are still stations associated. Once the stations disconnect, WiFi is disabled.
Please note, that the parameters module_load
and recheck_interval
are only accessible through uci.
UCI Configuration wifi_schedule
UCI configuration file: /etc/config/wifi_schedule
:
config global
option logging '0'
option enabled '0'
option recheck_interval '10'
option modules_retries '10'
config entry 'Businesshours'
option enabled '0'
option daysofweek 'Monday Tuesday Wednesday Thursday Friday'
option starttime '06:00'
option stoptime '22:00'
option forcewifidown '0'
config entry 'Weekend'
option enabled '0'
option daysofweek 'Saturday Sunday'
option starttime '00:00'
option stoptime '00:00'
option forcewifidown '1'
Script: wifi_schedule.sh
This is the script that does the work. Make your changes to the UCI config file: /etc/config/wifi_schedule
Then call the script as follows in order to get the necessary cron jobs created:
wifi_schedule.sh cron
All commands:
wifi_schedule.sh cron|start|stop|forcestop|recheck|getmodules|savemodules|help
cron: Create cronjob entries.
start: Start wifi.
stop: Stop wifi gracefully, i.e. check if there are stations associated and if so keep retrying.
forcestop: Stop wifi immediately.
recheck: Recheck if wifi can be disabled now.
getmodules: Returns a list of modules used by the wireless driver(s)
savemodules: Saves a list of automatic determined modules to UCI
help: This description.