Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/Duet3D/RepRapFirmware.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'src/Networking/ESP8266WiFi/WiFiInterface.cpp')
-rw-r--r--src/Networking/ESP8266WiFi/WiFiInterface.cpp13
1 files changed, 11 insertions, 2 deletions
diff --git a/src/Networking/ESP8266WiFi/WiFiInterface.cpp b/src/Networking/ESP8266WiFi/WiFiInterface.cpp
index ba4aec9a..a0ca3dbe 100644
--- a/src/Networking/ESP8266WiFi/WiFiInterface.cpp
+++ b/src/Networking/ESP8266WiFi/WiFiInterface.cpp
@@ -25,7 +25,7 @@ static_assert(SsidLength == SsidBufferLength, "SSID lengths in NetworkDefs.h and
// Define exactly one of the following as 1, the other as zero
-#if defined(DUET_NG)
+#if SAM4E
# include <pmc/pmc.h>
# include <spi/spi.h>
@@ -36,7 +36,7 @@ static_assert(SsidLength == SsidBufferLength, "SSID lengths in NetworkDefs.h and
# define USE_DMAC_MANAGER 0 // use SAMD/SAME DMA controller via DmacManager module
# define USE_XDMAC 0 // use SAME7 XDMA controller
-#elif defined(DUET3_MB6HC)
+#elif SAME70
# include <pmc/pmc.h>
# include <spi/spi.h>
@@ -47,6 +47,9 @@ static_assert(SsidLength == SsidBufferLength, "SSID lengths in NetworkDefs.h and
# define USE_DMAC_MANAGER 0 // use SAMD/SAME DMA controller via DmacManager module
# define USE_XDMAC 1 // use SAME7 XDMA controller
+static __nocache MessageBufferOut messageBufferOut;
+static __nocache MessageBufferIn messageBufferIn;
+
#elif SAME5x
# include <DmacManager.h>
@@ -467,8 +470,14 @@ void WiFiInterface::Activate() noexcept
{
activated = true;
+#if SAME70
+ bufferOut = &messageBufferOut;
+ bufferIn = &messageBufferIn;
+#else
bufferOut = new MessageBufferOut;
bufferIn = new MessageBufferIn;
+#endif
+
#if HAS_MASS_STORAGE || HAS_EMBEDDED_FILES
uploader = new WifiFirmwareUploader(SERIAL_WIFI_DEVICE, *this);
#endif