From b68f6560b97498a23a706f398596f39866ff5c82 Mon Sep 17 00:00:00 2001 From: Thomas Waldmann Date: Tue, 12 Dec 2017 02:05:11 +0100 Subject: [PATCH] rename check_connection -> get_connection --- main.py | 2 +- networkconfig.py | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/main.py b/main.py index 313472c..819aa15 100644 --- a/main.py +++ b/main.py @@ -1,7 +1,7 @@ import networkconfig -wlan = networkconfig.check_connection() +wlan = networkconfig.get_connection() if wlan is None: print("Could not initialize the network connection.") while True: diff --git a/networkconfig.py b/networkconfig.py index 16c3033..22af648 100644 --- a/networkconfig.py +++ b/networkconfig.py @@ -16,7 +16,8 @@ wlan_sta = network.WLAN(network.STA_IF) server_socket = None -def check_connection(): +def get_connection(): + """return a working WLAN(STA_IF) instance or None""" global wlan_sta # First check if there already is any connection: