fix ttn location parse

This commit is contained in:
Hendrik Schutter 2025-01-02 14:56:00 +01:00
parent 64b77c33b5
commit 7e42d3b8c9

View File

@ -33,11 +33,8 @@ const CalculateTtnGatewayLocation = (event: TtnMessageReceivedEvent) => {
}); });
// Calculate the weighted average to get the virtual location // Calculate the weighted average to get the virtual location
const virtualLocation = { virtualLocation.latitude = weightedLatitude / totalWeight;
latitude: weightedLatitude / totalWeight, virtualLocation.longitude = weightedLongitude / totalWeight;
longitude: weightedLongitude / totalWeight
};
console.log("Tracker location based on TTN Gateway location:", virtualLocation); console.log("Tracker location based on TTN Gateway location:", virtualLocation);
} }
return { return {