This repository contains a template code designed for the LilyGO T3 V1.6.1 board. The purpose of this project is to establish communication using LoRa technology to send sensor readings through a LoRa network.
This template was developed by MediaLab Uniovi, a university laboratory of technology and design that emerged in 2018 from a collaboration between the City Council of Gijón, Gijón Impulsa, and the University of Oviedo. MediaLab is headquartered at the School of Engineering of Gijón, and its main objective is to bring new technologies and project creation methodologies closer to people.
- Compatible with the LilyGO T3 V1.6.1 board
- Support for LoRa communication
- Modular and easy-to-customize template for adding new sensors
- Efficient sensor data reading and transmission
- Reliable communication with other stations in a LoRa network
- LilyGO T3 V1.6.1
- LoRa SX1276/78 module (integrated on the LilyGO board)
- Compatible sensors (you can add your own)
- Arduino IDE (or any other compatible IDE for ESP32 platforms)
- Required libraries:
- Arduino-Lmic: Library to manage LoRa communication
Wire.h
: Library for I2C communication with sensorsSPI.h
: Library for SPI communication (LoRa)- Additional libraries depending on the sensors you use
-
Clone the repository:
Clone this repository to your local machine using:
git clone https://github.com/MediaLabUniovi/Lora-Template.git
-
Set up the environment:
Open the project in Arduino IDE or your preferred IDE and ensure you have installed the necessary libraries mentioned above.
-
Connect your hardware:
- Connect the LilyGO T3 V1.6.1 to your computer using a USB cable.
- Add the required sensors according to your application and connect them to the corresponding pins.
-
Configure TTN credentials:
In the credentials code file (usually
credentials.h
), adjust the LoRa parameters such as APPEUI, DEVEUI, and APPKEY according to your TTN application:static const u1_t PROGMEM APPEUI[8] = {}; // INTRODUCE EN LSB static const u1_t PROGMEM DEVEUI[8] = {}; // INTRODUCE EN LSB static const u1_t PROGMEM APPKEY[16] = {}; // INTRODUCE EN MSB
-
Upload the code:
Select the TTGO LoRa 32-OLED board from the tools menu and upload the code to the board.
-
Power up the board: Once the code is uploaded, the board will start reading data from the connected sensors and send them over the LoRa network.
-
Data reception: The sensor data sent can be received and visualized on another LoRa-compatible device within the network range.
-
Modification and Customization: You can add new sensors by simply importing the required libraries and adding the code in the appropriate section of the template.
MediaLab Uniovi is a university laboratory of technology and design that was created in 2018 as a result of a collaboration between the City Council of Gijón, Gijón Impulsa, and the University of Oviedo. Its mission is to bring new technologies and project creation methodologies closer to people. MediaLab is based at the School of Engineering of Gijón and works to foster technological innovation and creativity.
Contributions are welcome. If you want to improve this project or add new features, feel free to open a pull request or create an issue in this repository.
This project is licensed under the MIT License.