-
Notifications
You must be signed in to change notification settings - Fork 674
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add lora doc to getting-started.md #529
Conversation
Signed-off-by: Manuel Imperiale <manuel.imperiale@gmail.com>
Codecov Report
@@ Coverage Diff @@
## master #529 +/- ##
==========================================
- Coverage 87.28% 87.05% -0.23%
==========================================
Files 53 53
Lines 2642 2642
==========================================
- Hits 2306 2300 -6
- Misses 226 231 +5
- Partials 110 111 +1
Continue to review full report at Codecov.
|
docs/getting-started.md
Outdated
@@ -346,6 +346,83 @@ The most of the notifications received from the Adapter are non-confirmable. By | |||
|
|||
CoAP Adapter sends these notifications every 12 hours. To configure this period, please check [adapter documentation](../coap/README.md) If the client is no longer interested in receiving notifications, the second scenario described above can be used to unsubscribe | |||
|
|||
### LoRa | |||
|
|||
Before to run the Mainflux lora-adapter you must install and run a [LoRa Server](https://www.loraserver.io/loraserver/overview). Execute the following command from LoRa Server project root: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Change to Before running Mainflux lora-adapter...
. Also, following command doesn't have to be executed from LoRa Server project root, because there shouldn't be one before executing go get
.
docs/getting-started.md
Outdated
|
||
``` | ||
|
||
The Mainflux lora-adapter can do the bridge between both systems. Basically, the service subscribe to the LoRa Gateway Bridge(https://www.loraserver.io/lora-gateway-bridge/overview/), an mqtt broker that receive UDP messages from the SemTech packet-forwarder. You must configure the docker-compose.yml with the address of your LoRa Server Network, otherwise the composition will fail: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Change this to:
The Mainflux lora-adapter can do bridging between both systems. Basically, the service subscribes to the LoRa Gateway Bridge (https://www.loraserver.io/lora-gateway-bridge/overview/), MQTT bridge that receives UDP messages from SemTech packet-forwarder. You must configure docker-compose.yml with the address of your LoRa Server Network, otherwise the composition will fail:
docs/getting-started.md
Outdated
``` | ||
|
||
At this point Mainflux and LoRa Server are running. To provision the LoRa Server with Networks, Organizations, Gateways, Applications and Devices | ||
you have to implement the gRPC API. Over the LoRa Server UI, which is precisely a good example of the gRPC API implementation, you can do it as well. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
...which is good example...
docs/getting-started.md
Outdated
|
||
#### LoRa Server setup | ||
- **Create Organization:** To add your own Gateways to the network you must have an Organization. | ||
- **Add Network LoRa Server:** Set the address of your LoRa Server where the [LoRa-Gateways-Bridge](https://www.loraserver.io/lora-gateway-bridge/overview) of brocaar will forward messages over MQTT. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
...where the LoRa-Gateway-Bridge will forward...
docs/getting-started.md
Outdated
- **Create a Service-profile:** A service-profile connects an organization to a network-server and defines the features that an organization can use on this Network-Server. | ||
- **Create a Gateway:** You must set proper ID in order to be discovered by LoRa Server. | ||
- **Create a LoRa Server Application:** You can then create Devices by connecting them to this application. This is equivalent to Devices connected to channels in Mainflux. | ||
- **Create a Device-Profile:** Before to create to Device you must create Device profile where you will define some parameter as LoRaWAN MAC version (format of the device address) and the LoRaWAN regional parameter (frequency band). This will allow you to create many devices using this profile. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Before creating Device you must create Device profile...
docs/getting-started.md
Outdated
- **Create a Gateway:** You must set proper ID in order to be discovered by LoRa Server. | ||
- **Create a LoRa Server Application:** You can then create Devices by connecting them to this application. This is equivalent to Devices connected to channels in Mainflux. | ||
- **Create a Device-Profile:** Before to create to Device you must create Device profile where you will define some parameter as LoRaWAN MAC version (format of the device address) and the LoRaWAN regional parameter (frequency band). This will allow you to create many devices using this profile. | ||
- **Create a Device:** Then you can create a Device. To must configure the `network session key` and `application session key` of your Device. You can generate and copy them on your device configuration or you can use your own pre generated keys and set them from the UI. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
...and set them using UI.
docs/getting-started.md
Outdated
|
||
``` | ||
|
||
This service uses RedisDB to create a route map between both systems. As in Mainflux we use Channels to connect Things, LoRa Serser uses Applications to connect Devices. Route map create a mapping of applications ID with channels ID and Devices EUI with things ID. The lora-adapter uses the matadata of provision events emitted by mainflux-things service to update the route map. For that, you must provision Mainflux Channels and Things with an extra metadata key in the JSON Body of the HTTP request. It must be a JSON object with keys `type` and `appID` or `devEUI`. In this case `type` must be `lora`, `appID` and `devEUI` must be an existent Lora application ID and device EUI: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fix LoRa Server
, also Route map creates a mapping of...
. Fix fourth sentence Lora-adapter uses metadata from provisioning events emitted by...
docs/getting-started.md
Outdated
} | ||
``` | ||
|
||
To receive Lora messages the lora-adapter subscribes to the topic `applications/+/devices/+` of the LoRa Server. The [LoRa-Gateways-Bridge](https://www.loraserver.io/lora-gateway-bridge/overview) uses the same topic to publish decoded messages received from gateways as UDP packets. The lora-adapter verify the applicationID and the deviceEUI of published message and if they are known it forwards the message on the Mainflux NATS broker as corresponding channel and thing. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LoRa-Gateway-Bridge
. The lora-adapter verifies the applicationID and...
.
Signed-off-by: Manuel Imperiale <manuel.imperiale@gmail.com>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM!
* Add lora doc to getting-started.md Signed-off-by: Manuel Imperiale <manuel.imperiale@gmail.com> * Fix reviews Signed-off-by: Manuel Imperiale <manuel.imperiale@gmail.com> * Typo fix Signed-off-by: Manuel Imperiale <manuel.imperiale@gmail.com> * Fix doc Signed-off-by: Manuel Imperiale <manuel.imperiale@gmail.com> * Add missing components doc to architecture.md (absmach#531) Signed-off-by: Manuel Imperiale <manuel.imperiale@gmail.com> * Fix doc Signed-off-by: Manuel Imperiale <manuel.imperiale@gmail.com>
* Add lora doc to getting-started.md Signed-off-by: Manuel Imperiale <manuel.imperiale@gmail.com> * Fix reviews Signed-off-by: Manuel Imperiale <manuel.imperiale@gmail.com> * Typo fix Signed-off-by: Manuel Imperiale <manuel.imperiale@gmail.com> * Fix doc Signed-off-by: Manuel Imperiale <manuel.imperiale@gmail.com> * Add missing components doc to architecture.md (absmach#531) Signed-off-by: Manuel Imperiale <manuel.imperiale@gmail.com> * Fix doc Signed-off-by: Manuel Imperiale <manuel.imperiale@gmail.com>
* Add lora doc to getting-started.md Signed-off-by: Manuel Imperiale <manuel.imperiale@gmail.com> * Fix reviews Signed-off-by: Manuel Imperiale <manuel.imperiale@gmail.com> * Typo fix Signed-off-by: Manuel Imperiale <manuel.imperiale@gmail.com> * Fix doc Signed-off-by: Manuel Imperiale <manuel.imperiale@gmail.com> * Add missing components doc to architecture.md (#531) Signed-off-by: Manuel Imperiale <manuel.imperiale@gmail.com> * Fix doc Signed-off-by: Manuel Imperiale <manuel.imperiale@gmail.com>
Signed-off-by: Manuel Imperiale manuel.imperiale@gmail.com