2.1.5 Switches
1.
AVR_RESET
This push button is used to reset the AVR chip ATmega2560 micro-controller.
2.
ESP_RESET
This push button is used to reset the ESP32 micro-controller.
3.
USER_SW
This push button is a User Switch. It is connected to
PE7 / INT7
pin of ATmega2560.
4.
S1
This switch is used to decide which application code ESP32 should be running.
If S1 is switched to the left side (indicated with a
Wi-Fi symbol
), ESP32 will run
the Over-The-Air (OTA) application. This application turns ON the ESP32 Wi-Fi
Access Point, listens and waits for any client to get connected with itself. It is
also used for flashing the firmware for ATmega2560 and ESP32 wirelessly. If S1
is switched to right side, ESP32 will run the User application (which is flashed on
ESP32 either via wired connection or wirelessly).
5.
S2
This switch is used to make or break the connection between ATmega2560 and
ESP32. If S2 is switched to left side (indicated with a
Wi-Fi symbol
), the
UART0
TX, RX lines of ATmega2560 gets connected to the
UART1
RX, TX lines of ESP32
respectively. Through this connection, one can send and receive any data between
ATmega2560 and ESP32. If S2 is switched to right side, the connection between
ATmega2560 and ESP32 breaks.
Note:
Make sure that while flashing the firmware for ATmega2560 wirelessly, the
S2 switch is on the left side.
6.
S3
This switch is used to decide whether to flash firmware on ATmega2560 or ESP32
through wired connection. If S3 is switched to left side (indicated with
W_AVR
),
one can flash firmware to ATmega2560 and if it is switched to right side (indicated
with
W_ESP/Wi-Fi symbol
), one can flash firmware to ESP32 through wired con-
nection. One can also use this switch for debugging purposes by printing data on
the Wired Serial Monitor. For more information on Wired Serial Monitor, refer to
the Section
Button - Wired Serial Monitor
in the
Software Manual of eYFi-Mega
development board
.
Note:
Make sure that while flashing the firmware for ATmega2560 wirelessly, the
S3 switch is on the right side.
Table
highlights the function of Switches
S1
,
S2
and
S3
in short.
Table
summarizes the use of the Switches
S1
,
S2
and
S3
and their positions for flashing
the firmware on ATmega2560 and ESP32 via wired connection or wirelessly (OTA).
12