force start wifi

This commit is contained in:
Miguel Fuertes committed 2025-10-04 01:06:06 +02:00
1 parent 269a29ff71
commit 8a18c714d0
1 file changed
+13 -4
+13 -4
View File
@@ -1,10 +1,10 @@
#!/bin/sh
# Enabling Wifi
# Enabling WiFi
uci set wireless.@wifi-device[0].disabled='0'
uci set wireless.@wifi-iface[0].disabled='0'
# create modem interface
# Create modem interface
uci set network.modem=interface
uci set network.modem.proto='modemmanager'
uci set network.modem.device='qcom-soc'
@@ -16,8 +16,17 @@ uci set network.modem.ifname='wwan0'
uci del_list firewall.@zone[1].network='modem'
uci add_list firewall.@zone[1].network='modem'
# We commit all the changes and restart network
# Commit all changes
uci commit
# Reload WiFi driver to load firmware
logger -t uci-defaults "Reloading wcn36xx driver"
rmmod wcn36xx 2>/dev/null || true
sleep 1
modprobe wcn36xx
# Apply network and wireless configuration
wifi reload
/etc/init.d/network restart
exit 0
exit 0