No description
- C++ 93%
- JavaScript 7%
| .vscode | ||
| include | ||
| lib | ||
| src | ||
| test | ||
| .gitignore | ||
| .gitlab-ci.yml | ||
| platformio.ini | ||
| Readme.md | ||
| uplink-decoder.js | ||
Lora Temperature Sensor
This is a simple project for a outdoor temperature sensor, which sends the temperature via lorawan. The sensor is based on the Heltect ESP32 LoRa Board and a DS18B20 temperature sensor. In the config file is already the appkey configured to make the setup as simple as possible.
Hardware Setup
Connect the DS18B20 sensor pin (yellow) to GPIO17 and a 4,7k Resistor between vext and GPIO17. Then connect the positive (red) wire to VEXT and the negative (black) wire to GND. Now flash the firmware, either using platformio to compile it yourself or use the precompiled firmware from the CI Pipeline. After flashing connect to the Serial console and note down the DEVEUI.
TTN Setup
- Create a new application in TTN
- Create a new device in the application:
- Specify the device manual:
- Frequency Plan: EU 863, SF9 for RX2
- Lorawan Version: 1.0.0
- JoinEUI: 0000000000000000
- DevEUI: The one you noted down before
- AppKey: 21DD665CA8AC4741CB40AEFB6AFF474E
- End device ID: The name of the device
- Create the device
- Go to payload formatters -> uplink and set the type to Custom JavaScript. Afterwards paste the content from uplink-decoder.js into the field and save it.
- Reconnect power to your sensor and wait for the first message to arrive in the console.
- Specify the device manual: