-
Notifications
You must be signed in to change notification settings - Fork 344
Description
Summary
Publish location solved event based on decoded payload.
Why do we need this?
To channel location solving on a single channel; the location solved application upstream message type.
This is helpful for upstream subscribers to have one source to subscribe to.
Also, this decouples application payload from location data, which is better for privacy. Currently, users have to configure the TTN Mapper integration for all their uplink message data, whereas only location data is interesting for TTN Mapper. cc @jpmeijers
What is already there? What do you see now?
When there's a geolocation integration like LoRa Cloud Geolocation for LoRa Edge devices, the location_solved message type is published by Application Server.
However, when the location coded in the application payload, like GPS coordinates, the location is only made available in a non-unified way through the uplink_message message type.
What is missing? What do you want to see?
Recognize location information from decoded uplink. This is based on predefined fields in the decoded payload.
How do you propose to implement this?
In Application Server, after decoding the payload, recognize fields like latitude, longitude (degrees), altitude, hdop and accuracy (meters). CayenneLPP coordinates should also be recognized. This is to be compatible with what TTN Mapper currently needs. See https://ttnmapper.org/faq/ under "How can I contribute data".
Integrations like TTN Mapper still rely on RX metadata, which is currently not part of location_solved messages. Therefore we cannot remove uplink_message from the TTN Mapper's webhook template (https://github.com/TheThingsNetwork/lorawan-webhook-templates/blob/e03f663772ffd04682f7a3029d1f16fb79ccb628/ttnmapper.yml#L23) but I believe this should be the aim on the longer term.
I'm also curious to hearing @jpmeijers his opinion on this matter.
How do you propose to test this?
Unit testing
Can you do this yourself and submit a Pull Request?
Yes