DOIT ESP32 DevKit | Getting Started & Programming | ESP32 Tutorial

In this tutorial, we’ll show you how to get started with the DOIT ESP32 DevKit and how to program it.

GETTING STARTED

DOIT ESP32 DevKit is a microprocessor-based development board developed by DOIT.am. It contains ESP-WROOM-32 Wi-Fi Module, which integrates an ESP32‑D0WDQ6 Wi-Fi System-on-a-Chip (SoC). The chip is embedded with Tensilica Xtensa LX6, Dual Core 32-bit Microprocessor, which has a 4MB of external SPI Flash Memory to store the user program. It also has 520KB of SRAM and 448KB of EEPROM, which can be read and written with the EEPROM library. It runs on the clock speed of 80MHz to 240MHz. It support IEEE 802.11b/g/n wireless networking standards and operates on 2.4GHz frequency band. It also support WEP, WPA, and WPA2 security protocols. It is compliant with Bluetooth v4.2 BR/EDR and BLE specifications. The chip also integrates a Temperature Sensor, Hall Sensor, and Capacitive Touch Sensor. DOIT ESP32 DevKit uses Silicon Labs CP2102 chip, as a USB-to-Serial Convertor.

DOIT ESP32 DevKit can be programmed or powered with the USB-to-Serial connection of 5V, via Type-Micro B USB Connector.

DOIT ESP32 DevKit has 19 digital input/output pins, which are labeled D2, D4, D5, D12, D13, D14, D15, D18, D19, D21, D22, D23, D25, D26, D27, D32, D33, D34, and D35. These pins are used for general purpose input/output and can be configured by using the pinMode(), digitalRead(), and digitalWrite() functions.

DOIT ESP32 DevKit also has 14 analog input pins, which are labeled D4, D12, D13, D14, D15, D25, D26, D27, D32, D33, D34, D35, VN, and VP. These pins are connected to on-board 18-channel 12-bit Analog-to-Digital Converter (ADC) and are used to read the analog voltages by using the analogRead() function.

Both digital and analog pins can tolerate a maximum voltage of 3.3V and can provide or receive a maximum current of 40mA. Each of these pins has an internal pull-up resistor, which can be enabled by using the INPUT_PULLUP command.

VIN Pin is used to power the board with an external power supply of 7V to 12V.

3V3 Pin provides a regulated 3.3V output from the board.

GND Pins are the Ground pins.

Digital Pin D0 and D1 are RX and TX respectively are the Serial pins, which support Serial or UART communication by receiving/transmitting TTL serial data.

Digital Pin D2, D4, D5, D12, D13, D14, D15, D18, D19, D21, D22, D23, D25, D26, D27, D32, D33, D34, and D35 are the External Interrupts pins, which can be configured to trigger an interrupt on a low value, a rising or falling edge, or a change in value by using the attachInterrupt() function.

Digital Pin D2, D4, D5, D12, D13, D14, D15, D18, D19, D21, D22, D23, D25, D26, D27, D32, D33, D34, and D35 are the Pulse Width Modulation (PWM) pins, which provides 12-bit Pulse Width Modulation (PWM) output by using the ledcWrite() function.

Digital Pin D5, D18, D19, and D23 are SS, SCK, MISO, and MOSI respectively are the Serial Peripheral Interface (SPI) pins, which support Serial Peripheral Interface (SPI) communication by using the SPI library.

Digital Pin D21 and D22 are SDA and SCL respectively are the Two Wire Interface (TWI) pins, which support Two Wire Interface (TWI) or I2C communication by using the Wire library.

Digital Pin D25 and D26 are the 2-channel 8-bit Digital-to-Analog Converter (DAC) pins, which can be used to convert two digital signals into two analog voltage signal outputs.

Digital Pin D2, D4, D12, D13, D14, D15, D27, D32, and D33 are the Capacitive Touch sensing pins, which detect variations induced by touching or approaching the pins with a finger or other objects by using the touchRead() function.

VN and VP Pin is recommended for use as Analog-to-Digital Converter (ADC).

EN Pin is the Chip Enable pin, which is to be active HIGH for normal operation.

EN Button is used to reset the microprocessor when pressed.

BOOT Button enables us to flash the firmware into the microprocessor when pressed.

– There is a built-in LED which is connected to the Digital Pin D2.

COMPONENTS REQUIRED

Components that you’ll required:

DOIT ESP32 DevKit

LED

220 Ohm Resistor

400 Tie-Points Breadboard

Jumper Wire

Type-A to Type-Micro B USB Cable

Please check out here to buy these components.

CONNECTIONS

DOIT ESP32 DevKit | Getting Started & Programming | ESP32 Tutorial | Connections

DOIT ESP32 DevKit | Getting Started & Programming | ESP32 Tutorial | Connections

Now, let’s see the connections.

– Connect the anode of LED to the Digital Pin D2 of DOIT ESP32 DevKit, via a 220 Ohm Resistor.

– Connect the cathode of LED to the GND Pin of DOIT ESP32 DevKit.

PROGRAMMING

In order to program the DOIT ESP32 DevKit, you’ll need to download the software and source code from the links below.

Arduino IDE: https://www.arduino.cc/en/Main/Software

Source Code: Blink_LED.zip

Now, let’s program the DOIT ESP32 DevKit.

– Connect the one end of USB cable to the DOIT ESP32 DevKit, and another end to your Computer.

– Install the CP210x USB to UART driver, if not already installed.

– Open the sketch in the Arduino IDE. This program enables the DOIT ESP32 DevKit to turn the LED on and off depending upon the value of pin connected to the LED. When the pin value is HIGH, the LED turns on and when the pin value is LOW, the LED turns off. This program doesn’t require any library.

– Open the Preferences dialog from the File menu of Arduino IDE.

– Enter the URL of the Board Package into the Additional Board Manager URLs field.

https://dl.espressif.com/dl/package_esp32_index.json

– Open the Boards Manager from the Tools menu of Arduino IDE.

– Find the “esp32” package and click on the Install button.

– Select the proper Board from the Tools menu of Arduino IDE.

– Select the proper Serial Port from the Tools menu of Arduino IDE.

– Click on the Upload button to upload the sketch.

If the upload is successful, the message “Done uploading” will appear in the status bar of Arduino IDE. After a few seconds, you should see the LED starts blinking.

WANT TO LEARN MORE ABOUT ESP32?

Build a strong foundation in ESP32 and Open-Source Electronics with this Comprehensive Course.

eductronics™ The Complete Guide to ESP32 | ESP32 Course | ESP32 eBook

eductronics™ The Complete Guide to ESP32 | ESP32 Course | ESP32 eBook

WANT TO SUPPORT US?

We love to share our knowledge with you and we need your continued support to enable us to continue with our work with the same vigour and passion. If you like eductronics™ and appreciate the information and knowledge we provide, please consider supporting us. Every contribution, however big or small, helps us keep going!

Please visit our Support Us page to make a contribution online.

LIKED THIS TUTORIAL & WANT TO READ MORE?

Here is the list of some tutorials, that you may find useful.

Share this Post

About eductronics

eductronics™ is a team of skilled, experienced Makers and Inventors. We provide Courses, eBooks, Tutorials, and Projects on Microcontroller and Microprocessor-based Development Boards, Single Board Computers, Open-Source Electronics, Internet of Things (IoT), Home Automation, and Robotics.