Book Image

Internet of Things Projects with ESP32

By : Agus Kurniawan
Book Image

Internet of Things Projects with ESP32

By: Agus Kurniawan

Overview of this book

ESP32 is a low-cost MCU with integrated Wi-Fi and BLE. Various modules and development boards-based on ESP32 are available for building IoT applications easily. Wi-Fi and BLE are a common network stack in the Internet of Things application. These network modules can leverage your business and projects needs for cost-effective benefits. This book will serve as a fundamental guide for developing an ESP32 program. We will start with GPIO programming involving some sensor devices. Then we will study ESP32 development by building a number of IoT projects, such as weather stations, sensor loggers, smart homes, Wi-Fi cams and Wi-Fi wardriving. Lastly, we will enable ESP32 boards to execute interactions with mobile applications and cloud servers such as AWS. By the end of this book, you will be up and running with various IoT project-based ESP32 chip.
Table of Contents (12 chapters)

Working with the joystick sensor module

Connecting an analog joystick to the ESP32 is easy. You can just connect this device to the analog pins. The ESP32 has two ADC1 and ADC2 pins, with some channels. You can find the analog pins with their channels on the ESP32 in figure 3-5:

Figure 3-5: ADC pinout on ESP32
Some ADC2 pins are used for internal devices such as Wi-Fi. For the ESP-WROVER-KIT board, GPIO 0, 2, 4, and 15 cannot be used for ADC due to external connections for different purposes.

Wiring

In this section, we'll perform hardware wiring between the ESP32 and analog joystick. For demo purposes, I will use the ESP-WROVER-KIT v4.1 board. We can connect our analog joystick with the ESP32 on the following wiring...