ESP8266 Weather Widget V2.0

91,184

867

139

Introduction: ESP8266 Weather Widget V2.0

About: I am a DIY hobbyist by passion and Power Engineer by profession. Most of my works are related to Solar Energy and Arduino. Apart from Electronics I love 3D printing, Woodworking and to make crafts from used …

Welcome to my new Weather Widget Project. Earlier I posted an Instructables on the weather widget, that uses a 0.96" OLED display to display the weather parameters. The main problem in the earlier version is that the display is very small in size, so you have to come very close to it for reading the parameters. That's why it was always in my mind to upgrade it to a larger color display with a nice 3D printed enclosure.

Recently I was browsing the Banggood website for purchasing a few components for my upcoming project, then I came across a desktop Weather Station. I showed the product to my wife and she was fascinated with it and wished to see it on her craft table. First I thought to gift her by purchasing it, but then I changed my mind and challenged myself to make a cool weather widget by using my skill and taking help from the open-source community.

In this Instructables, I will show you how to make a Weather Widget by using ESP8266 and a 2.8" touch screen display. The device retrieves localized weather information from https://openweathermap.org/ by WLAN and displays it on the Display module.

Support me On Patreon:

If you enjoy my work here on Instructables, consider joining my Patreon, it will be a great help for me to make more interesting projects in the future.

Patreon Link:https://www.patreon.com/opengreenenergy

The Widget displays the following things:

1. Current Time with Date

2. Current Day Weather Information like Temperature, Pressure, Humidity, and Rainfall.

3. Future forecasting for 7 days

Credit :

I would like to give credit to my friend Dani Eichhorn who did all of the programming parts. He is updating the software on his Github page regularly with new features. You can visit SquixTechBlog to see more projects on ESP8266.

Thank You, PCBWay:

This project is successfully completed because of the help and support from PCBWay. Guys if you have a PCB project, please visit their website and get exciting discounts and coupons.

PCBWay 4th PCB Design Contest: If you have a cool PCB project, you may participate in the 4th PCB Design Contest.

Step 1: Parts and Tools Required

Parts Used :

1. Wemos D1 Mini Pro ( Amazon / AliExpress / Banggood )

2. 2.8" TFT Display ( Amazon / AliExpress / Banggood )

3. 30 AWG Wires ( Amazon / AliExpress / Banggood )

4. USB Cable ( Amazon / AliExpress / Banggood )

5. PLA Filament ( Amazon / AliExpress / Banggood )

Tools Used :

1. 3D Printer ( Amazon / AliExpress / Banggood )

2. Soldering Iron ( Amazon / AliExpress / Banggood )

3. Wire Cutter ( Amazon / AliExpress / Banggood )

4. Wire Stripper ( Amazon / AliExpress / Banggood )

Step 2: Prepare the Wires

My plan is to place the weather display circuit inside a 3D-printed enclosure. But the enclosure that I am going to use is very compact, and there is little room to keep the Wemos board along with the connecting wires inside the housing.

So, we have to select thin wires to make the connection between the display unit and Wemos Board. Here, I have selected 30 AWG single-stranded wires.

Cut 14 numbers of wires with equal length by using a Nipper.

Then strip out the insulation from the wires by using a Wire Stripper.

Step 3: Solder Wires to the Display Unit

The TFT display has pre-soldered straight header pins to mount it to the breadboard or any other shield. You have two options

1. Desolder the header pins from the PCB and then solder the wires to the soldering pads

2. Directly solder to the header pins

I prefer the second one, it is much easier and requires less effort and skill.

Before soldering apply a small amount of soldering flux to all the header pins. Then tin the header pins by using a small amount of solder on the soldering iron tip. Tinning is required as it makes the soldering process easier and strong bonding between the wire and header pins.

Finally, solder the wires to all the header pins as shown in the above picture.

Step 4: 3D Printing

I have modified the enclosure in Autodesk Fusion 360 by taking reference from a nice model available in Thingiverse and designed by smily77. The dimensions of all the components are measured by a vernier caliper then the same were considered during the design.

The enclosure has 3 parts:

1. Housing Body

2. Back Cover

3. Base Cover

Download the STL files from Thingiverse ( If the link is broken, you may download the STL files here)

I have used my Creality CR-10 Mini 3D printer and 1.75 mm white PLA filament to print the parts.

My settings are:

Print Speed: 60 mm/s

Layer height: 0.2mm

Fill Density: 20%

Extruder Temperature: 210 deg C

Bed Temp: 60 deg C

Step 5: Install the Display

In this step, you have two options

1. First Install the Display into the enclosure then solder the wires to the Wemos Board

2. Make the wiring between display and Wemos board first, then install them into the enclosure later.

I have shown both ways in the above pictures. The pictures themselves are self-explanatory. My personal preference is the second option.

Step 6: Wiring Diagram

The wiring diagram is very straightforward. You have to connect the TFT display module ( ILI9341 ) pins with Wemos pins as per the schematic diagram. The schematic diagram is shown above. You may also follow the following pin mapping

TFT Display->Wemos ( ESP8266 )

VIN -> 3.3V

GND -> GND

CS -> D1

RESET -> RST

DC -> D2

SDI -> D7

SCK - D5

LED -> D8

SDO -> D6

T_CLK -> D5

T_CS -> D3

T_DIN -> D7

T_DO -> D6

T_IRQ -> D4

Step 7: Make the Circuit

