Arduino MEGA 2560 With WiFi Built in ESP8266 PDF
Arduino MEGA 2560 With WiFi Built in ESP8266 PDF
by Fernando Koyanagi
In today's text, we discuss an Arduino that I consider Let’s move onto how this Arduino works, and let's do
extremely special, as it has an ESP8266 embedded an assembly that shows when you should select ESP
in its board. It doesn’t have the ESP12 soldered onto or Mega to perform a home automation. With this, we
the board. Instead, it has the Espressif chip. So, on can turn lamps on and off, which is a mechanism that
the board you have the built-in Tensilica chip with can be very useful for you to make improvements in
4MB of memory, along with the ATmega2560, which your house.
is the traditional Arduino Mega.
https://youtu.be/Yj5apiv4wcE
I really like that this Arduino has a Pigtail connector This board also has a selector switch that allows the
for an antenna. Why is this good? If you connect an ESP to interleave the connection between TX0 and
antenna on this device, you will have a huge benefit, TX3, remembering that the ATmega has four serials.
as it will increase your reach, straight from 90 meters A second selector switch is the DIP Switch, and we
to 240 meters away. I came to this conclusion after a also have a key recording mode of the ESP8266. All
test I did, so I did not have to rely solely on the the pinning is completely compatible with the
datasheet manual. ATmega pinout.
Here, I show the back of the board, where there is a table that displays access to the ESP pins.
Here, we have a comparison between the Mega We can see, then, that the intention of the RobotDyn
Arduino with the integrated ESP (Arduino Mega creaters was to maintain the architecture of the
RobotDyn) and the traditional Mega Arduino (Arduino ATmega.
Mega 2560). We can see that they are similar, but in
the 2560, we have the USB printer, which is a large As we see in the table above, the ATmega has 32MB
connector. However, in the RobotDyn, we have the of memory, not counting the ESP memory. This is
mini-USB. I particularly like the more compact option, wonderful, since the traditional Mega Arduino has
but the power is the same in both. only 256kb of memory. The power in the RobotDyn is
7 to 12 volts, and the ESP8266 is already powered, The processors are the same, 16MHz, and one great
and already has a voltage reducer. So, feeding the advantage of these models is the high amount of IOs.
Arduino is already feeding the ESP, which is already
down to 3v3, and internally that microcontroller is
already 3v3.
We have here the DIP Switch and a table with In the image below, we zoomed in on the key that
several positions. These help in the connections, changes the serial port of the Arduino Mega. This
depending on your objective. One essential detail is connects to the ESP, and also in the key Mode,
that if you are writing Flash in ESP, you have to be requiring that we must press the ESP8266 to record.
aware of addresses that are even slightly different.
If you want to use ESP8266 in AT mode, you should Crystal Freq = 26M
configure the Flash Download Tool as follows:
File\bin\esp_init_data_default.binataddress0x3fc000 File\bin\at\512+512\user1.1024.new.2.binataddress0x
1000
File\bin\blank.binataddress0x37e000
File\bin\boot_v1.4(b1).binataddress0x00000
In this part, I used esptool.exe, which is a command tool that accesses the ESP8266 Flash and checks for some
settings, such as the chip type and memory size.
In this example we show the hexadecimal addresses we use to write with the Flash Download Tool.
Also, for those who do not have much experience with the ESP8266, I suggest two of my previous videos:
Recording in ESP01 and Introduction to ESP8266.
To record the Arduino, there is no mystery at all. You only need to set up the Mega Arduino 2560 board as if it
were a traditional Arduino.
We have here the assembly scheme that I perform in the video. We connected the Arduino Mega to the ESP01
and controlled two relays for one application.
Here, we do the same thing mentioned above, but while using the Arduino Mega with integrated ESP. One tip is
that you watch the video entitled Residential Automation with Arduino Mega and ESP8266 for more details about
this subject.