From b8c1bfe1fa546e15b54d5f3f7f14f6d9ad56c65b Mon Sep 17 00:00:00 2001 From: Harsh Sharma Date: Thu, 4 Aug 2022 16:32:06 -0500 Subject: Updated lora packet forwarder recipe and lns init script --- .../lora/lora-gateway/lora_gateway-gpsd-3.23.patch | 55 ++++++++++++++++++++++ 1 file changed, 55 insertions(+) create mode 100644 recipes-connectivity/lora/lora-gateway/lora_gateway-gpsd-3.23.patch (limited to 'recipes-connectivity/lora/lora-gateway') diff --git a/recipes-connectivity/lora/lora-gateway/lora_gateway-gpsd-3.23.patch b/recipes-connectivity/lora/lora-gateway/lora_gateway-gpsd-3.23.patch new file mode 100644 index 0000000..25b0d25 --- /dev/null +++ b/recipes-connectivity/lora/lora-gateway/lora_gateway-gpsd-3.23.patch @@ -0,0 +1,55 @@ +From d631d2a3c35baac66d75acea0b2e25a6b804c7e1 Mon Sep 17 00:00:00 2001 +From: Serhii Voloshynov +Date: Tue, 8 Feb 2022 15:56:18 +0200 +Subject: [PATCH] gpsd: add fixes to support new gpsd 3.23 + +--- + libloragw/inc/loragw_gps.h | 1 + + libloragw/tst/test_loragw_gps.c | 5 +++-- + 2 files changed, 4 insertions(+), 2 deletions(-) + +diff --git a/libloragw/inc/loragw_gps.h b/libloragw/inc/loragw_gps.h +index 0714974..dd4aa0f 100644 +--- a/libloragw/inc/loragw_gps.h ++++ b/libloragw/inc/loragw_gps.h +@@ -27,6 +27,7 @@ Maintainer: Michael Coracin + #include /* time library */ + #include /* speed_t */ + #include /* ssize_t */ ++#include + #include + #include + #include /* error messages */ +diff --git a/libloragw/tst/test_loragw_gps.c b/libloragw/tst/test_loragw_gps.c +index 994c0ad..d6706b7 100644 +--- a/libloragw/tst/test_loragw_gps.c ++++ b/libloragw/tst/test_loragw_gps.c +@@ -31,6 +31,7 @@ Maintainer: Michael Coracin + #include /* sigaction */ + #include /* exit */ + #include /* read */ ++#include + #include + #include + +@@ -128,7 +129,7 @@ int main() + while ((quit_sig != 1) && (exit_sig != 1)) { + wait_ms(100); + int r = gps_read(&gpsdata, 0, 0); +- if (r!= -1 && (gpsdata.status != STATUS_NO_FIX) && ++ if (r!= -1 && (gpsdata.fix.status != STATUS_NO_FIX) && + (gpsdata.fix.mode == MODE_2D || gpsdata.fix.mode == MODE_3D) && + !isnan(gpsdata.fix.latitude) && + !isnan(gpsdata.fix.longitude)) { +@@ -142,7 +143,7 @@ int main() + printf("\n--- GPS ---\n"); + printf("Set: %lld\n", gpsdata.set); + printf("Online: %10.0f\n", gpsdata.online); +- printf("Status: %d\n", gpsdata.status); ++ printf("Status: %d\n", gpsdata.fix.status); + printf("Satellites Used: %d\n", gpsdata.satellites_used); + printf("Mode: %d\n", gpsdata.fix.mode); + printf("UTC time: %lld.%09ld\n", (long long)time_reference_gps.utc.tv_sec, time_reference_gps.utc.tv_nsec); +-- +2.25.1 + -- cgit v1.2.3