First, download the schematic diagram, then take a printout. It Is really handy during the soldering and you will save a lot of time also. The most important thing is any mistakes in the connection may damage the display module or Wemos board. During the making of this project, I have fried my display unit touch screen IC due to some mistake in connection.

Step 8: Prepare the Arduino IDE for ESP8266 Board

The ESP8266 module isn't part of the Arduino-IDE, so we have to install it first. You can easily install it by going through the following steps:

1. Start Arduino IDE and open the Preferences window.

2. Enter https://arduino.esp8266.com/stable/package_esp826... into the File>Preferences>Additional Boards Manager URLs field of the Arduino IDE. You can add multiple URLs, separating them with commas.

3.Close this window with the OK Button. Open Boards Manager from Tools > Board menu and select the correct ESP8266 board.

4. Now you can choose LOLIN(WEMOS) D1 R2 & mini. Set the CPU frequency to 80MHz, Flash Size to "4MB (FS:3MB OTA:~512KB)", and the COM port.

Step 9: Download the Code and Libraries

You can download the Arduino code and supporting libraries from the following links.

Arduino Code:

https://github.com/ThingPulse/esp8266-weather-stat...

Libraries:

1. Mini Grafx by Daniel Eichhorn

2. ESP8266 WeatherStation by Daniel Eichhorn

3. Json Streaming Parser by Daniel Eichhorn

4. ThingPulse XPT2046 Touch by ThingPulse (forked from Paul Stoffregen), if you had previously installed the original XPT2046_Touchscreen then you need to uninstall that one!

After downloading the library unzip it and installed it with your Arduino Library Manager in
Sketch > Include Library > Manage Libraries...

Step 10: Get OpenWeatherMap API Key

The Weather Station real-time data is obtained from the OpenWeatherMap website. So you have to get the OpenWeatherMap API Key.

Now you can choose the free plan in the first column. There is no cost to apply for a free plan, which is more than sufficient for our requirements. Only the limitation of using the free plan is that you are limited to 60 calls per minute.

Now click on Get " API Key " then create a new account by filling up your credentials.

Note down the API key which will be required in our code in the next step.

Step 11: Upload the Software

After setting up Arduino IDE and installing all the libraries we can move to upload the code into the ESP8266 board ( Wemos D1 Mini Pro or any other board )

First, you have to unzip the code downloaded in the earlier step and then save it somewhere on your PC or Laptop. Remove the word master from the folder name, the final name shall be " esp8266-weather-station-color "

Now open the folder and click on "esp8266-weather-station-color.ino "

In one of the tabs, the IDE opened settings.h. Go through the file and adjust the two handfuls of configuration parameters. They are all documented inside the file directly. Everything should be self-explanatory. Most importantly you will need to set the OpenWeatherMap API key you obtained in a previous step.

Now you are ready to upload the code, just hit the upload arrow button.

Step 12: Install the Covers

After mounting the display unit and circuit board, we can move to box up the housing by using the two covers. The enclosure is designed with very tight clearance, so you don't need any glue or screw to hold the covers.

Align the cover with the slot in the enclosure and press it all around, you are done. The smaller cover is for the base part and the larger one is for the back side of the display part.

Step 13: Testing

If you are successfully uploaded the code into the ESP8266, you will immediately notice the display on the front page by searching the WiFi Network for connection. After connecting the device to your WiFi router, it will update the time and weather data from the web.

Now you will be able to see all the weather information along with all other parameters on the TFT display. You can swap between the different pages by using the stylus or touching with your finger.

Note: In the beginning, you will be asked to touch the screen for calibrating the touch screen display.

I am super happy with the final outcome of this little gadget. You may gift this little gadget to someone on any occasion.

DIY Summer Camp Contest

Participated in the
DIY Summer Camp Contest

24 People Made This Project!

Recommendations

  • Fabric Challenge

    Fabric Challenge
  • On a Budget Challenge

    On a Budget Challenge
  • Fandom Contest

    Fandom Contest

139 Comments

0
Unmesh55
Unmesh55

18 days ago

I have successfully uploaded the project to nodemcu but my screen is stuck on "calibration initiated now release screen", the touchscreen is working as the led is blinking on touch please help.

0
maruchiel24
maruchiel24

27 days ago

hello..have a good day.!
we madw it for our thesis but our instructor suggested that we have to change the screen into bigger one so that the weather forecast looks wider..but I don't know if it will works to bigger screen..Can I have some advice..thank you in advance..

received_5193169340769315.jpeg
0
larrymenzie
larrymenzie

7 weeks ago on Step 11

