blob: 34d1f93cf940436c0b73442b0e7fa12c3d0c3ba1 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
|
#!/usr/bin/python
import dbus
bus = dbus.SystemBus()
manager = dbus.Interface(bus.get_object("org.moblin.connman", "/"),
"org.moblin.connman.Manager")
properties = manager.GetProperties()
for path in properties["Connections"]:
connection = dbus.Interface(bus.get_object("org.moblin.connman", path),
"org.moblin.connman.Connection")
properties = connection.GetProperties()
if (properties["Default"] == dbus.Boolean(1)):
continue
print "[ %s ]" % (path)
connection.SetProperty("Default", dbus.Boolean(1))
|