I finally found a solution :
Whatever you use to create your current connection, just recreate a new object using the object name of the current connection. In the following example 'WLAN' is the current running object ( create something like an alias ) and use it to disconnect :
Whatever you use to create your current connection, just recreate a new object using the object name of the current connection. In the following example 'WLAN' is the current running object ( create something like an alias ) and use it to disconnect :
Code:
nic = network.WLAN(network.STA_IF) print("WLAN PROPERTIES : ", nic) nic.disconnect() nic.active(False) nic.deinit() print("WLAN PROPERTIES : ", nic)Statistics: Posted by jcd95 — Sun May 04, 2025 4:06 pm