How to Use Wemos ESP-Wroom-02 D1 Mini WiFi Module ESP8266 + 18650 by Using Blynk

Introduction: How to Use Wemos ESP-Wroom-02 D1 Mini WiFi Module ESP8266 + 18650 by Using Blynk


  • Compatible with nodemcu 18650 charging system integration
  • The indicator LED (green means full red means charging) can be used while charging
  • Switch control power supply
  • SMT connector can be used for sleep mode · 1 additional LED programmable (gpio16)
  • 0.5a charging current
  • 1A output
  • Overcharge protection
  • Over discharge protection
  • 10 digital pin read/write/interrupt/PWM/I2C/line support (except D0)
  • If the battery is in the wrong direction, the charging chip will be destroyed.

Features :

  • One AD inputs.
  • Micro USB inputs.
  • One programmable LED (D0).
  • AUTO PROGRAM circuit.ESP8266 (ESP-WROOM-02 With TELEC) is equivalent to the NodeMCU.
  • Analog Input (AD): Built-in dividing resistor (AD = 220K – ADC – 100K = GND).
  • There is a SOLDER terminal for SLEEP MODE.
  • Compatible With Arduino and NodeMCU.
  • Operation and charging are possible at the same time.
  • 18650 charging circuit including the 5V boosting circuit with TP5410.
  • Overcharge protection, over-discharge protection built in.
  • LED: Red = Charging, Green = Full charging.
  • 3000 mA 18650 It is possible to operate for more than 17 hours on a battery.
  • Integrated 18650 battery charging and discharging system.
  • One switch controls whether the 18650 battery is powered or not.
  • OLED’s SDA and SCL connected to the D1 pin and the D2 pin respectively.
  • The five buttons are controlled by FLASH, RESET, D5, D6, and D7 respectively.
  • The 5 Digital pins can configure the write/read/interrupt/PWM/I2C/one-wire supported separately.
  • Operation and NodeMCU consistent, adding a programmable LED, you can use GPIO16 to control, display 8266 running status and other functions.
  • Integrated OLED and five buttons, more convenient for development.
  • The design concept originates from the open source project NodeMCU, and the development board integrates 18650 charging and discharging systems with charging and discharging protection.
  • At the same time, an OLED and five directional buttons are integrated to facilitate the development.

Step 1: Material Preparation

In this tutorial we need:

  1. Wemos ESP-Wroom-02 D1 Mini Wifi Module ESP8266 + 18650 Battery Cover
  2. Micro USB cable

In this tutorial, we'll use an application from smartphone "Blynk" to control the Arduino Wemos D1 (ESP8266) with LED Traffic Light Module.

Before we begin, prepare all the item needed:

  • Breadboard
  • Wemos ESP-Wroom-02 D1 Mini Wifi Module ESP8266 + 18650 Battery Cover
  • Jumper wires male to female
  • LED Traffic Light Module ( you can also use base LEDs )
  • micro USB
  • Smartphone (You need to download "Blynk" from Play Store/iStore)
  • Ultrafire 3.7V 1100mAh Li-Ion Battery (if needed)

Step 2: Pin Connection

Follow the connection as shown above.

Step 3: Board Installation

Next, open Arduino IDE and go to [File => Preferences]. A dialog box appears. In this box, an additional board manager URL text box is present.

Step 4: Find Out in Board Manager

Next, go to [Tools => Board => Board Manager] in your Arduino IDE. The Boards Manager window appears as below. Scroll down the boards in the board manager to select ESP8266 from the list of available boards. Click on install to begin the installation.

Step 5: Select Board

Next, uploading your first program select the type of "LOLIN(WEMOS) D1 R2 & mini" board from the [Tools => Boards] section in your Arduino IDE.

Step 6: Example Code

To get the example code from the Blynk you need to download the library from Blynk website.

Follow these steps:

  1. Select "Download Blynk Library".
  2. Select to "".
  3. Extract the files and copy both of the files (libraries, tools).
  4. Open Arduino IDE go to [Files => Preferences] find the files that appears on the "Sketchbooks location".
  5. Open the Arduino file and paste both of the files you've copied.
  6. Then, open your Arduino IDE, go to [Files => Examples => Blynk => Boards Wifi =>Standalone] for the example code.

Step 7: Blynk Setup

Next, you need to set up your "Blynk" from your smartphone.

Follow these steps:

  1. Download "Blynk" at Play Store/iStore.
  2. Sign up using your email.
  3. Go to "New Project" Enter your project name (if needed).
  4. Choose device "WeMos D1 mini".
  5. Connection type "Wifi" then "Create". (After create you will receive Auth Token from your email).
  6. Slide to the left to open "Widget Box".
  7. Select "Button" to add button.
  8. Touch the button for "Button Settings".
  9. Select [Output => Digital => D2,D3,D4] to choose pin connection.
  10. Mode turn into "Switch".

Step 8: Uploading

Now you need to check out your email inbox and copy the Auth token code.

Insert the Auth Token, Network name, and Password to your programming. Now upload the code to your WeMos D1 mini through micro USB. Make sure you use the right port by select at [Tools => Port].

Step 9: Try Out Blynk Button

Select the play button from the upper right side and turn on the pin button.

Step 10: Done

Be the First to Share


    • CNC and 3D Printing Contest

      CNC and 3D Printing Contest
    • Rice & Grains Challenge

      Rice & Grains Challenge
    • Lamps Challenge

      Lamps Challenge



    1 year ago

    Where can I find info about "SMT connector can be used for sleep mode" and "SOLDER terminal for SLEEP MODE" ?


    Reply 5 months ago

    I found this image at:
    I believe the SMT pads to link are shown as GPIO16 and Sleep Mode on the left just above the blue LED.
    Note: GPIO16 is equivalent to D0, which is also the output the drives the LED, on this board.
    I've tried this with a simple sketch to test wake up after deepsleep.
    For example, put this at the end of the main loop() function:

    It goes to sleep and then appears to wake up and the LED turns on but it stalls at that pint and wont re-run the sketch ant further.

    Has anyone else got this to work successfully? If so, how?

    Ilyasaq Hazami
    Ilyasaq Hazami

    2 years ago

    Can the Wemos tell to the consumer when the battery are low and need to be charge?


    Question 2 years ago on Introduction

    What are the two buttons in left side used for??


    Answer 2 years ago

    One is reset (Bottom) and the other (Top) is to put the unit into flash mode


    2 years ago

    I can't to upload my SPIFFS image with this module, someone had problems writting to SPIFFS?


    Question 3 years ago on Step 9

    which one is the analog pin in WeMos D1 ? what is that AD pin?


    Question 3 years ago

    If i upload the sketch to the wemos, do i have to hold the flash button? If i don't, the sketch won't upload. If i do, it deletes the firmware and i can't use AT commands anymore, which i need for my projects.