From 1ec403d2b4211e8d2c0d83485c43eacaf0d0242c Mon Sep 17 00:00:00 2001 From: David Gauchard Date: Thu, 21 Feb 2019 16:06:09 +0100 Subject: [PATCH 1/2] fix sdk changes with host emulation --- tests/host/common/user_interface.cpp | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/tests/host/common/user_interface.cpp b/tests/host/common/user_interface.cpp index c15e3759b9..47221accac 100644 --- a/tests/host/common/user_interface.cpp +++ b/tests/host/common/user_interface.cpp @@ -84,7 +84,9 @@ bool wifi_station_get_config (struct station_config *config) config->bssid[i] = i; config->threshold.rssi = 1; config->threshold.authmode = AUTH_WPA_PSK; +#ifndef NONOSDK221 config->open_and_wep_mode_disable = true; +#endif return true; } @@ -190,11 +192,15 @@ uint8 wifi_get_opmode_default (void) return STATION_MODE; } +#ifndef NONOSDK221 + sleep_level_t wifi_get_sleep_level (void) { return MIN_SLEEP_T; } +#endif // nonos-sdk-pre-3 + sleep_type_t wifi_get_sleep_type (void) { return NONE_SLEEP_T; @@ -242,6 +248,8 @@ bool wifi_set_phy_mode (phy_mode_t mode) return true; } +#ifndef NONOSDK221 + bool wifi_set_sleep_level (sleep_level_t level) { (void)level; @@ -254,6 +262,8 @@ bool wifi_set_sleep_type (sleep_type_t type) return true; } +#endif + bool wifi_station_connect (void) { return true; From 7ad4714141e4f108248e9e0318f5afa5173325d7 Mon Sep 17 00:00:00 2001 From: David Gauchard Date: Thu, 21 Feb 2019 16:12:04 +0100 Subject: [PATCH 2/2] wifi_set_sleep_type is in sdk221 --- tests/host/common/user_interface.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tests/host/common/user_interface.cpp b/tests/host/common/user_interface.cpp index 47221accac..936eb075ff 100644 --- a/tests/host/common/user_interface.cpp +++ b/tests/host/common/user_interface.cpp @@ -256,14 +256,14 @@ bool wifi_set_sleep_level (sleep_level_t level) return true; } +#endif + bool wifi_set_sleep_type (sleep_type_t type) { (void)type; return true; } -#endif - bool wifi_station_connect (void) { return true;