| LoRaWan | ||
| LoRaWanNode | ||
| HT-CT62(Rev1.1).pdf | ||
| README.md | ||
LoRaWAN Sensor HT-CT62
A LoRaWAN communication project for Heltec HT-CT62 devices, featuring two Arduino sketch implementations for wireless sensor data transmission.
Overview
This project provides LoRaWAN connectivity solutions for the Heltec HT-CT62 device, supporting both basic and advanced communication modes. The system enables remote sensor monitoring through LoRaWAN networks with configurable parameters and multiple authentication methods.
Project Structure
├── LoRaWan/ # Basic LoRaWAN implementation
│ └── LoRaWan.ino # Simple LoRaWAN communication sketch
├── LoRaWanNode/ # Advanced LoRaWAN node implementation
│ └── LoRaWanNode.ino # Feature-rich node with serial commands
├── HT-CT62(Rev1.1).pdf # Device datasheet and technical documentation
└── README.md # This file
Features
Basic Implementation (LoRaWan/)
- Standard LoRaWAN Class A communication
- OTAA (Over-The-Air Activation) support
- Mock data transmission for testing
- 15-second transmission intervals
- Confirmed message transmission
Advanced Implementation (LoRaWanNode/)
- Enhanced LoRaWAN Class C communication
- Serial command interface for real-time control
- EEPROM storage for persistent configuration
- Debug mode with detailed logging
- Dynamic payload management
- Remote device restart capability
- Runtime App EUI and App Key modification
Hardware Requirements
- Device: Heltec HT-CT62 (Rev 1.1 or later)
- Connectivity: LoRaWAN gateway within range
- Development: Arduino IDE with Heltec board support
Software Requirements
- Arduino IDE
- Heltec ESP32 board package
- LoRaWAN library for Heltec devices
Configuration
Network Parameters
The project supports both OTAA and ABP activation methods:
OTAA Configuration
uint8_t devEui[] = {0x70, 0xB3, 0xD5, 0x7E, 0xD0, 0x06, 0x53, 0xC8};
uint8_t appEui[] = {0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00};
uint8_t appKey[] = {0x74, 0xD6, 0x6E, 0x63, 0x45, 0x82, 0x48, 0x27, 0xFE, 0xC5, 0xB7, 0x70, 0xBA, 0x2B, 0x50, 0x45};
Regional Settings
- Default Region: Configurable via Arduino IDE tools
- Channel Mask: Channels 0-7 enabled by default
- Data Rate: DR3 (configurable)
Advanced Node Serial Commands
The advanced implementation supports real-time commands via serial interface:
| Command | Format | Description |
|---|---|---|
1 + data |
1Hello World |
Send custom data payload |
2 |
2 |
Restart the device |
3 + 8 bytes |
3XXXXXXXX |
Change App EUI |
4 + 16 bytes |
4XXXXXXXXXXXXXXXX |
Change App Key |
Installation and Setup
- Install Arduino IDE with Heltec ESP32 support
- Clone/Download this repository
- Open desired sketch (
LoRaWan.inoorLoRaWanNode.ino) - Configure LoRaWAN parameters for your network
- Select correct board and region in Arduino IDE
- Upload the sketch to your HT-CT62 device
Usage
Basic Implementation
- Power on the device
- Monitor serial output for connection status
- Device will automatically join the network and transmit data every 15 seconds
Advanced Implementation
- Power on and monitor serial output
- Send commands via serial interface for real-time control:
1sensor_data_123 # Send sensor data 2 # Restart device 3APPEUI01 # Set new App EUI 4APPKEY1234567890AB # Set new App Key
Debug Mode
Enable debug output in the advanced implementation:
#define DEBUG_MODE 1 // Set to 1 to enable debug messages
Transmission Settings
- Duty Cycle: 15 seconds (configurable)
- Confirmed Messages: Enabled
- Retry Attempts: 4 attempts with adaptive data rate
- Application Port: 2
- Max Payload: 32 bytes
Technical Specifications
- Device Class: A (basic) / C (advanced)
- Activation: OTAA preferred, ABP supported
- ADR: Adaptive Data Rate enabled
- Regional Support: Multiple regions via Arduino IDE configuration
Troubleshooting
Common Issues
- Join Failed: Check devEui, appEui, and appKey configuration
- No Gateway: Ensure LoRaWAN gateway is within range
- Region Mismatch: Verify region settings match your location
- Payload Too Large: Keep data payload ≤ 32 bytes
Debug Steps
- Enable debug mode in advanced implementation
- Monitor serial output for detailed logs
- Verify network credentials with your LoRaWAN provider
- Check regional frequency plan compatibility
License
This project is based on Heltec Automation examples and follows their licensing terms.
Contributing
- Fork the repository
- Create a feature branch
- Commit your changes
- Push to the branch
- Create a Pull Request
Support
- Heltec Documentation: https://www.heltec.org
- LoRaWAN Specification: LoRaWAN 1.0.2+
- Hardware Manual: See
HT-CT62(Rev1.1).pdffor detailed specifications
Manufacturer: Heltec Automation
Website: www.heltec.org
Device: HT-CT62 LoRaWAN Sensor Node