From 20b7f057214a9edcda554c50ebec99e51f9756ed Mon Sep 17 00:00:00 2001 From: Bartek Szatkowski Date: Wed, 16 Nov 2016 12:00:09 +0000 Subject: [PATCH] WiFi: Make WiFi default networking interface on Odin board That disables Ethernet by default and makes sure the Ethernet tests are not failing when it's disabled. --- .../FEATURE_LWIP/TESTS/mbedmicro-net/gethostbyname/main.cpp | 5 ++++- .../TESTS/mbedmicro-net/nist_internet_time_service/main.cpp | 4 ++++ .../TESTS/mbedmicro-net/tcp_client_echo/main.cpp | 4 ++++ .../TESTS/mbedmicro-net/tcp_client_hello_world/main.cpp | 4 ++++ .../TESTS/mbedmicro-net/udp_echo_client/main.cpp | 4 ++++ targets/targets.json | 2 +- 6 files changed, 21 insertions(+), 2 deletions(-) diff --git a/features/FEATURE_LWIP/TESTS/mbedmicro-net/gethostbyname/main.cpp b/features/FEATURE_LWIP/TESTS/mbedmicro-net/gethostbyname/main.cpp index 7ae6ca8948..8609a71da2 100644 --- a/features/FEATURE_LWIP/TESTS/mbedmicro-net/gethostbyname/main.cpp +++ b/features/FEATURE_LWIP/TESTS/mbedmicro-net/gethostbyname/main.cpp @@ -1,3 +1,7 @@ +#if DEVICE_EMAC + #error [NOT_SUPPORTED] Not supported for WiFi targets +#endif + #include "mbed.h" #include "greentea-client/test_env.h" #include "unity.h" @@ -6,7 +10,6 @@ using namespace utest::v1; - // Hostname for testing against // Must have A and AAAA records #ifndef MBED_DNS_TEST_HOST diff --git a/features/FEATURE_LWIP/TESTS/mbedmicro-net/nist_internet_time_service/main.cpp b/features/FEATURE_LWIP/TESTS/mbedmicro-net/nist_internet_time_service/main.cpp index 730f8d3511..9324d975c9 100644 --- a/features/FEATURE_LWIP/TESTS/mbedmicro-net/nist_internet_time_service/main.cpp +++ b/features/FEATURE_LWIP/TESTS/mbedmicro-net/nist_internet_time_service/main.cpp @@ -2,6 +2,10 @@ #error [NOT_SUPPORTED] LWIP not supported for this target #endif +#if DEVICE_EMAC + #error [NOT_SUPPORTED] Not supported for WiFi targets +#endif + #include "mbed.h" #include "EthernetInterface.h" #include "UDPSocket.h" diff --git a/features/FEATURE_LWIP/TESTS/mbedmicro-net/tcp_client_echo/main.cpp b/features/FEATURE_LWIP/TESTS/mbedmicro-net/tcp_client_echo/main.cpp index d5c4abcf1d..3b09657fbc 100644 --- a/features/FEATURE_LWIP/TESTS/mbedmicro-net/tcp_client_echo/main.cpp +++ b/features/FEATURE_LWIP/TESTS/mbedmicro-net/tcp_client_echo/main.cpp @@ -2,6 +2,10 @@ #error [NOT_SUPPORTED] LWIP not supported for this target #endif +#if DEVICE_EMAC + #error [NOT_SUPPORTED] Not supported for WiFi targets +#endif + #include "mbed.h" #include "EthernetInterface.h" #include "TCPSocket.h" diff --git a/features/FEATURE_LWIP/TESTS/mbedmicro-net/tcp_client_hello_world/main.cpp b/features/FEATURE_LWIP/TESTS/mbedmicro-net/tcp_client_hello_world/main.cpp index fb4d39f388..38d0dba53d 100644 --- a/features/FEATURE_LWIP/TESTS/mbedmicro-net/tcp_client_hello_world/main.cpp +++ b/features/FEATURE_LWIP/TESTS/mbedmicro-net/tcp_client_hello_world/main.cpp @@ -2,6 +2,10 @@ #error [NOT_SUPPORTED] LWIP not supported for this target #endif +#if DEVICE_EMAC + #error [NOT_SUPPORTED] Not supported for WiFi targets +#endif + #include #include "mbed.h" #include "EthernetInterface.h" diff --git a/features/FEATURE_LWIP/TESTS/mbedmicro-net/udp_echo_client/main.cpp b/features/FEATURE_LWIP/TESTS/mbedmicro-net/udp_echo_client/main.cpp index 5c7f208d1b..cb91d4fb91 100644 --- a/features/FEATURE_LWIP/TESTS/mbedmicro-net/udp_echo_client/main.cpp +++ b/features/FEATURE_LWIP/TESTS/mbedmicro-net/udp_echo_client/main.cpp @@ -2,6 +2,10 @@ #error [NOT_SUPPORTED] LWIP not supported for this target #endif +#if DEVICE_EMAC + #error [NOT_SUPPORTED] Not supported for WiFi targets +#endif + #include "mbed.h" #include "EthernetInterface.h" #include "UDPSocket.h" diff --git a/targets/targets.json b/targets/targets.json index 7b85a8d2cb..b70bbcc707 100644 --- a/targets/targets.json +++ b/targets/targets.json @@ -1292,7 +1292,7 @@ "extra_labels": ["STM", "STM32F4", "STM32F439", "STM32F439ZI","STM32F439xx"], "macros": ["HSE_VALUE=24000000", "HSE_STARTUP_TIMEOUT=5000", "CB_INTERFACE_SDIO","CB_CHIP_WL18XX","SUPPORT_80211D_ALWAYS","WLAN_ENABLED","MBEDTLS_ARC4_C","MBEDTLS_DES_C","MBEDTLS_MD4_C","MBEDTLS_MD5_C","MBEDTLS_SHA1_C"], "inherits": ["Target"], - "device_has": ["ANALOGIN", "CAN", "I2C", "I2CSLAVE", "INTERRUPTIN", "PORTIN", "PORTINOUT", "PORTOUT", "PWMOUT", "SERIAL", "SLEEP", "SPI", "SPISLAVE", "STDIO_MESSAGES", "TRNG"], + "device_has": ["ANALOGIN", "CAN", "EMAC", "I2C", "I2CSLAVE", "INTERRUPTIN", "PORTIN", "PORTINOUT", "PORTOUT", "PWMOUT", "SERIAL", "SLEEP", "SPI", "SPISLAVE", "STDIO_MESSAGES", "TRNG"], "features": ["LWIP"], "release_versions": ["5"], "device_name": "STM32F439ZI"