Skip to content

Commit 47537f9

Browse files
committed
luci-app-qmodem: introduced start delay modem_scan for special module booting
1 parent 59774e3 commit 47537f9

File tree

3 files changed

+13
-2
lines changed

3 files changed

+13
-2
lines changed

luci/luci-app-qmodem/Makefile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,8 @@ include $(TOPDIR)/rules.mk
66
PKG_NAME:=luci-app-qmodem
77
LUCI_TITLE:=LuCI support for QWRT Modem
88
LUCI_PKGARCH:=all
9-
PKG_VERSION:=2.8.2
10-
PKG_RELEASE:=2
9+
PKG_VERSION:=2.8.3
10+
PKG_RELEASE:=1
1111
PKG_LICENSE:=GPLv3
1212
PKG_LINCESE_FILES:=LICENSE
1313
PKG_MAINTAINER:=Tom <fjrcn@outlook.com>

luci/luci-app-qmodem/root/etc/config/qmodem

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,3 +3,4 @@ config main 'main'
33
option try_preset_usb "1"
44
option try_preset_pcie "1"
55
option enable_pcie_scan '1'
6+
option start_delay '0'

luci/luci-app-qmodem/root/etc/init.d/qmodem_init

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,16 @@ start_service() {
3636
fi
3737
}
3838

39+
boot() {
40+
local delay=$(uci -q get qmodem.main.start_delay || echo 0)
41+
if [ "$delay" -gt 0 ]; then
42+
logger "Delay QModem Boot init scan for $delay S"
43+
sleep $delay
44+
/usr/share/qmodem/modem_scan.sh scan >/dev/null 2>&1 &
45+
fi
46+
start
47+
}
48+
3949
_try_vendor_preset_usb()
4050
{
4151
config_foreach _try_usb_device modem-device

0 commit comments

Comments
 (0)