Cirkit Designer Logo
Cirkit Designer
Your all-in-one circuit design IDE
Home / 
Component Documentation

How to Use Heltec ESP 32 Lora: Examples, Pinouts, and Specs

Image of Heltec ESP 32 Lora
Cirkit Designer LogoDesign with Heltec ESP 32 Lora in Cirkit Designer

Introduction

The Heltec ESP32 LoRa is a versatile microcontroller board developed by ESP, featuring the powerful ESP32 chip with integrated LoRa (Long Range) communication capabilities. This board is designed for IoT applications that require long-range wireless connectivity, low power consumption, and high performance. It is equipped with an OLED display, onboard Wi-Fi, and Bluetooth, making it a comprehensive solution for a wide range of projects.

Explore Projects Built with Heltec ESP 32 Lora

Use Cirkit Designer to design, explore, and prototype these projects online. Some projects support real-time simulation. Click "Open Project" to start designing instantly!
ESP32 and LoRa Communication Module for IoT Applications
Image of ESP32 LoRa: A project utilizing Heltec ESP 32 Lora in a practical application
This circuit integrates an ESP32 microcontroller with a LoRa module for wireless communication, powered by an MB102 breadboard power supply. The ESP32 handles the control signals and data exchange with the LoRa module, enabling long-range, low-power data transmission.
Cirkit Designer LogoOpen Project in Cirkit Designer
ESP32 and LoRa SX1278 Based Wireless Communication Module
Image of Esp 32 as Receiver or Sender: A project utilizing Heltec ESP 32 Lora in a practical application
This circuit integrates an ESP32 microcontroller with a LoRa Ra-02 SX1278 module to enable long-range wireless communication. The ESP32 handles the control and data processing, while the LoRa module provides the communication link. The connections include SPI interface and control signals between the ESP32 and the LoRa module, as well as shared power and ground lines.
Cirkit Designer LogoOpen Project in Cirkit Designer
ESP32C3 and LoRa-Enabled Environmental Sensing Node
Image of temperature_KA: A project utilizing Heltec ESP 32 Lora in a practical application
This circuit features an ESP32C3 Supermini microcontroller connected to a LORA_RA02 module and a DHT11 temperature and humidity sensor. The ESP32C3 handles communication with the LORA module via SPI (using GPIO05, GPIO06, GPIO10, and GPIO04 for MISO, MOSI, NSS, and SCK respectively) and GPIO01 and GPIO02 for additional control signals. The DHT11 sensor is interfaced through GPIO03 for data reading, and all components share a common power supply through the 3.3V and GND pins.
Cirkit Designer LogoOpen Project in Cirkit Designer
ESP32 and LoRa-Based GNSS and IMU Data Logger with Wireless Transmission
Image of Test 0: A project utilizing Heltec ESP 32 Lora in a practical application
This circuit consists of two ESP32 microcontrollers, each interfaced with a LoRa Ra-02 SX1278 module for wireless communication. One ESP32 is also connected to an Adafruit BNO055 sensor for orientation data and an L89HA GNSS module for location data, which it transmits via LoRa. The second ESP32 receives this data via LoRa and outputs it to the serial monitor.
Cirkit Designer LogoOpen Project in Cirkit Designer

Explore Projects Built with Heltec ESP 32 Lora

Use Cirkit Designer to design, explore, and prototype these projects online. Some projects support real-time simulation. Click "Open Project" to start designing instantly!
Image of ESP32 LoRa: A project utilizing Heltec ESP 32 Lora in a practical application
ESP32 and LoRa Communication Module for IoT Applications
This circuit integrates an ESP32 microcontroller with a LoRa module for wireless communication, powered by an MB102 breadboard power supply. The ESP32 handles the control signals and data exchange with the LoRa module, enabling long-range, low-power data transmission.
Cirkit Designer LogoOpen Project in Cirkit Designer
Image of Esp 32 as Receiver or Sender: A project utilizing Heltec ESP 32 Lora in a practical application
ESP32 and LoRa SX1278 Based Wireless Communication Module
This circuit integrates an ESP32 microcontroller with a LoRa Ra-02 SX1278 module to enable long-range wireless communication. The ESP32 handles the control and data processing, while the LoRa module provides the communication link. The connections include SPI interface and control signals between the ESP32 and the LoRa module, as well as shared power and ground lines.
Cirkit Designer LogoOpen Project in Cirkit Designer
Image of temperature_KA: A project utilizing Heltec ESP 32 Lora in a practical application
ESP32C3 and LoRa-Enabled Environmental Sensing Node
This circuit features an ESP32C3 Supermini microcontroller connected to a LORA_RA02 module and a DHT11 temperature and humidity sensor. The ESP32C3 handles communication with the LORA module via SPI (using GPIO05, GPIO06, GPIO10, and GPIO04 for MISO, MOSI, NSS, and SCK respectively) and GPIO01 and GPIO02 for additional control signals. The DHT11 sensor is interfaced through GPIO03 for data reading, and all components share a common power supply through the 3.3V and GND pins.
Cirkit Designer LogoOpen Project in Cirkit Designer
Image of Test 0: A project utilizing Heltec ESP 32 Lora in a practical application
ESP32 and LoRa-Based GNSS and IMU Data Logger with Wireless Transmission
This circuit consists of two ESP32 microcontrollers, each interfaced with a LoRa Ra-02 SX1278 module for wireless communication. One ESP32 is also connected to an Adafruit BNO055 sensor for orientation data and an L89HA GNSS module for location data, which it transmits via LoRa. The second ESP32 receives this data via LoRa and outputs it to the serial monitor.
Cirkit Designer LogoOpen Project in Cirkit Designer

