commit 3402f5994b7b01e3cad32d3411877dd0f79cdf4e
parent 518808c70944fa6b20e3e9afb1dea4420350ee8c
Author: James Prestwood <prestwoj@gmail.com>
Date: Thu, 12 Aug 2021 13:21:55 -0700
auto-t: iwd.py: add connect_bssid() method
Python API for ConnectBssid() developer method
Diffstat:
1 file changed, 7 insertions(+), 0 deletions(-)
diff --git a/autotests/util/iwd.py b/autotests/util/iwd.py
@@ -39,6 +39,7 @@ IWD_P2P_INTERFACE = 'net.connman.iwd.p2p.Device'
IWD_P2P_PEER_INTERFACE = 'net.connman.iwd.p2p.Peer'
IWD_P2P_SERVICE_MANAGER_INTERFACE = 'net.connman.iwd.p2p.ServiceManager'
IWD_P2P_WFD_INTERFACE = 'net.connman.iwd.p2p.Display'
+IWD_STATION_DEBUG_INTERFACE = 'net.connman.iwd.StationDebug'
IWD_AGENT_MANAGER_PATH = '/net/connman/iwd'
IWD_TOP_LEVEL_PATH = '/'
@@ -535,6 +536,12 @@ class Device(IWDDBusAbstract):
def stop_adhoc(self):
self._prop_proxy.Set(IWD_DEVICE_INTERFACE, 'Mode', 'station')
+ def connect_bssid(self, address):
+ self._station_debug_if = dbus.Interface(self._bus.get_object(IWD_SERVICE,
+ self.device_path),
+ IWD_STATION_DEBUG_INTERFACE)
+ self._station_debug_if.ConnectBssid(dbus.ByteArray.fromhex(address.replace(':', '')))
+
def __str__(self, prefix = ''):
return prefix + 'Device: ' + self.device_path + '\n'\
+ prefix + '\tName:\t\t' + self.name + '\n'\