improve readme
This commit is contained in:
parent
2ae6d49b72
commit
f03a98aadd
41
README.md
41
README.md
@ -1,22 +1,44 @@
|
||||
# LocationHub
|
||||
|
||||
Selfhosted backend for LoRaWAN based Location Tracker that support multiple location providers like GNSS, Gateway-Triangulation, WiFi-Triangulation and BLE-Triangulation.
|
||||
We suggest to use [The Things Network](https://www.thethingsnetwork.org/) (TTN) as middleware for relaying the LoRaWAN payload.
|
||||
**Self-hosted backend for LoRaWAN-based location tracking, supporting multiple location providers such as GNSS, Gateway-Triangulation, WiFi-Triangulation, and BLE-Triangulation.**
|
||||
We recommend using [The Things Network](https://www.thethingsnetwork.org/) (TTN) as middleware for relaying LoRaWAN payloads.
|
||||
|
||||
---
|
||||
|
||||
## Table of Contents
|
||||
1. [Setup](#setup)
|
||||
- [Prerequisites](#prerequisites)
|
||||
- [Database](#database)
|
||||
- [Configuration](#configuration)
|
||||
2. [TTN Integration](#ttn-integration)
|
||||
3. [Add a Location Tracker](#add-a-location-tracker)
|
||||
- [Onboard SenseCAP T1000-B](#onboard-sensecap-t1000-b)
|
||||
- [Register SenseCAP T1000-B](#register-sensecap-t1000-b)
|
||||
4. [Testing](#testing)
|
||||
- [Testing Webhook](#testing-webhook)
|
||||
- [Emulating Wigle API](#emulating-wigle-api)
|
||||
|
||||
---
|
||||
|
||||
## Setup
|
||||
|
||||
### Prerequisites
|
||||
- Node.js >= 22.11.0
|
||||
- Maria DB >= 11.6.2
|
||||
- Webserver like nginx
|
||||
Ensure the following dependencies are installed:
|
||||
- **Node.js** >= 22.11.0
|
||||
- **MariaDB** >= 11.6.2
|
||||
- A web server, such as **nginx**
|
||||
|
||||
---
|
||||
|
||||
### Database
|
||||
**Change name of database and credentials as you like!**
|
||||
**Customize the database name and credentials to your preference.**
|
||||
Follow these steps to set up the database:
|
||||
- Create new database: `CREATE DATABASE dev_locationhub;`
|
||||
- Create new user for database: `GRANT ALL PRIVILEGES ON dev_locationhub.* TO 'dbuser'@'localhost' IDENTIFIED BY '1234';`
|
||||
- Import tables: `/usr/bin/mariadb -u dbuser -p1234 dev_locationhub < server/sql/tables.sql`
|
||||
|
||||
### Configuration
|
||||
- Copy the `.env.template` to `.env` and configure as you like.
|
||||
- Copy the .env.template file and rename it to .env:
|
||||
- Use a strong token/secret for the webhook.
|
||||
- Add your [Wigle](http://wigle.net) API token to translate MAC addresses to coordinates
|
||||
- Use [systemd](server/scripts/locationhub.service) to start the server.
|
||||
@ -28,7 +50,7 @@ Add a addidtional header:
|
||||
- Value: `Bearer your-very-secure-token-from-the-env-file`
|
||||
|
||||
## Add a Location Tracker
|
||||
We use the [SenseCAP T1000-B](https://www.seeedstudio.com/SenseCAP-Card-Tracker-T1000-B-p-5698.html) from seeedstudio because of the fair price and multiple location providers. You can use any LoRaWAN enabled tracker that is able to communicate with TTN and supports the needed fields in the payload data.
|
||||
We use the [SenseCAP T1000-B](https://www.seeedstudio.com/SenseCAP-Card-Tracker-T1000-B-p-5698.html) from seeedstudio because of the fair price and multiple location providers. However, you can use any LoRaWAN-enabled tracker that is compatible with TTN and supports the required payload fields.
|
||||
|
||||
### Onboard SenseCAP T1000-B
|
||||
1. Download and install the App [SenseCraft](https://play.google.com/store/apps/details?id=cc.seeed.sensecapmate)
|
||||
@ -65,3 +87,6 @@ We use the [SenseCAP T1000-B](https://www.seeedstudio.com/SenseCAP-Card-Tracker-
|
||||
|
||||
### Emulating Wigle API
|
||||
- To emulate the Wigle API use the python script [wigle-dummy.py](server/scripts/wigle-dummy.py) to translate MAC addresses to coordinates.
|
||||
|
||||
|
||||
Happy tracking! 🎉
|
Loading…
Reference in New Issue
Block a user