<p>After having looked into them, these boards certainly seem to be rather interesting.</p>

<p>There appear to be two varieties of this board, as I have seen photos with either <em>RobotDyn</em>:</p>

<p><a href="https://i.sstatic.net/l7vGQ.jpg" rel="nofollow noreferrer" title="RobotDyn board"><img src="https://i.sstatic.net/l7vGQ.jpg" alt="RobotDyn board" title="RobotDyn board"></a></p>

<p>rear (from Instructables)</p>

<p><a href="https://i.sstatic.net/rwceY.jpg" rel="nofollow noreferrer" title="RobotDyn board (rear)"><img src="https://i.sstatic.net/rwceY.jpg" alt="RobotDyn board (rear)" title="RobotDyn board (rear)"></a></p>

<p>or <em>WeMos</em> logos on them. </p>

<p><a href="https://i.sstatic.net/62P2A.jpg" rel="nofollow noreferrer" title="WeMos board"><img src="https://i.sstatic.net/62P2A.jpg" alt="WeMos board" title="WeMos board"></a></p>

<p>They <em>may</em>, or <em>may not</em>, be the same. There is also this one, with just a generic "WiFi" logo (from the eBay page below):</p>

<p><a href="https://i.sstatic.net/ybdWZ.jpg" rel="nofollow noreferrer" title="Generic board"><img src="https://i.sstatic.net/ybdWZ.jpg" alt="Generic board" title="Generic board"></a></p>

<h2>Memory Discrepancies</h2>

<p>However, there is certainly some discrepancy relating to the specification and amount of memory (unless there are a number of variants - which would certainly be possible):</p>

<ul>
<li>4&nbsp;MB of Flash is in the ESP8266-12, as <a href="https://3dprinting.stackexchange.com/questions/6316/arduino-wemos-and-ramps#comment9539_6316">Dan states</a>, see <a href="https://shop.pimoroni.com/products/esp8266-smt-module-esp-12" rel="nofollow noreferrer">ESP8266 SMT Module - ESP-12</a>. But is it the ESP8266-12 in the board, or is it another ESP variant?</li>
<li>This <strong>WeMos</strong> product, on eBay, <a href="https://www.ebay.com/itm/WeMOS-Mega-WiFi-R3-ATmega2560-ESP8266-USB-TTL-For-Arduino-Mega-NodeMCU-/263689252053" rel="nofollow noreferrer">WeMOS Mega + WiFi R3 ATmega2560 + ESP8266 USB-TTL For Arduino Mega NodeMCU</a> appears to agree with the 32&nbsp;Mb<sup>1</sup> </li>
<li>This <strong>RobotDyn</strong> board, <a href="https://robotdyn.ru/catalog/arduino/boards/kontroller_arduino_mega_revizii_r3_s_integrirovannym_chipom_wifi_esp8266_b_8_mb_pamyati.html" rel="nofollow noreferrer">Контроллер RobotDyn Mega 2560 R3 + WiFi ESP8266b, flash память 8Mbit, USB-TTL CH340G, MicroUSB</a>, has 8&nbsp;Mb apparently. </li>
<li>However the <strong>same</strong> product page, but in English, upgrades the memory to 32 MB! See <a href="https://robotdyn.com/mega-wifi-r3-atmega2560-esp8266-flash-32mb-usb-ttl-ch340g-micro-usb.html" rel="nofollow noreferrer">MEGA+WiFi R3 ATmega2560+ESP8266, flash 32MB, USB-TTL CH340G, Micro-USB</a></li>
</ul>

<p>Looking at this article, Instructables - <a href="https://www.instructables.com/id/Arduino-MEGA-2560-With-WiFi-Built-in-ESP8266/" rel="nofollow noreferrer">Arduino MEGA 2560 With WiFi Built-in - ESP8266</a>, it isn't <em>exactly</em> the ESP8266-12:</p>

<blockquote>
  <p>In today's text, we discuss an Arduino that I consider extremely special, as it has an ESP8266 embedded in its board. It doesn’t have the ESP12 soldered onto the board. Instead, it has the Espressif chip. So, on the board you have the built-in Tensilica chip with 4MB of memory, along with the ATmega2560, which is the traditional Arduino Mega.</p>
</blockquote>

<p>So the ESP has 4&nbsp;MB, but where does the 32&nbsp;Mb come in to play?</p>

<p>Well, looking at this RobotDyn memory table (taken from the Instructables page):</p>

<p><a href="https://i.sstatic.net/oAmbU.jpg" rel="nofollow noreferrer" title="RobotDyn memory table"><img src="https://i.sstatic.net/oAmbU.jpg" alt="RobotDyn memory table" title="RobotDyn memory table"></a></p>

