mirror of
https://github.com/Doodle3D/doodle3d-firmware.git
synced 2024-12-22 02:53:49 +01:00
Fixed check to see if it has to switch to ap mode
This commit is contained in:
parent
7397066ad9
commit
4160441a4b
@ -9,9 +9,13 @@ if [ "$SEEN" -lt 1 ]
|
||||
then
|
||||
#see https://github.com/Doodle3D/doodle3d-firmware/blob/master/src/network/wlanconfig.lua#L188 for reference
|
||||
#check if network on top is in STA mode
|
||||
if [ $(uci get wireless.@wifi-iface[0].mode) == "sta" ];
|
||||
if [ $(uci get wireless.@wifi-iface[1].mode) == "ap" ]
|
||||
then
|
||||
logger "switching to AP"
|
||||
if [ $(uci get wireless.@wifi-iface[1].network) != "wlan" ] #edge case when only the factory default openwrt network is available
|
||||
then
|
||||
uci set wireless.@wifi-iface[1].network=wlan
|
||||
fi
|
||||
#configure dhcp
|
||||
uci delete network.wlan
|
||||
uci set network.wlan=interface
|
||||
|
Loading…
Reference in New Issue
Block a user