Install the Arduino Software and D1 Mini

by Achim Haug

For all the AirGradient for Education build instructions we use very similar components and the same microcontroller, the Wemos D1 Mini. This tutorial explains you how to set up the Arduino IDE for this microprocessor in order to flash the software.

Install the Arduino Software

a) Please install the Arduino Software on your computer. Please do not use the web version but download and install the version for Linux, Mac, or Windows. We use this software to transfer the code to the microprocessor (and make adjustments to the code).

b) Enable the ESP8266 board (Wemos D1 Mini). You need to enable the D1 mini board in the Arduino IDE by following these steps:

  • Start Arduino and open the Preferences window.
  • Enter http://arduino.esp8266.com/stable/package_esp8266com_index.json into Additional Board Manager URLs field.
  • Open Boards Manager from Tools > Board menu and find the ESP8266 platform.
  • Select the latest version you need from a drop-down box.
  • Click the install button.
  • Don’t forget to select the Lolin (Wemos) D1 Mini board from Tools > Board menu after installation.

c) Test if the connection to the ESP8266 is working by flashing the BLINK code. The BLINK code lets the LED on the D1 MINI blink and when doing this successfully you can see if your software and cable work. To do this, please do the following:

  • In the Arduino IDE open File, Examples,01.Basic, Blink
  • Connect the D1 MINI with your USB port
  • Then go to Tools, and ensure that the Lolin (Wemos) D1 Mini board is selected
  • Then go to Tools, Port, and select the USB connection to your D1 Mini. Important if the USB connection does not show up it indicates that your cable might not provide the Data capabilities. Then please change to another cable. Also sometimes for Mac users, an additional driver might need to be installed.
  • Once you selected the Port, flash the BLINK file to the D1 MINI by clicking on the Upload Arrow
  • If you see the LED on the D1 MINI blinking, you have successfully flashed the software

If you have any problems with the above, please do not hesitate to contact us!