<p>The 4&nbsp;MB of the ESP appears to have been immediately contradicted and upgraded to 8&nbsp;MB! The ATmega2560 <em>somehow</em> has 32&nbsp;Mb (which seems a bit of a lie - as there isn't an ATmega2560 <em>known to man</em> that has that much memory<sup>2</sup>), and is confused further by the corresponding text:</p>

<blockquote>
  <p>As we see in the table above, the ATmega has 32MB of memory, not counting the ESP memory. This is wonderful, since the traditional Mega Arduino has only 256kb of memory. </p>
</blockquote>

<p>So <code>MB</code> or <code>Mb</code>? Is there an additional flash IC external to the ATmega2560? Looking at the schematic, taken from the Russian RobotDyn page, there doesn't appear to be:</p>

<p><a href="https://i.sstatic.net/dX5UC.png" rel="nofollow noreferrer" title="RobotDyn schematic"><img src="https://i.sstatic.net/dX5UC.png" alt="RobotDyn schematic" title="RobotDyn schematic"></a></p>

<p>So this could be nonsense. Logic would dictate that the ATmega has 256&nbsp;kB and the ESP has 4&nbsp;MB... But I could be wrong..?</p>

<p>Links from <a href="https://robotdyn.ru/catalog/arduino/boards/kontroller_arduino_mega_revizii_r3_s_integrirovannym_chipom_wifi_esp8266_b_8_mb_pamyati.html" rel="nofollow noreferrer">Контроллер RobotDyn Mega 2560 R3 + WiFi ESP8266b, flash память 8Mbit, USB-TTL CH340G, MicroUSB</a>:</p>

<ul>
<li>Schematic (<a href="https://robotdyn.ru/upload/PHOTO/0G-00005302==MEGA+WiFi-R3-AT2560-ESP8266-8MB-CH340G/DOCS/Schematic==0G-00005302==MEGA+WiFi-R3-AT2560-ESP8266-8MB-CH340G.pdf" rel="nofollow noreferrer">PDF</a>)</li>
<li>Pin out (<a href="https://robotdyn.ru/upload/PHOTO/0G-00005302==MEGA+WiFi-R3-AT2560-ESP8266-8MB-CH340G/DOCS/PINOUT==0G-00005302==MEGA+WiFi-R3-AT2560-ESP8266-8MB-CH340G.pdf" rel="nofollow noreferrer">PDF</a>) (<a href="https://robotdyn.ru/upload/PHOTO/0G-00005302==MEGA+WiFi-R3-AT2560-ESP8266-8MB-CH340G/DOCS/PINOUT==0G-00005302==MEGA+WiFi-R3-AT2560-ESP8266-8MB-CH340G.jpg" rel="nofollow noreferrer">JPG</a>)</li>
<li>Mechanics (<a href="https://robotdyn.ru/upload/PHOTO/0G-00005302==MEGA+WiFi-R3-AT2560-ESP8266-8MB-CH340G/DOCS/DIM==0G-00005302==MEGA+WiFi-R3-AT2560-ESP8266-8MB-CH340G.pdf" rel="nofollow noreferrer">PDF</a>) (<a href="https://robotdyn.ru/upload/PHOTO/0G-00005302==MEGA+WiFi-R3-AT2560-ESP8266-8MB-CH340G/DOCS/DIM==0G-00005302==MEGA+WiFi-R3-AT2560-ESP8266-8MB-CH340G.jpg" rel="nofollow noreferrer">JPG</a>)</li>
</ul>

<hr>

<h2>Reliability of communication</h2>

<p>Regardless of the actual spec, to address your question of ESP/Arduino communication reliability:</p>

<p>As the ESP8266 and the ATmega2560 are on the <em>same</em> board one would assume that the (serial) communication between the two would be faultless. However, some issues have been reported<sup>3</sup>. </p>

<p>Nevertheless, from your question, it seems that you were having issues with the ESP to the OctoPi communication, rather than ESP to Arduino, so maybe this doesn't actually answer your question.</p>

<p>Also, as to their compatibility with RAMPS, there is very little information available currently, and it would seem to be a case of try-it-and-see. The closest I got was <a href="https://groups.io/g/onstep/message/154" rel="nofollow noreferrer">this post</a> on the thread, <a href="https://groups.io/g/onstep/topic/onstep_and_ramps1_4/7358494?p=Created,,,20,2,0,0::,,,0,0,0,7358494&amp;jump=1" rel="nofollow noreferrer">OnStep and RAMPS1.4</a>, but it seems to be spam. </p>

<p>However, it certainly sounds worth a gamble as it would be a nice combination of technologies. However, I would imagine that some modification of the firmware would be necessary.</p>

<hr>

<h2>Useful Notes</h2>

<ul>
<li>From <a href="https://forum.arduino.cc/index.php?topic=464400.msg3485996#msg3485996" rel="nofollow noreferrer">post #8</a> of Mega + WiFi R3 ATmega2560 + ESP8266 (8 Mb mémoire)</li>
</ul>

<blockquote>
  <p>To upload the sketch to the board:</p>

<pre><code>5, 6, 7 ON
RXD3 - TXD3   
</code></pre>
  
  <p>To run the sketch:</p>

<pre><code>5 and 6 ON
RXD3 - TXD3
</code></pre>
</blockquote>

<ul>
<li>Here is an <a href="http://www.sysengineering.ru/blog/%D1%8D%D0%BB%D0%B5%D0%BA%D1%82%D1%80%D0%BE%D0%BD%D0%B8%D0%BA%D0%B0-%D0%BA%D0%BE%D0%BD%D1%82%D1%80%D0%BE%D0%BB%D0%BB%D0%B5%D1%80-arduino-mega-%D1%81-esp8266/" rel="nofollow noreferrer">excellent manual in Russian</a></li>
</ul>

<hr>

<h2>Footnotes</h2>

<p><sup>1</sup>  From <a href="https://www.ebay.com/itm/WeMOS-Mega-WiFi-R3-ATmega2560-ESP8266-USB-TTL-For-Arduino-Mega-NodeMCU-/263689252053" rel="nofollow noreferrer">WeMOS Mega + WiFi R3 ATmega2560 + ESP8266 USB-TTL For Arduino Mega NodeMCU</a></p>

<blockquote>
  <h3>WeMOS Mega + WiFi R3 ATmega2560 + ESP8266 USB-TTL For Arduino Mega NodeMCU 　</h3>
  
  <p>Features:</p>
  
  <ul>
  <li>Full integration on one board: Mega R3 ATmega2560 and WiFi ESP8266 with memory 32Mb (megabyte)</li>
  <li>All of the modules can work together or each separately. And everyone has their own pinout headers</li>
  <li><p>The convenient solution for the development of new projects requiring Uno and WiFi </p></li>
  <li><p>Via USB you can update sketches and firmware for ATmega2560 and for ESP8266. For this on board have the USB-serial converter CH340G</p></li>
  <li>Use this board is very simple</li>
  <li>The board has DIP-switch, to connect the modules. For example to:
  
  <ul>
  <li>USB and ATmeg2560, </li>
  <li>USB and ESP8266, </li>
  <li>ATmega2560 and ESP8266</li>
  </ul></li>
  </ul>
  
  <p>Table DIP- Switch:</p>

<pre><code>Connection                                                          DIP
                                           1        2        3         4       5         6        7
ATmega2560&lt;-&gt;ESP8266                      ON       ON       OFF       OFF     OFF       OFF      OFF
USB &lt;-&gt;ATmega2560                         OFF      OFF      ON        ON      OFF       OFF      OFF
USB&lt;-&gt;ESP8266 (Update firmware or sketch) OFF      OFF      OFF       OFF     ON        ON       ON
USB&lt;-&gt;ESP8266 (communication)             OFF      OFF      OFF       OFF     ON        ON       OFF
All independent                           OFF      OFF      OFF       OFF     OFF       OFF      OFF

Special solution:
USB &lt;-&gt;ATmega328&lt;-&gt; ESP8266
Connection                                                          DIP                                     SWITCH 2
                                           1        2        3         4       5         6        7

USB &lt;-&gt; ATmega2560&lt;-&gt; ESP8266             ON       ON       ON        ON      OFF       OFF      OFF         To RXD3/TXD3
</code></pre>
  
  <ul>
  <li>USB converter CH340G connect to RX0/TX0 of ATmega2560</li>
  <li>ESP8266 connect to RX3/TX3 of ATmega2560</li>
  </ul>
  
  <p>Size: 10.5x5.3cm/4.13x2.09inch</p>
</blockquote>

<p><sup>2</sup> From the <a href="http://ww1.microchip.com/downloads/en/DeviceDoc/Atmel-2549-8-bit-AVR-Microcontroller-ATmega640-1280-1281-2560-2561_datasheet.pdf" rel="nofollow noreferrer">Atmel ATmega640/V-1280/V
-1281/V-2560/V-2561/V datasheet</a></p>

<blockquote>
  <p><a href="https://i.sstatic.net/4zAjV.png" rel="nofollow noreferrer"><img src="https://i.sstatic.net/4zAjV.png" alt="ATmega256 memory"></a></p>
</blockquote>

<p><sup>3</sup> From <a href="https://forum.arduino.cc/index.php?topic=464400.0" rel="nofollow noreferrer">Mega + WiFi R3 ATmega2560 + ESP8266 (8 Mb mémoire)</a>, there <em>do</em> appear to be some issues communicating between the ATmega and the ESP ICs, with a number of users reporting problems. </p>

<p>However, a couple of solutions are provided:</p>

<h3>Solution 1</h3>

<p>From <a href="https://forum.arduino.cc/index.php?topic=464400.msg3220188#msg3220188" rel="nofollow noreferrer">post #2</a></p>

<blockquote>
  <ol>
  <li><p>Set the DIP switch to "special" mode: (<code>1=on, 2=on, 3=on, 4=on, 5=off, 6=off, 7=off, 8=off</code>) see the the description of <a href="http://www.ebay.com/itm/Mega-WiFi-R3-ATmega2560-ESP8266-USB-TTL-Arduino-Mega-NodeMCU-WeMos-ESP8266-/222305385421" rel="nofollow noreferrer">the
  product</a>.</p></li>
  <li><p>Set the switch in RXD3</p></li>
  <li>Run the below sketch, change the SSID and PASSWORD values. this is just to test that Arduino and ESP8266 are working together. The code
  originated from BISSA ORBOEA in Element14.</li>
  </ol>
  
  <p>Code:</p>

<pre><code>#include "ESP8266.h"

#define SSID        "YOURSID"
#define PASSWORD    "YOURPASSWORD"

ESP8266 wifi(Serial3,115200);

void setup() {


  Serial.begin(9600);              

  Serial.println("Restart");
  wifi.restart();
  delay(1000);

  Serial.println("FW Version:");
  Serial.println(wifi.getVersion().c_str());

    if (wifi.setOprToStation()) {
        Serial.println("OprToStation ok");    }
        else {
        Serial.println("OprToStation  err");
    }

    if (wifi.joinAP(SSID, PASSWORD)) {
        Serial.println("Join AP success");

        Serial.print("IP:");
        Serial.println( wifi.getLocalIP().c_str());      
    } else {
        Serial.println("Join AP failure");
    }
}


void loop()
{
}
</code></pre>
</blockquote>

<h3>Solution 2</h3>

<p>From <a href="https://forum.arduino.cc/index.php?topic=464400.msg3301552#msg3301552" rel="nofollow noreferrer">post #6</a></p>

<blockquote>
  <p>First you need to write the code for each board according your
  application, but in your code you need to establish a commmincation
  between serial port of Atmega and ESP in both code, again in according
  you application. Finally, put the switches which make the intenal
  interconnection between both. </p>
  
  <p>For example, I made a code for ESP to connect in an Access Point and
  put on a TCP server. When a wireless client is connected in ESP and
  consequently in the TCP Server, all data send by client I redirect to
  the serial port. As serial port of ESP is connected with serial 3 of
  the Atmega, the code in Atmega pass to theat the data from serial 3.</p>
</blockquote>

<h3>Solution 3</h3>

<p>From <a href="https://forum.arduino.cc/index.php?topic=464400.msg3500882#msg3500882" rel="nofollow noreferrer">post #11</a></p>

<blockquote>
  <p>Follow this if you have the same to my cases:</p>
  
  <ol>
  <li>programm to the ESP(upload sketch) for wifi connection by configure the DIP to 5:on,6:on,7:on and other off.</li>
  <li>program to mega(upload sketch) in case you want to send communication to each other by configure Dip to 3:on,4:on, and other
  off.</li>
  <li>switch two  RX0/TX0(in my case I use Serial.print() and Serial.readString() for communicate between Esp and Mega)</li>
  <li><p>after you already upload sketch to both Modules you can test communication between them by configure DIP to: 1:on,2:on,3:on,4:on.
  and then press Reset Button to restart the boards.</p></li>
  <li><p>In ESP you can get the string from Mega by  if(Serial.available()) Serial.readString();  and In mega you can get data from ESP by :
  if(Serial.available())Serial.readString().  </p></li>
  <li>After you got a string so you can split or do anything whatever you want. </li>
  <li>If you want send data to Firebase you must use the Firebase Library at the Esp side, in Mega it not support.</li>
  </ol>
</blockquote>

CC BY-SA 4.0
2018-07-31T21:04:28.883Z
thanks a lot for that compilation. will buy one and see how it works.
profesor79
CC BY-SA 4.0
2018-07-31T21:05:48.540Z
Yeah, I want to get one. I've just updated my answer with a reasonably accurate sounding description. I will continue to look for a RAMPS use case.
Greenonline
CC BY-SA 4.0
2018-08-01T06:57:36.533Z
Great post, you want to make me buy that board! :D
0scar
CC BY-SA 4.0
2018-08-01T07:05:10.617Z
@0scar - The trouble is that the documentation seems to be lying about the memory, and there is not one clear description. There also seems to be two varieties. RobotDyn and WeMos - although they may be exactly the same
Greenonline
CC BY-SA 4.0
2018-07-31T18:54:52.120Z
2018-08-01T08:35:37.587Z
2018-08-01T08:35:37.587Z
Greenonline
<p>I'm thinking of buying an <a href="http://s.aliexpress.com/z6jMvy6j" rel="nofollow noreferrer">Arduino WEMOS</a><sup>1</sup> as I am tired with SD card fiddling. </p>

<p><a href="https://i.sstatic.net/vKi4r.jpg" rel="nofollow noreferrer" title="Arduino WEMOS"><img src="https://i.sstatic.net/vKi4r.jpg" alt="Arduino WEMOS" title="Arduino WEMOS"></a></p>

<p>As the ESP8266 chip has 32&nbsp;Mb (~4&nbsp;MB) flash memory, I am hoping to be able to push most of the G-code files over the Wi-Fi. </p>

<p>I was trying OctoPi but, having electronic noise issues, the transmission was not stable. </p>

<p>Has anyone tried WEMOS with RAMPS? Is the serial communication stable between ESP and Arduino? </p>

<hr>

<p><sup>1</sup> Product description is <em>Mega +WiFi R3 ATmega2560+ESP8266 (32Mb memory), USB-TTL CH340G. Compatible for Arduino Mega, NodeMCU, WeMos ESP8266</em></p>

CC BY-SA 4.0
2018-07-08T03:01:11.013Z
You might have confused RAM with Flash memory. The ESP8266-12 as used in that board has about 50 kb of RAM available.
Klaus D.
CC BY-SA 4.0
2018-07-08T07:53:04.507Z
That is correct, will edit question.
profesor79
CC BY-SA 4.0
2018-07-08T20:50:21.580Z
you also confuse units: the ESP has ~3MB of storage to use, not 32. the 32 figure is Mb (megabits) and your program takes up about a meg as well.
dandavis
CC BY-SA 4.0
2018-07-09T08:17:42.957Z
@dandavis thanks for that - that is taken from the specs I found. Anyway if it is 3MB or 32Mb my question is still valid as I was planning to use SD card for storage.
profesor79
CC BY-SA 4.0
2018-07-09T20:03:02.560Z
I don't know about RAMPS in particular, but ESP -> Arduino serial communication is extremely reliable; I have a few devices with such a setup and they have well under 1 ppm error long-term
dandavis
CC BY-SA 4.0
2018-07-31T19:13:36.660Z
Just to clarify, are you asking about (1) the Wireless noise issues between the ESP and the OctoPi; (2) ESP to the ATmega, or (3) The Arduino board and the RAMPS board? Or all three?
Greenonline
CC BY-SA 4.0
2019-01-02T15:25:16.297Z
As a follow up, were you able to use this board [Wemos Mega +WiFi R3 Module ATmega2560+ESP8266 32Mb](https://www.banggood.com/custlink/mDvmhGNmap) instead of the Mega Arduino?
Ricardo AkA Voodoo
CC BY-SA 4.0
2019-01-03T01:27:23.747Z
You can also skip the Arduino ATmega, and get an ESP8266 board or it's bigger brother, an ESP32 board. They're 32 bit microcontrollers while still very low power. It's actually kind of funny having the much more capable ESP8266 chip being used on an arduino board just for Wifi. I didn't put this an answer because I don't have a specific board to recommend that meets your needs.
T. M.
<diy-3d-printer><ramps-1.4>
Arduino WEMOS and RAMPS
profesor79
# Arduino WEMOS and RAMPS

(Asked by: username_0 on 2018-07-07)

I'm thinking of buying an [Arduino WEMOS](http://s.aliexpress.com/z6jMvy6j)1 as I am tired with SD card fiddling.

[![Arduino WEMOS](https://i.sstatic.net/vKi4r.jpg "Arduino WEMOS")](https://i.sstatic.net/vKi4r.jpg "Arduino WEMOS")

As the ESP8266 chip has 32 Mb (~4 MB) flash memory, I am hoping to be able to push most of the G-code files over the Wi-Fi.

I was trying OctoPi but, having electronic noise issues, the transmission was not stable.

Has anyone tried WEMOS with RAMPS? Is the serial communication stable between ESP and Arduino?

---

1 Product description is *Mega +WiFi R3 ATmega2560+ESP8266 (32Mb memory), USB-TTL CH340G. Compatible for Arduino Mega, NodeMCU, WeMos ESP8266*

**Tags:** diy-3d-printer, ramps-1.4

> **Comments:**
> **username_1**: You might have confused RAM with Flash memory. The ESP8266-12 as used in that board has about 50 kb of RAM available.  
> **username_0**: That is correct, will edit question.  
> **username_2**: you also confuse units: the ESP has ~3MB of storage to use, not 32. the 32 figure is Mb (megabits) and your program takes up about a meg as well.  
> **username_0**: @username_2 thanks for that - that is taken from the specs I found. Anyway if it is 3MB or 32Mb my question is still valid as I was planning to use SD card for storage.  
> **username_2**: I don't know about RAMPS in particular, but ESP -> Arduino serial communication is extremely reliable; I have a few devices with such a setup and they have well under 1 ppm error long-term  
> **username_3**: Just to clarify, are you asking about (1) the Wireless noise issues between the ESP and the OctoPi; (2) ESP to the ATmega, or (3) The Arduino board and the RAMPS board? Or all three?  
> **username_4**: As a follow up, were you able to use this board [Wemos Mega +WiFi R3 Module ATmega2560+ESP8266 32Mb](https://www.banggood.com/custlink/mDvmhGNmap) instead of the Mega Arduino?  
> **username_5**: You can also skip the Arduino ATmega, and get an ESP8266 board or it's bigger brother, an ESP32 board. They're 32 bit microcontrollers while still very low power. It's actually kind of funny having the much more capable ESP8266 chip being used on an arduino board just for Wifi. I didn't put this an answer because I don't have a specific board to recommend that meets your needs.  

---

## 1 answers

### Answer by username_3 on 2018-07-31. Score: 4 | Accepted answer

After having looked into them, these boards certainly seem to be rather interesting.

There appear to be two varieties of this board, as I have seen photos with either *RobotDyn*:

[![RobotDyn board](https://i.sstatic.net/l7vGQ.jpg "RobotDyn board")](https://i.sstatic.net/l7vGQ.jpg "RobotDyn board")

rear (from Instructables)

[![RobotDyn board (rear)](https://i.sstatic.net/rwceY.jpg "RobotDyn board (rear)")](https://i.sstatic.net/rwceY.jpg "RobotDyn board (rear)")

or *WeMos* logos on them.

[![WeMos board](https://i.sstatic.net/62P2A.jpg "WeMos board")](https://i.sstatic.net/62P2A.jpg "WeMos board")

They *may*, or *may not*, be the same. There is also this one, with just a generic "WiFi" logo (from the eBay page below):

[![Generic board](https://i.sstatic.net/ybdWZ.jpg "Generic board")](https://i.sstatic.net/ybdWZ.jpg "Generic board")

## Memory Discrepancies

However, there is certainly some discrepancy relating to the specification and amount of memory (unless there are a number of variants - which would certainly be possible):

* 4 MB of Flash is in the ESP8266-12, as [Dan states](https://3dprinting.stackexchange.com/questions/6316/arduino-wemos-and-ramps#comment9539_6316), see [ESP8266 SMT Module - ESP-12](https://shop.pimoroni.com/products/esp8266-smt-module-esp-12). But is it the ESP8266-12 in the board, or is it another ESP variant?
* This **WeMos** product, on eBay, [WeMOS Mega + WiFi R3 ATmega2560 + ESP8266 USB-TTL For Arduino Mega NodeMCU](https://www.ebay.com/itm/WeMOS-Mega-WiFi-R3-ATmega2560-ESP8266-USB-TTL-For-Arduino-Mega-NodeMCU-/263689252053) appears to agree with the 32 Mb1
* This **RobotDyn** board, [Контроллер RobotDyn Mega 2560 R3 + WiFi ESP8266b, flash память 8Mbit, USB-TTL CH340G, MicroUSB](https://robotdyn.ru/catalog/arduino/boards/kontroller_arduino_mega_revizii_r3_s_integrirovannym_chipom_wifi_esp8266_b_8_mb_pamyati.html), has 8 Mb apparently.
* However the **same** product page, but in English, upgrades the memory to 32 MB! See [MEGA+WiFi R3 ATmega2560+ESP8266, flash 32MB, USB-TTL CH340G, Micro-USB](https://robotdyn.com/mega-wifi-r3-atmega2560-esp8266-flash-32mb-usb-ttl-ch340g-micro-usb.html)

Looking at this article, Instructables - [Arduino MEGA 2560 With WiFi Built-in - ESP8266](https://www.instructables.com/id/Arduino-MEGA-2560-With-WiFi-Built-in-ESP8266/), it isn't *exactly* the ESP8266-12:

> In today's text, we discuss an Arduino that I consider extremely special, as it has an ESP8266 embedded in its board. It doesn’t have the ESP12 soldered onto the board. Instead, it has the Espressif chip. So, on the board you have the built-in Tensilica chip with 4MB of memory, along with the ATmega2560, which is the traditional Arduino Mega.

So the ESP has 4 MB, but where does the 32 Mb come in to play?

Well, looking at this RobotDyn memory table (taken from the Instructables page):

[![RobotDyn memory table](https://i.sstatic.net/oAmbU.jpg "RobotDyn memory table")](https://i.sstatic.net/oAmbU.jpg "RobotDyn memory table")

The 4 MB of the ESP appears to have been immediately contradicted and upgraded to 8 MB! The ATmega2560 *somehow* has 32 Mb (which seems a bit of a lie - as there isn't an ATmega2560 *known to man* that has that much memory2), and is confused further by the corresponding text:

> As we see in the table above, the ATmega has 32MB of memory, not counting the ESP memory. This is wonderful, since the traditional Mega Arduino has only 256kb of memory.

So `MB` or `Mb`? Is there an additional flash IC external to the ATmega2560? Looking at the schematic, taken from the Russian RobotDyn page, there doesn't appear to be:

[![RobotDyn schematic](https://i.sstatic.net/dX5UC.png "RobotDyn schematic")](https://i.sstatic.net/dX5UC.png "RobotDyn schematic")

So this could be nonsense. Logic would dictate that the ATmega has 256 kB and the ESP has 4 MB... But I could be wrong..?

Links from [Контроллер RobotDyn Mega 2560 R3 + WiFi ESP8266b, flash память 8Mbit, USB-TTL CH340G, MicroUSB](https://robotdyn.ru/catalog/arduino/boards/kontroller_arduino_mega_revizii_r3_s_integrirovannym_chipom_wifi_esp8266_b_8_mb_pamyati.html):

* Schematic ([PDF](https://robotdyn.ru/upload/PHOTO/0G-00005302==MEGA+WiFi-R3-AT2560-ESP8266-8MB-CH340G/DOCS/Schematic==0G-00005302==MEGA+WiFi-R3-AT2560-ESP8266-8MB-CH340G.pdf))
* Pin out ([PDF](https://robotdyn.ru/upload/PHOTO/0G-00005302==MEGA+WiFi-R3-AT2560-ESP8266-8MB-CH340G/DOCS/PINOUT==0G-00005302==MEGA+WiFi-R3-AT2560-ESP8266-8MB-CH340G.pdf)) ([JPG](https://robotdyn.ru/upload/PHOTO/0G-00005302==MEGA+WiFi-R3-AT2560-ESP8266-8MB-CH340G/DOCS/PINOUT==0G-00005302==MEGA+WiFi-R3-AT2560-ESP8266-8MB-CH340G.jpg))
* Mechanics ([PDF](https://robotdyn.ru/upload/PHOTO/0G-00005302==MEGA+WiFi-R3-AT2560-ESP8266-8MB-CH340G/DOCS/DIM==0G-00005302==MEGA+WiFi-R3-AT2560-ESP8266-8MB-CH340G.pdf)) ([JPG](https://robotdyn.ru/upload/PHOTO/0G-00005302==MEGA+WiFi-R3-AT2560-ESP8266-8MB-CH340G/DOCS/DIM==0G-00005302==MEGA+WiFi-R3-AT2560-ESP8266-8MB-CH340G.jpg))

---

## Reliability of communication

Regardless of the actual spec, to address your question of ESP/Arduino communication reliability:

As the ESP8266 and the ATmega2560 are on the *same* board one would assume that the (serial) communication between the two would be faultless. However, some issues have been reported3.

Nevertheless, from your question, it seems that you were having issues with the ESP to the OctoPi communication, rather than ESP to Arduino, so maybe this doesn't actually answer your question.

Also, as to their compatibility with RAMPS, there is very little information available currently, and it would seem to be a case of try-it-and-see. The closest I got was [this post](https://groups.io/g/onstep/message/154) on the thread, [OnStep and RAMPS1.4](https://groups.io/g/onstep/topic/onstep_and_ramps1_4/7358494?p=Created,,,20,2,0,0::,,,0,0,0,7358494&jump=1), but it seems to be spam.

However, it certainly sounds worth a gamble as it would be a nice combination of technologies. However, I would imagine that some modification of the firmware would be necessary.

---

## Useful Notes

* From [post #8](https://forum.arduino.cc/index.php?topic=464400.msg3485996#msg3485996) of Mega + WiFi R3 ATmega2560 + ESP8266 (8 Mb mémoire)

> To upload the sketch to the board:
>
> ```
> 5, 6, 7 ON
> RXD3 - TXD3   
>
> ```
>
> To run the sketch:
>
> ```
> 5 and 6 ON
> RXD3 - TXD3
>
> ```

* Here is an [excellent manual in Russian](http://www.sysengineering.ru/blog/%D1%8D%D0%BB%D0%B5%D0%BA%D1%82%D1%80%D0%BE%D0%BD%D0%B8%D0%BA%D0%B0-%D0%BA%D0%BE%D0%BD%D1%82%D1%80%D0%BE%D0%BB%D0%BB%D0%B5%D1%80-arduino-mega-%D1%81-esp8266/)

---

## Footnotes

1 From [WeMOS Mega + WiFi R3 ATmega2560 + ESP8266 USB-TTL For Arduino Mega NodeMCU](https://www.ebay.com/itm/WeMOS-Mega-WiFi-R3-ATmega2560-ESP8266-USB-TTL-For-Arduino-Mega-NodeMCU-/263689252053)

> ### WeMOS Mega + WiFi R3 ATmega2560 + ESP8266 USB-TTL For Arduino Mega NodeMCU
>
> Features:
>
> * Full integration on one board: Mega R3 ATmega2560 and WiFi ESP8266 with memory 32Mb (megabyte)
> * All of the modules can work together or each separately. And everyone has their own pinout headers
> * The convenient solution for the development of new projects requiring Uno and WiFi
> * Via USB you can update sketches and firmware for ATmega2560 and for ESP8266. For this on board have the USB-serial converter CH340G
> * Use this board is very simple
> * The board has DIP-switch, to connect the modules. For example to:
>   + USB and ATmeg2560,
>   + USB and ESP8266,
>   + ATmega2560 and ESP8266
>
> Table DIP- Switch:
>
> ```
> Connection                                                          DIP
>                                            1        2        3         4       5         6        7
> ATmega2560<->ESP8266                      ON       ON       OFF       OFF     OFF       OFF      OFF
> USB <->ATmega2560                         OFF      OFF      ON        ON      OFF       OFF      OFF
> USB<->ESP8266 (Update firmware or sketch) OFF      OFF      OFF       OFF     ON        ON       ON
> USB<->ESP8266 (communication)             OFF      OFF      OFF       OFF     ON        ON       OFF
> All independent                           OFF      OFF      OFF       OFF     OFF       OFF      OFF
>
> Special solution:
> USB <->ATmega328<-> ESP8266
> Connection                                                          DIP                                     SWITCH 2
>                                            1        2        3         4       5         6        7
>
> USB <-> ATmega2560<-> ESP8266             ON       ON       ON        ON      OFF       OFF      OFF         To RXD3/TXD3
>
> ```
>
> * USB converter CH340G connect to RX0/TX0 of ATmega2560
> * ESP8266 connect to RX3/TX3 of ATmega2560
>
> Size: 10.5x5.3cm/4.13x2.09inch

2 From the [Atmel ATmega640/V-1280/V
-1281/V-2560/V-2561/V datasheet](http://ww1.microchip.com/downloads/en/DeviceDoc/Atmel-2549-8-bit-AVR-Microcontroller-ATmega640-1280-1281-2560-2561_datasheet.pdf)

> [![ATmega256 memory](https://i.sstatic.net/4zAjV.png)](https://i.sstatic.net/4zAjV.png)

3 From [Mega + WiFi R3 ATmega2560 + ESP8266 (8 Mb mémoire)](https://forum.arduino.cc/index.php?topic=464400.0), there *do* appear to be some issues communicating between the ATmega and the ESP ICs, with a number of users reporting problems.

However, a couple of solutions are provided:

### Solution 1

From [post #2](https://forum.arduino.cc/index.php?topic=464400.msg3220188#msg3220188)

> 1. Set the DIP switch to "special" mode: (`1=on, 2=on, 3=on, 4=on, 5=off, 6=off, 7=off, 8=off`) see the the description of [the
>    product](http://www.ebay.com/itm/Mega-WiFi-R3-ATmega2560-ESP8266-USB-TTL-Arduino-Mega-NodeMCU-WeMos-ESP8266-/222305385421).
> 2. Set the switch in RXD3
> 3. Run the below sketch, change the SSID and PASSWORD values. this is just to test that Arduino and ESP8266 are working together. The code
>    originated from BISSA ORBOEA in Element14.
>
> Code:
>
> ```
> #include "ESP8266.h"
>
> #define SSID        "YOURSID"
> #define PASSWORD    "YOURPASSWORD"
>
> ESP8266 wifi(Serial3,115200);
>
> void setup() {
>
>
>   Serial.begin(9600);              
>
>   Serial.println("Restart");
>   wifi.restart();
>   delay(1000);
>
>   Serial.println("FW Version:");
>   Serial.println(wifi.getVersion().c_str());
>
>     if (wifi.setOprToStation()) {
>         Serial.println("OprToStation ok");    }
>         else {
>         Serial.println("OprToStation  err");
>     }
>
>     if (wifi.joinAP(SSID, PASSWORD)) {
>         Serial.println("Join AP success");
>
>         Serial.print("IP:");
>         Serial.println( wifi.getLocalIP().c_str());      
>     } else {
>         Serial.println("Join AP failure");
>     }
> }
>
>
> void loop()
> {
> }
>
> ```

### Solution 2

From [post #6](https://forum.arduino.cc/index.php?topic=464400.msg3301552#msg3301552)

> First you need to write the code for each board according your
> application, but in your code you need to establish a commmincation
> between serial port of Atmega and ESP in both code, again in according
> you application. Finally, put the switches which make the intenal
> interconnection between both.
>
> For example, I made a code for ESP to connect in an Access Point and
> put on a TCP server. When a wireless client is connected in ESP and
> consequently in the TCP Server, all data send by client I redirect to
> the serial port. As serial port of ESP is connected with serial 3 of
> the Atmega, the code in Atmega pass to theat the data from serial 3.

### Solution 3

From [post #11](https://forum.arduino.cc/index.php?topic=464400.msg3500882#msg3500882)

> Follow this if you have the same to my cases:
>
> 1. programm to the ESP(upload sketch) for wifi connection by configure the DIP to 5:on,6:on,7:on and other off.
> 2. program to mega(upload sketch) in case you want to send communication to each other by configure Dip to 3:on,4:on, and other
>    off.
> 3. switch two RX0/TX0(in my case I use Serial.print() and Serial.readString() for communicate between Esp and Mega)
> 4. after you already upload sketch to both Modules you can test communication between them by configure DIP to: 1:on,2:on,3:on,4:on.
>    and then press Reset Button to restart the boards.
> 5. In ESP you can get the string from Mega by if(Serial.available()) Serial.readString(); and In mega you can get data from ESP by :
>    if(Serial.available())Serial.readString().
> 6. After you got a string so you can split or do anything whatever you want.
> 7. If you want send data to Firebase you must use the Firebase Library at the Esp side, in Mega it not support.

> **Comments:**
> **username_0**: thanks a lot for that compilation. will buy one and see how it works.  
> **username_3**: Yeah, I want to get one. I've just updated my answer with a reasonably accurate sounding description. I will continue to look for a RAMPS use case.  
> **username_6**: Great post, you want to make me buy that board! :D  
> **username_3**: @username_6 - The trouble is that the documentation seems to be lying about the memory, and there is not one clear description. There also seems to be two varieties. RobotDyn and WeMos - although they may be exactly the same  

---