Common Applications and Use Cases

  • Internet of Things (IoT) devices and networks
  • Remote environmental monitoring
  • Smart agriculture and precision farming
  • Asset tracking and geolocation
  • Industrial automation and control systems
  • Wireless sensor networks

Technical Specifications

Key Technical Details

Parameter Specification
Microcontroller ESP32 dual-core processor
Wireless Connectivity Wi-Fi 802.11 b/g/n, Bluetooth 4.2, LoRa
LoRa Frequency 433 MHz / 868 MHz / 915 MHz (region-dependent)
Flash Memory 4 MB (SPI Flash)
SRAM 520 KB
Operating Voltage 3.3V
Input Voltage Range 5V (via USB) or 3.3V (via pin)
Power Consumption Ultra-low power (varies based on usage)
OLED Display 0.96-inch, 128x64 pixels, monochrome
GPIO Pins 26 (multipurpose, including ADC, DAC, PWM, etc.)
Communication Interfaces UART, SPI, I2C, I2S
Dimensions 41 x 25 x 12 mm

Pin Configuration and Descriptions

Pin Name Pin Number Description
GND Multiple Ground pin
3V3 Multiple 3.3V power output
VIN - Power input (5V via USB or external source)
GPIO0 0 General-purpose I/O, boot mode selection
GPIO21 21 I2C SDA (default)
GPIO22 22 I2C SCL (default)
GPIO16 16 LoRa Reset (connected to LoRa module)
GPIO17 17 LoRa DIO1 (connected to LoRa module)
GPIO18 18 SPI SCK (LoRa communication)
GPIO19 19 SPI MISO (LoRa communication)
GPIO23 23 SPI MOSI (LoRa communication)
GPIO25 25 DAC1, PWM, or general-purpose I/O
GPIO26 26 DAC2, PWM, or general-purpose I/O
GPIO27 27 ADC, PWM, or general-purpose I/O

Usage Instructions

How to Use the Component in a Circuit

  1. Powering the Board:

    • Connect the board to a 5V USB power source or supply 3.3V directly to the VIN pin.
    • Ensure the power source can provide sufficient current (at least 500 mA).
  2. Connecting Peripherals:

    • Use the GPIO pins for connecting sensors, actuators, or other peripherals.
    • For I2C devices, connect them to GPIO21 (SDA) and GPIO22 (SCL).
    • For SPI communication, use GPIO18 (SCK), GPIO19 (MISO), and GPIO23 (MOSI).
  3. Programming the Board:

    • Install the Arduino IDE and add the ESP32 board support package.
    • Select "Heltec ESP32 LoRa" as the board in the Arduino IDE.
    • Connect the board to your computer via USB and upload your code.
  4. Using LoRa Communication:

    • Install the "LoRa" library in the Arduino IDE.
    • Configure the LoRa frequency to match your region (e.g., 868 MHz for Europe).

Important Considerations and Best Practices

  • Power Supply: Avoid supplying more than 3.3V to the GPIO pins to prevent damage.
  • Antenna Connection: Always connect the LoRa antenna before powering the board to avoid damaging the LoRa module.
  • Frequency Compliance: Ensure the LoRa frequency is compliant with local regulations.
  • Heat Management: The ESP32 chip may heat up during operation; ensure proper ventilation.

Example Code for Arduino UNO

Below is an example of using the Heltec ESP32 LoRa to send a simple message via LoRa:

#include <SPI.h>
#include <LoRa.h> // Include the LoRa library

#define LORA_SCK 18  // SPI Clock pin
#define LORA_MISO 19 // SPI MISO pin
#define LORA_MOSI 23 // SPI MOSI pin
#define LORA_CS 5    // LoRa chip select pin
#define LORA_RST 14  // LoRa reset pin
#define LORA_IRQ 26  // LoRa IRQ pin

void setup() {
  Serial.begin(9600); // Initialize serial communication
  while (!Serial);

  Serial.println("Initializing LoRa...");

  // Initialize LoRa with frequency 868 MHz
  if (!LoRa.begin(868E6)) {
    Serial.println("LoRa initialization failed!");
    while (1);
  }

  Serial.println("LoRa initialized successfully!");
}

void loop() {
  Serial.println("Sending message...");
  LoRa.beginPacket(); // Start a new LoRa packet
  LoRa.print("Hello, LoRa!"); // Add message to the packet
  LoRa.endPacket(); // Send the packet

  delay(5000); // Wait 5 seconds before sending the next message
}

Troubleshooting and FAQs

Common Issues and Solutions

  1. LoRa Initialization Fails:

    • Ensure the LoRa antenna is connected properly.
    • Verify the LoRa frequency matches your region.
    • Check the wiring of the LoRa module (CS, RST, and IRQ pins).
  2. Board Not Detected by Computer:

    • Confirm the USB cable is functional and supports data transfer.
    • Install the correct USB driver for the ESP32 board.
  3. OLED Display Not Working:

    • Verify the I2C connections (SDA and SCL).
    • Ensure the OLED library is installed and configured correctly.
  4. Overheating:

    • Avoid overloading the GPIO pins.
    • Use a heat sink or ensure proper ventilation if necessary.

FAQs

Q: Can I use the Heltec ESP32 LoRa with a 5V sensor?
A: Yes, but you will need a level shifter to convert the 5V signal to 3.3V for the ESP32 GPIO pins.

Q: What is the maximum range of LoRa communication?
A: The range depends on environmental factors but can reach up to 10 km in open areas.

Q: Can I power the board with a battery?
A: Yes, you can use a 3.7V LiPo battery connected to the battery connector on the board.

Q: How do I update the firmware?
A: Use the Arduino IDE or ESP32 flashing tools to upload new firmware via USB.