Arduino: 1.8.15 (Linux), Board: "NodeMCU 1.0 (ESP-12E Module), 80 MHz, Flash, Disabled (new aborts on oom), Disabled, All SSL ciphers (most compatible), 32KB cache + 32KB IRAM (balanced), Use pgm_read macros for IRAM/PROGMEM, 4MB (FS:2MB OTA:~1019KB), 2, v2 Lower Memory, Disabled, None, Only Sketch, 115200"
In file included from /home/bear/snap/arduino/current/Arduino/libraries/esp8266-weather-station-color-master/TouchControllerWS.h:2,
from /home/bear/Desktop/esp8266/ws/esp8266-weather-station-color-master/esp8266-weather-station-color/esp8266-weather-station-color.ino:33:
/home/bear/snap/arduino/current/Arduino/libraries/ThingPulse_XPT2046_Touch-1.4.0/XPT2046_Touchscreen.h:33:7: error: redefinition of 'class TS_Point'
33 | class TS_Point {
| ^~~~~~~~
In file included from /home/bear/Desktop/esp8266/ws/esp8266-weather-station-color-master/esp8266-weather-station-color/esp8266-weather-station-color.ino:31:
/home/bear/snap/arduino/current/Arduino/libraries/Adafruit_STMPE610/Adafruit_STMPE610.h:135:7: note: previous definition of 'class TS_Point'
135 | class TS_Point {
| ^~~~~~~~
esp8266-weather-station-color:88:40: error: no matching function for call to 'TouchControllerWS::TouchControllerWS(Adafruit_STMPE610*)'
88 | TouchControllerWS touchController(&ts);
| ^
In file included from /home/bear/Desktop/esp8266/ws/esp8266-weather-station-color-master/esp8266-weather-station-color/esp8266-weather-station-color.ino:33:
/home/bear/snap/arduino/current/Arduino/libraries/esp8266-weather-station-color-master/TouchControllerWS.h:11:5: note: candidate: 'TouchControllerWS::TouchControllerWS(XPT2046_Touchscreen*)'
11 | TouchControllerWS(XPT2046_Touchscreen *touchScreen);
| ^~~~~~~~~~~~~~~~~
/home/bear/snap/arduino/current/Arduino/libraries/esp8266-weather-station-color-master/TouchControllerWS.h:11:44: note: no known conversion for argument 1 from 'Adafruit_STMPE610*' to 'XPT2046_Touchscreen*'
11 | TouchControllerWS(XPT2046_Touchscreen *touchScreen);
| ~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~
/home/bear/snap/arduino/current/Arduino/libraries/esp8266-weather-station-color-master/TouchControllerWS.h:9:7: note: candidate: 'constexpr TouchControllerWS::TouchControllerWS(const TouchControllerWS&)'
9 | class TouchControllerWS {
| ^~~~~~~~~~~~~~~~~
/home/bear/snap/arduino/current/Arduino/libraries/esp8266-weather-station-color-master/TouchControllerWS.h:9:7: note: no known conversion for argument 1 from 'Adafruit_STMPE610*' to 'const TouchControllerWS&'
/home/bear/snap/arduino/current/Arduino/libraries/esp8266-weather-station-color-master/TouchControllerWS.h:9:7: note: candidate: 'constexpr TouchControllerWS::TouchControllerWS(TouchControllerWS&&)'
/home/bear/snap/arduino/current/Arduino/libraries/esp8266-weather-station-color-master/TouchControllerWS.h:9:7: note: no known conversion for argument 1 from 'Adafruit_STMPE610*' to 'TouchControllerWS&&'
exit status 1
no matching function for call to 'TouchControllerWS::TouchControllerWS(Adafruit_STMPE610*)'
This report would have more information with
"Show verbose output during compilation"
option enabled in File -> Preferences.

0
larrymenzie
larrymenzie

Reply 7 weeks ago

i dont see any answers

0
ChrisD547
ChrisD547

6 months ago

This is a great tutorial - thanks! The link to your Thingiverse page seems broken though - any chance of making the STL file available again please? Thanks

0
ChrisD547
ChrisD547

Reply 5 months ago

Many thanks for these :-)

0
ChrisD547
ChrisD547

Reply 6 months ago

Thank you so much - really appreciate it!

0
PWDawgy
PWDawgy

6 months ago

Tried to add this to the "I made it" section but due to some unknown errors can't add photos so that's that.

Nice little project could do with some improvements:
changed the time format change to be any touch point within the time box on the first screen
Added a degC to degF format change to the top lefthand area next to the time on the first screen
Debounced the touch screen input as it was way too sensitive.
Changed the timeserver to a local one on my network.

Apparently I can't add images here because of the same unknown error

0
PWDawgy
PWDawgy

Reply 6 months ago

Apparently it was me, needed to clear browser cashe, thought I'd done but apparently not.

0
DAPPER767
DAPPER767

7 months ago

Hello. I just made this project but all the times in the display keep constantly flashing the time between 12 and 24 hr format. Can anybody help me please? Thank you.

0
PWDawgy
PWDawgy

Reply 6 months ago

Its probably a calibration issue, I had this for some reason it had calibration info already, so change this line:
if (!isCalibrationAvailable) {
to
if (isCalibrationAvailable) {

Run the project and the calibration screen will show up, do the calibration change the line back and everything should work.

0
DAPPER767
DAPPER767

Reply 6 months ago

Thank you very much. I've tried what you suggested and it now works perfectly!

0
spack2007
spack2007

11 months ago

Hello to the whole group, so I have finished the project that works very well, the only strange thing is that on the home page the notifications that scroll miss the screens of Thursday and Friday jumps from Wednesday to Saturday and Wednesday only the information is displayed at 2:00 the one at 14:00 is missing, for the rest everything works what happens even in the forecast pages are only two and then goes to the system info, can someone tell me how I can solve the problem?
Thanks

0
TedB62
TedB62

Reply 6 months ago

I have the same problem.
I have tried looking through the code but can not figure it out.
Has anyone found the problem?


0
charcuteriamayratienda

Hello, everything is connected and in principle the code has loaded but the screen does not turn on. The light on the D1 mini pro board is flickering and when I touch the screen, the light on the D1 mini pro flashes as if the touch works but the screen doesn't turn on, I don't see anything.
What can I do wrong?

0
PeterD229
PeterD229

Reply 7 months ago

Check the wiring, I had an issue when I first wired it the LCD screen would be on but all that would be visiable is the LED backlight

0
ednegari
ednegari

7 months ago

Very cool! Does anyone have a way to control brightness? Like:

1. Integrate a Light sensor (photoresistor) to detect the ambient light
2. Change the code to hard-code it to, say, 60% brightness
3. Add a button to cycle through high, medium, & low brightness settings
4. Time-based: From 7am-10pm, 100% brightness; From 10pm-7am, 40% brightness.

Thanks!

0
kcraig35
kcraig35

7 months ago

If you are running into the issue with the screens not changing, the original code is looking for a tap at less than 80pixels on the y-axis. That being said I never could get it to change properly with the original code. I made a slight change to the code and am able to change screens properly now.

In esp8266-weather-station-color.ino @ line 247 you should see
if (!asleep) { // no need to change screens;if (p.y < 80) {
IS_STYLE_12HR = !IS_STYLE_12HR;
} else {
screen = (screen + 1) % screenCount;
}
}

remove the everything but screen = (screen + 1) % screenCount;

which should leave you with

if (!asleep) {
screen = (screen + 1) % screenCount;
}

I looked and couldn't find the answer if there is a way to put the code in a code block please let me know.

0
w37986
w37986

8 months ago

Arduino:1.8.12 (Windows 7), 開發板:"LOLIN(WEMOS) D1 R2 & mini, 80 MHz, Flash, Disabled (new aborts on oom), Disabled, All SSL ciphers (most compatible), 32KB cache + 32KB IRAM (balanced), Byte/Word access to IRAM/PROGMEM (very slow), 4MB (FS:2MB OTA:~1019KB), v2 Lower Memory, Disabled, None, Only Sketch, 512000"
c:/users/dlit/appdata/local/arduino15/packages/esp8266/tools/xtensa-lx106-elf-gcc/3.0.4-gcc10.3-1757bed/bin/../lib/gcc/xtensa-lx106-elf/10.3.0/../../../../xtensa-lx106-elf/bin/ld.exe: libraries\ThingPulse_XPT2046_Touch\XPT2046_Touchscreen.cpp.o: in function `_Z6isrPinv':
C:\Users\dlit\Desktop\arduino-1.8.15-windows\2021_11_22\libraries\ThingPulse_XPT2046_Touch/XPT2046_Touchscreen.cpp:49: multiple definition of `_Z6isrPinv'; sketch\XPT2046_Touchscreen.cpp.o:sketch/XPT2046_Touchscreen.cpp:69: first defined here
c:/users/dlit/appdata/local/arduino15/packages/esp8266/tools/xtensa-lx106-elf-gcc/3.0.4-gcc10.3-1757bed/bin/../lib/gcc/xtensa-lx106-elf/10.3.0/../../../../xtensa-lx106-elf/bin/ld.exe: libraries\ThingPulse_XPT2046_Touch\XPT2046_Touchscreen.cpp.o: in function `_ZN19XPT2046_Touchscreen11tirqTouchedEv':
C:\Users\dlit\Desktop\arduino-1.8.15-windows\2021_11_22\libraries\ThingPulse_XPT2046_Touch/XPT2046_Touchscreen.cpp:61: multiple definition of `_ZN19XPT2046_Touchscreen11tirqTouchedEv'; sketch\XPT2046_Touchscreen.cpp.o:sketch/XPT2046_Touchscreen.cpp:81: first defined here
c:/users/dlit/appdata/local/arduino15/packages/esp8266/tools/xtensa-lx106-elf-gcc/3.0.4-gcc10.3-1757bed/bin/../lib/gcc/xtensa-lx106-elf/10.3.0/../../../../xtensa-lx106-elf/bin/ld.exe: libraries\ThingPulse_XPT2046_Touch\XPT2046_Touchscreen.cpp.o: in function `_ZN19XPT2046_Touchscreen11bufferEmptyEv':
C:\Users\dlit\Desktop\arduino-1.8.15-windows\2021_11_22\libraries\ThingPulse_XPT2046_Touch/XPT2046_Touchscreen.cpp:79: multiple definition of `_ZN19XPT2046_Touchscreen11bufferEmptyEv'; sketch\XPT2046_Touchscreen.cpp.o:sketch/XPT2046_Touchscreen.cpp:99: first defined here
c:/users/dlit/appdata/local/arduino15/packages/esp8266/tools/xtensa-lx106-elf-gcc/3.0.4-gcc10.3-1757bed/bin/../lib/gcc/xtensa-lx106-elf/10.3.0/../../../../xtensa-lx106-elf/bin/ld.exe: libraries\ThingPulse_XPT2046_Touch\XPT2046_Touchscreen.cpp.o: in function `_ZN19XPT2046_Touchscreen6updateEv':
C:\Users\dlit\Desktop\arduino-1.8.15-windows\2021_11_22\libraries\ThingPulse_XPT2046_Touch/XPT2046_Touchscreen.cpp:101: multiple definition of `_ZN19XPT2046_Touchscreen6updateEv'; sketch\XPT2046_Touchscreen.cpp.o:sketch/XPT2046_Touchscreen.cpp:121: first defined here
c:/users/dlit/appdata/local/arduino15/packages/esp8266/tools/xtensa-lx106-elf-gcc/3.0.4-gcc10.3-1757bed/bin/../lib/gcc/xtensa-lx106-elf/10.3.0/../../../../xtensa-lx106-elf/bin/ld.exe: libraries\ThingPulse_XPT2046_Touch\XPT2046_Touchscreen.cpp.o: in function `_ZN19XPT2046_Touchscreen8readDataEPtS0_Ph':
C:\Users\dlit\Desktop\arduino-1.8.15-windows\2021_11_22\libraries\ThingPulse_XPT2046_Touch/XPT2046_Touchscreen.cpp:71: multiple definition of `_ZN19XPT2046_Touchscreen8readDataEPtS0_Ph'; sketch\XPT2046_Touchscreen.cpp.o:sketch/XPT2046_Touchscreen.cpp:91: first defined here
c:/users/dlit/appdata/local/arduino15/packages/esp8266/tools/xtensa-lx106-elf-gcc/3.0.4-gcc10.3-1757bed/bin/../lib/gcc/xtensa-lx106-elf/10.3.0/../../../../xtensa-lx106-elf/bin/ld.exe: libraries\ThingPulse_XPT2046_Touch\XPT2046_Touchscreen.cpp.o: in function `_ZN19XPT2046_Touchscreen7touchedEv':
C:\Users\dlit\Desktop\arduino-1.8.15-windows\2021_11_22\libraries\ThingPulse_XPT2046_Touch/XPT2046_Touchscreen.cpp:65: multiple definition of `_ZN19XPT2046_Touchscreen7touchedEv'; sketch\XPT2046_Touchscreen.cpp.o:sketch/XPT2046_Touchscreen.cpp:85: first defined here
c:/users/dlit/appdata/local/arduino15/packages/esp8266/tools/xtensa-lx106-elf-gcc/3.0.4-gcc10.3-1757bed/bin/../lib/gcc/xtensa-lx106-elf/10.3.0/../../../../xtensa-lx106-elf/bin/ld.exe: libraries\ThingPulse_XPT2046_Touch\XPT2046_Touchscreen.cpp.o: in function `_ZN19XPT2046_Touchscreen8getPointEv':
C:\Users\dlit\Desktop\arduino-1.8.15-windows\2021_11_22\libraries\ThingPulse_XPT2046_Touch/XPT2046_Touchscreen.cpp:54: multiple definition of `_ZN19XPT2046_Touchscreen8getPointEv'; sketch\XPT2046_Touchscreen.cpp.o:sketch/XPT2046_Touchscreen.cpp:74: first defined here
c:/users/dlit/appdata/local/arduino15/packages/esp8266/tools/xtensa-lx106-elf-gcc/3.0.4-gcc10.3-1757bed/bin/../lib/gcc/xtensa-lx106-elf/10.3.0/../../../../xtensa-lx106-elf/bin/ld.exe: libraries\Time\Time.cpp.o: in function `_Z9breakTimexR12tmElements_t':
C:\Users\dlit\Desktop\arduino-1.8.15-windows\2021_11_22\libraries\Time/Time.cpp:151: multiple definition of `_Z9breakTimexR12tmElements_t'; sketch\Time.cpp.o:sketch/Time.cpp:151: first defined here
c:/users/dlit/appdata/local/arduino15/packages/esp8266/tools/xtensa-lx106-elf-gcc/3.0.4-gcc10.3-1757bed/bin/../lib/gcc/xtensa-lx106-elf/10.3.0/../../../../xtensa-lx106-elf/bin/ld.exe: libraries\Time\Time.cpp.o: in function `_Z12refreshCachex':
C:\Users\dlit\Desktop\arduino-1.8.15-windows\2021_11_22\libraries\Time/Time.cpp:42: multiple definition of `_Z12refreshCachex'; sketch\Time.cpp.o:sketch/Time.cpp:42: first defined here
c:/users/dlit/appdata/local/arduino15/packages/esp8266/tools/xtensa-lx106-elf-gcc/3.0.4-gcc10.3-1757bed/bin/../lib/gcc/xtensa-lx106-elf/10.3.0/../../../../xtensa-lx106-elf/bin/ld.exe: libraries\Time\Time.cpp.o: in function `_Z4yearx':
C:\Users\dlit\Desktop\arduino-1.8.15-windows\2021_11_22\libraries\Time/Time.cpp:137: multiple definition of `_Z4yearx'; sketch\Time.cpp.o:sketch/Time.cpp:137: first defined here
c:/users/dlit/appdata/local/arduino15/packages/esp8266/tools/xtensa-lx106-elf-gcc/3.0.4-gcc10.3-1757bed/bin/../lib/gcc/xtensa-lx106-elf/10.3.0/../../../../xtensa-lx106-elf/bin/ld.exe: libraries\Time\Time.cpp.o: in function `_Z5monthx':
C:\Users\dlit\Desktop\arduino-1.8.15-windows\2021_11_22\libraries\Time/Time.cpp:128: multiple definition of `_Z5monthx'; sketch\Time.cpp.o:sketch/Time.cpp:128: first defined here
c:/users/dlit/appdata/local/arduino15/packages/esp8266/tools/xtensa-lx106-elf-gcc/3.0.4-gcc10.3-1757bed/bin/../lib/gcc/xtensa-lx106-elf/10.3.0/../../../../xtensa-lx106-elf/bin/ld.exe: libraries\Time\Time.cpp.o: in function `_Z7weekdayx':
C:\Users\dlit\Desktop\arduino-1.8.15-windows\2021_11_22\libraries\Time/Time.cpp:119: multiple definition of `_Z7weekdayx'; sketch\Time.cpp.o:sketch/Time.cpp:119: first defined here
c:/users/dlit/appdata/local/arduino15/packages/esp8266/tools/xtensa-lx106-elf-gcc/3.0.4-gcc10.3-1757bed/bin/../lib/gcc/xtensa-lx106-elf/10.3.0/../../../../xtensa-lx106-elf/bin/ld.exe: libraries\Time\Time.cpp.o: in function `_Z3dayx':
C:\Users\dlit\Desktop\arduino-1.8.15-windows\2021_11_22\libraries\Time/Time.cpp:110: multiple definition of `_Z3dayx'; sketch\Time.cpp.o:sketch/Time.cpp:110: first defined here
c:/users/dlit/appdata/local/arduino15/packages/esp8266/tools/xtensa-lx106-elf-gcc/3.0.4-gcc10.3-1757bed/bin/../lib/gcc/xtensa-lx106-elf/10.3.0/../../../../xtensa-lx106-elf/bin/ld.exe: libraries\Time\Time.cpp.o: in function `_Z6secondx':
C:\Users\dlit\Desktop\arduino-1.8.15-windows\2021_11_22\libraries\Time/Time.cpp:101: multiple definition of `_Z6secondx'; sketch\Time.cpp.o:sketch/Time.cpp:101: first defined here
c:/users/dlit/appdata/local/arduino15/packages/esp8266/tools/xtensa-lx106-elf-gcc/3.0.4-gcc10.3-1757bed/bin/../lib/gcc/xtensa-lx106-elf/10.3.0/../../../../xtensa-lx106-elf/bin/ld.exe: libraries\Time\Time.cpp.o: in function `_Z6minutex':
C:\Users\dlit\Desktop\arduino-1.8.15-windows\2021_11_22\libraries\Time/Time.cpp:92: multiple definition of `_Z6minutex'; sketch\Time.cpp.o:sketch/Time.cpp:92: first defined here
c:/users/dlit/appdata/local/arduino15/packages/esp8266/tools/xtensa-lx106-elf-gcc/3.0.4-gcc10.3-1757bed/bin/../lib/gcc/xtensa-lx106-elf/10.3.0/../../../../xtensa-lx106-elf/bin/ld.exe: libraries\Time\Time.cpp.o: in function `_Z4isPMx':
C:\Users\dlit\Desktop\arduino-1.8.15-windows\2021_11_22\libraries\Time/Time.cpp:84: multiple definition of `_Z4isPMx'; sketch\Time.cpp.o:sketch/Time.cpp:84: first defined here
c:/users/dlit/appdata/local/arduino15/packages/esp8266/tools/xtensa-lx106-elf-gcc/3.0.4-gcc10.3-1757bed/bin/../lib/gcc/xtensa-lx106-elf/10.3.0/../../../../xtensa-lx106-elf/bin/ld.exe: libraries\Time\Time.cpp.o: in function `_Z4isAMx':
C:\Users\dlit\Desktop\arduino-1.8.15-windows\2021_11_22\libraries\Time/Time.cpp:76: multiple definition of `_Z4isAMx'; sketch\Time.cpp.o:sketch/Time.cpp:76: first defined here
c:/users/dlit/appdata/local/arduino15/packages/esp8266/tools/xtensa-lx106-elf-gcc/3.0.4-gcc10.3-1757bed/bin/../lib/gcc/xtensa-lx106-elf/10.3.0/../../../../xtensa-lx106-elf/bin/ld.exe: libraries\Time\Time.cpp.o: in function `_Z12hourFormat12x':
C:\Users\dlit\Desktop\arduino-1.8.15-windows\2021_11_22\libraries\Time/Time.cpp:62: multiple definition of `_Z12hourFormat12x'; sketch\Time.cpp.o:sketch/Time.cpp:62: first defined here
c:/users/dlit/appdata/local/arduino15/packages/esp8266/tools/xtensa-lx106-elf-gcc/3.0.4-gcc10.3-1757bed/bin/../lib/gcc/xtensa-lx106-elf/10.3.0/../../../../xtensa-lx106-elf/bin/ld.exe: libraries\Time\Time.cpp.o: in function `_Z4hourx':
C:\Users\dlit\Desktop\arduino-1.8.15-windows\2021_11_22\libraries\Time/Time.cpp:53: multiple definition of `_Z4hourx'; sketch\Time.cpp.o:sketch/Time.cpp:53: first defined here
c:/users/dlit/appdata/local/arduino15/packages/esp8266/tools/xtensa-lx106-elf-gcc/3.0.4-gcc10.3-1757bed/bin/../lib/gcc/xtensa-lx106-elf/10.3.0/../../../../xtensa-lx106-elf/bin/ld.exe: libraries\Time\Time.cpp.o: in function `_Z8makeTimeRK12tmElements_t':
C:\Users\dlit\Desktop\arduino-1.8.15-windows\2021_11_22\libraries\Time/Time.cpp:204: multiple definition of `_Z8makeTimeRK12tmElements_t'; sketch\Time.cpp.o:sketch/Time.cpp:204: first defined here
c:/users/dlit/appdata/local/arduino15/packages/esp8266/tools/xtensa-lx106-elf-gcc/3.0.4-gcc10.3-1757bed/bin/../lib/gcc/xtensa-lx106-elf/10.3.0/../../../../xtensa-lx106-elf/bin/ld.exe: libraries\Time\Time.cpp.o: in function `_Z7setTimex':
C:\Users\dlit\Desktop\arduino-1.8.15-windows\2021_11_22\libraries\Time/Time.cpp:274: multiple definition of `_Z7setTimex'; sketch\Time.cpp.o:sketch/Time.cpp:274: first defined here
c:/users/dlit/appdata/local/arduino15/packages/esp8266/tools/xtensa-lx106-elf-gcc/3.0.4-gcc10.3-1757bed/bin/../lib/gcc/xtensa-lx106-elf/10.3.0/../../../../xtensa-lx106-elf/bin/ld.exe: libraries\Time\Time.cpp.o:C:\Users\dlit\Desktop\arduino-1.8.15-windows\2021_11_22\libraries\Time/Time.cpp:242: multiple definition of `getTimePtr'; sketch\Time.cpp.o:sketch/Time.cpp:242: first defined here
c:/users/dlit/appdata/local/arduino15/packages/esp8266/tools/xtensa-lx106-elf-gcc/3.0.4-gcc10.3-1757bed/bin/../lib/gcc/xtensa-lx106-elf/10.3.0/../../../../xtensa-lx106-elf/bin/ld.exe: libraries\Time\Time.cpp.o: in function `_Z3nowv':
C:\Users\dlit\Desktop\arduino-1.8.15-windows\2021_11_22\libraries\Time/Time.cpp:250: multiple definition of `_Z3nowv'; sketch\Time.cpp.o:sketch/Time.cpp:250: first defined here
c:/users/dlit/appdata/local/arduino15/packages/esp8266/tools/xtensa-lx106-elf-gcc/3.0.4-gcc10.3-1757bed/bin/../lib/gcc/xtensa-lx106-elf/10.3.0/../../../../xtensa-lx106-elf/bin/ld.exe: libraries\Time\Time.cpp.o: in function `_Z4yearv':
C:\Users\dlit\Desktop\arduino-1.8.15-windows\2021_11_22\libraries\Time/Time.cpp:133: multiple definition of `_Z4yearv'; sketch\Time.cpp.o:sketch/Time.cpp:133: first defined here
c:/users/dlit/appdata/local/arduino15/packages/esp8266/tools/xtensa-lx106-elf-gcc/3.0.4-gcc10.3-1757bed/bin/../lib/gcc/xtensa-lx106-elf/10.3.0/../../../../xtensa-lx106-elf/bin/ld.exe: libraries\Time\Time.cpp.o: in function `_Z5monthv':
C:\Users\dlit\Desktop\arduino-1.8.15-windows\2021_11_22\libraries\Time/Time.cpp:124: multiple definition of `_Z5monthv'; sketch\Time.cpp.o:sketch/Time.cpp:124: first defined here
c:/users/dlit/appdata/local/arduino15/packages/esp8266/tools/xtensa-lx106-elf-gcc/3.0.4-gcc10.3-1757bed/bin/../lib/gcc/xtensa-lx106-elf/10.3.0/../../../../xtensa-lx106-elf/bin/ld.exe: libraries\Time\Time.cpp.o: in function `_Z7weekdayv':
C:\Users\dlit\Desktop\arduino-1.8.15-windows\2021_11_22\libraries\Time/Time.cpp:115: multiple definition of `_Z7weekdayv'; sketch\Time.cpp.o:sketch/Time.cpp:115: first defined here
c:/users/dlit/appdata/local/arduino15/packages/esp8266/tools/xtensa-lx106-elf-gcc/3.0.4-gcc10.3-1757bed/bin/../lib/gcc/xtensa-lx106-elf/10.3.0/../../../../xtensa-lx106-elf/bin/ld.exe: libraries\Time\Time.cpp.o: in function `_Z3dayv':
C:\Users\dlit\Desktop\arduino-1.8.15-windows\2021_11_22\libraries\Time/Time.cpp:106: multiple definition of `_Z3dayv'; sketch\Time.cpp.o:sketch/Time.cpp:106: first defined here
c:/users/dlit/appdata/local/arduino15/packages/esp8266/tools/xtensa-lx106-elf-gcc/3.0.4-gcc10.3-1757bed/bin/../lib/gcc/xtensa-lx106-elf/10.3.0/../../../../xtensa-lx106-elf/bin/ld.exe: libraries\Time\Time.cpp.o: in function `_Z6secondv':
C:\Users\dlit\Desktop\arduino-1.8.15-windows\2021_11_22\libraries\Time/Time.cpp:97: multiple definition of `_Z6secondv'; sketch\Time.cpp.o:sketch/Time.cpp:97: first defined here
c:/users/dlit/appdata/local/arduino15/packages/esp8266/tools/xtensa-lx106-elf-gcc/3.0.4-gcc10.3-1757bed/bin/../lib/gcc/xtensa-lx106-elf/10.3.0/../../../../xtensa-lx106-elf/bin/ld.exe: libraries\Time\Time.cpp.o: in function `_Z6minutev':
C:\Users\dlit\Desktop\arduino-1.8.15-windows\2021_11_22\libraries\Time/Time.cpp:88: multiple definition of `_Z6minutev'; sketch\Time.cpp.o:sketch/Time.cpp:88: first defined here
c:/users/dlit/appdata/local/arduino15/packages/esp8266/tools/xtensa-lx106-elf-gcc/3.0.4-gcc10.3-1757bed/bin/../lib/gcc/xtensa-lx106-elf/10.3.0/../../../../xtensa-lx106-elf/bin/ld.exe: libraries\Time\Time.cpp.o: in function `_Z4isPMv':
C:\Users\dlit\Desktop\arduino-1.8.15-windows\2021_11_22\libraries\Time/Time.cpp:80: multiple definition of `_Z4isPMv'; sketch\Time.cpp.o:sketch/Time.cpp:80: first defined here
c:/users/dlit/appdata/local/arduino15/packages/esp8266/tools/xtensa-lx106-elf-gcc/3.0.4-gcc10.3-1757bed/bin/../lib/gcc/xtensa-lx106-elf/10.3.0/../../../../xtensa-lx106-elf/bin/ld.exe: libraries\Time\Time.cpp.o: in function `_Z4isAMv':
C:\Users\dlit\Desktop\arduino-1.8.15-windows\2021_11_22\libraries\Time/Time.cpp:72: multiple definition of `_Z4isAMv'; sketch\Time.cpp.o:sketch/Time.cpp:72: first defined here
c:/users/dlit/appdata/local/arduino15/packages/esp8266/tools/xtensa-lx106-elf-gcc/3.0.4-gcc10.3-1757bed/bin/../lib/gcc/xtensa-lx106-elf/10.3.0/../../../../xtensa-lx106-elf/bin/ld.exe: libraries\Time\Time.cpp.o: in function `_Z12hourFormat12v':
C:\Users\dlit\Desktop\arduino-1.8.15-windows\2021_11_22\libraries\Time/Time.cpp:58: multiple definition of `_Z12hourFormat12v'; sketch\Time.cpp.o:sketch/Time.cpp:58: first defined here
c:/users/dlit/appdata/local/arduino15/packages/esp8266/tools/xtensa-lx106-elf-gcc/3.0.4-gcc10.3-1757bed/bin/../lib/gcc/xtensa-lx106-elf/10.3.0/../../../../xtensa-lx106-elf/bin/ld.exe: libraries\Time\Time.cpp.o: in function `_Z4hourv':
C:\Users\dlit\Desktop\arduino-1.8.15-windows\2021_11_22\libraries\Time/Time.cpp:49: multiple definition of `_Z4hourv'; sketch\Time.cpp.o:sketch/Time.cpp:49: first defined here
c:/users/dlit/appdata/local/arduino15/packages/esp8266/tools/xtensa-lx106-elf-gcc/3.0.4-gcc10.3-1757bed/bin/../lib/gcc/xtensa-lx106-elf/10.3.0/../../../../xtensa-lx106-elf/bin/ld.exe: libraries\Time\Time.cpp.o: in function `_Z7setTimeiiiiii':
C:\Users\dlit\Desktop\arduino-1.8.15-windows\2021_11_22\libraries\Time/Time.cpp:286: multiple definition of `_Z7setTimeiiiiii'; sketch\Time.cpp.o:sketch/Time.cpp:286: first defined here
c:/users/dlit/appdata/local/arduino15/packages/esp8266/tools/xtensa-lx106-elf-gcc/3.0.4-gcc10.3-1757bed/bin/../lib/gcc/xtensa-lx106-elf/10.3.0/../../../../xtensa-lx106-elf/bin/ld.exe: libraries\Time\Time.cpp.o: in function `_Z10adjustTimel':
C:\Users\dlit\Desktop\arduino-1.8.15-windows\2021_11_22\libraries\Time/Time.cpp:303: multiple definition of `_Z10adjustTimel'; sketch\Time.cpp.o:sketch/Time.cpp:303: first defined here
c:/users/dlit/appdata/local/arduino15/packages/esp8266/tools/xtensa-lx106-elf-gcc/3.0.4-gcc10.3-1757bed/bin/../lib/gcc/xtensa-lx106-elf/10.3.0/../../../../xtensa-lx106-elf/bin/ld.exe: libraries\Time\Time.cpp.o: in function `_Z10timeStatusv':
C:\Users\dlit\Desktop\arduino-1.8.15-windows\2021_11_22\libraries\Time/Time.cpp:307: multiple definition of `_Z10timeStatusv'; sketch\Time.cpp.o:sketch/Time.cpp:307: first defined here
c:/users/dlit/appdata/local/arduino15/packages/esp8266/tools/xtensa-lx106-elf-gcc/3.0.4-gcc10.3-1757bed/bin/../lib/gcc/xtensa-lx106-elf/10.3.0/../../../../xtensa-lx106-elf/bin/ld.exe: libraries\Time\Time.cpp.o: in function `_Z15setSyncProviderPFxvE':
C:\Users\dlit\Desktop\arduino-1.8.15-windows\2021_11_22\libraries\Time/Time.cpp:312: multiple definition of `_Z15setSyncProviderPFxvE'; sketch\Time.cpp.o:sketch/Time.cpp:312: first defined here
c:/users/dlit/appdata/local/arduino15/packages/esp8266/tools/xtensa-lx106-elf-gcc/3.0.4-gcc10.3-1757bed/bin/../lib/gcc/xtensa-lx106-elf/10.3.0/../../../../xtensa-lx106-elf/bin/ld.exe: libraries\Time\Time.cpp.o: in function `_Z15setSyncIntervalx':
C:\Users\dlit\Desktop\arduino-1.8.15-windows\2021_11_22\libraries\Time/Time.cpp:319: multiple definition of `_Z15setSyncIntervalx'; sketch\Time.cpp.o:sketch/Time.cpp:319: first defined here
collect2.exe: error: ld returned 1 exit status
exit status 1
開發板 LOLIN(WEMOS) D1 R2 & mini 編譯錯誤。
This report would have more information with
"Show verbose output during compilation"
option enabled in File -> Preferences.

Any thoughts on how to solve this?