diff options
author | David Crocker <dcrocker@eschertech.com> | 2022-09-20 11:17:48 +0300 |
---|---|---|
committer | David Crocker <dcrocker@eschertech.com> | 2022-09-23 15:45:44 +0300 |
commit | f966947e7eb87154b09716fda3f716a2a486564a (patch) | |
tree | 4607daf01769fffe49e426a06da9ab09cde1b97c | |
parent | e73b4fbe803033d2fc6e9f3193ae2b5bb1c9e08b (diff) |
Added WIFI_USES_ESP32 configuration definition
-rw-r--r-- | src/Config/Pins.h | 4 | ||||
-rw-r--r-- | src/Config/Pins_Duet3_MB6HC.h | 1 | ||||
-rw-r--r-- | src/Networking/ESP8266WiFi/WiFiInterface.cpp | 2 |
3 files changed, 6 insertions, 1 deletions
diff --git a/src/Config/Pins.h b/src/Config/Pins.h index 69d7f45d..7e34e13d 100644 --- a/src/Config/Pins.h +++ b/src/Config/Pins.h @@ -153,6 +153,10 @@ # define HAS_WIFI_NETWORKING 0 #endif +#if HAS_WIFI_NETWORKING && !defined(WIFI_USES_ESP32) +# define WIFI_USES_ESP32 0 +#endif + #ifndef HAS_W5500_NETWORKING # define HAS_W5500_NETWORKING 0 #endif diff --git a/src/Config/Pins_Duet3_MB6HC.h b/src/Config/Pins_Duet3_MB6HC.h index 9d41ac77..ba4f363f 100644 --- a/src/Config/Pins_Duet3_MB6HC.h +++ b/src/Config/Pins_Duet3_MB6HC.h @@ -20,6 +20,7 @@ constexpr uint32_t IAP_IMAGE_START = 0x20458000; // last 32kb of RAM // Networking support #define HAS_LWIP_NETWORKING 1 #define HAS_WIFI_NETWORKING 1 +#define WIFI_USES_ESP32 1 // Storage support #define HAS_SBC_INTERFACE 1 diff --git a/src/Networking/ESP8266WiFi/WiFiInterface.cpp b/src/Networking/ESP8266WiFi/WiFiInterface.cpp index f54a52a9..ba4aec9a 100644 --- a/src/Networking/ESP8266WiFi/WiFiInterface.cpp +++ b/src/Networking/ESP8266WiFi/WiFiInterface.cpp @@ -2039,7 +2039,7 @@ void WiFiInterface::StartWiFi() noexcept SetPinFunction(APIN_SerialWiFi_RXD, SerialWiFiPeriphMode); // connect the pins to the UART #endif -#if defined(DUET3_MB6HC) +#if WIFI_USES_ESP32 SERIAL_WIFI_DEVICE.begin(WiFiBaudRate_ESP32); // initialise the UART, to receive debug info #else SERIAL_WIFI_DEVICE.begin(WiFiBaudRate); // initialise the UART, to receive debug info |