TTN HTTP integration metadata device location/position

Can the device coordinates in the metadata be set from the device GPS position?
Can this be set from a decoder using payload data?
Is it a automatically calculated field?
Or is it only possible to set it manually in the device settings on the web page?
What is this position data, and what different methods can be used to set this position data?
Can I somehow set the location source, or is this something else?

{
    "time": "2019-03-03T12:47:50.624474908Z",
    "frequency": 868.1,
    "modulation": "LORA",
    "data_rate": "SF12BW125",
    "coding_rate": "4/5",
    "gateways": [
        {
            "gtw_id": "eui-b827ebfffee2b605",
            "timestamp": 485715212,
            "time": "",
            "channel": 0,
            "rssi": -60,
            "snr": 9.8,
            "rf_chain": 1,
            "latitude": 61.510452,
            "longitude": 6.151432,
            "altitude": 235,
            "location_source": "registry"
        }
    ],
--->"latitude": 61.51543,
--->"longitude": 6.2156367,
--->"altitude": 207,
    "location_source": "registry"
}

It depends.
If your device has a fixed position (and thus does not need a GPS), you can set its position in the console, and you will automatically find its coordinates as above.
If your device has a GPS, you can send its coordinates via LoRaWAN but they will be among the payload fields, and you will have to decode them with a decoder function /thus in the payload_fields field of the JSON file).

1 Like

Can I update this metadata position based on payload data automatically? Or is it not meant to be used this way?

1 Like

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.