wifi: fix #1181
This commit is contained in:
parent
6eefe9d465
commit
b10f6a65ff
@ -20,7 +20,8 @@ class Panel(ScreenPanel):
|
||||
self.update_timeout = None
|
||||
self.network_interfaces = netifaces.interfaces()
|
||||
self.wireless_interfaces = [
|
||||
iface for iface in self.network_interfaces if iface.startswith('w') and not iface.startswith('wwan')
|
||||
iface for iface in self.network_interfaces
|
||||
if iface.startswith('wlan') or iface.startswith('wlp')
|
||||
]
|
||||
self.wifi = None
|
||||
self.use_network_manager = os.system('systemctl is-active --quiet NetworkManager.service') == 0
|
||||
@ -32,7 +33,7 @@ class Panel(ScreenPanel):
|
||||
else:
|
||||
logging.info("Using wpa_cli")
|
||||
from ks_includes.wifi import WifiManager
|
||||
self.wifi = WifiManager(self.wireless_interfaces[-1])
|
||||
self.wifi = WifiManager(self.wireless_interfaces[0])
|
||||
|
||||
# Get IP Address
|
||||
gws = netifaces.gateways()
|
||||
|
Loading…
x
Reference in New Issue
Block a user