From 3d72fbb19e524bf87d4851b7b4134130ab09aa5c Mon Sep 17 00:00:00 2001 From: Vertex <5567402+RealityAnomaly@users.noreply.github.com> Date: Thu, 12 Sep 2024 18:20:38 +0100 Subject: [PATCH 1/8] Define SX126X_ANT_SW for the RAK11200 to allow it to function correctly on the RAK19007 base (#4690) --- variants/rak11200/variant.h | 1 + 1 file changed, 1 insertion(+) diff --git a/variants/rak11200/variant.h b/variants/rak11200/variant.h index 3cd601254..259fa6e87 100644 --- a/variants/rak11200/variant.h +++ b/variants/rak11200/variant.h @@ -70,6 +70,7 @@ static const uint8_t SCK = 33; #define LORA_CS SS #define USE_SX1262 +#define SX126X_ANT_SW WB_IO2 #define SX126X_CS SS // NSS for SX126X #define SX126X_DIO1 LORA_DIO1 #define SX126X_BUSY LORA_DIO2 From d36c69396b79caa734dc3009798389fd9b6299a5 Mon Sep 17 00:00:00 2001 From: Ben Meadors Date: Fri, 13 Sep 2024 10:42:40 -0500 Subject: [PATCH 2/8] Exclude meshtasticd binaries from firmware.zip (#4698) * Exclude meshtasticd binaries from firmware.zip * Incorrect --- .github/workflows/main_matrix.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/main_matrix.yml b/.github/workflows/main_matrix.yml index 36125f72f..9b97dcb2e 100644 --- a/.github/workflows/main_matrix.yml +++ b/.github/workflows/main_matrix.yml @@ -266,7 +266,7 @@ jobs: chmod +x ./output/device-update.sh - name: Zip firmware - run: zip -j -9 -r ./firmware-${{ steps.version.outputs.version }}.zip ./output -x *.deb + run: zip -j -9 -r ./firmware-${{ steps.version.outputs.version }}.zip ./output -x meshtasticd_* - uses: actions/download-artifact@v4 with: From 8b911f14cff15c4de6d7bdedb1bac854e7382d85 Mon Sep 17 00:00:00 2001 From: rcarteraz Date: Fri, 13 Sep 2024 14:11:39 -0700 Subject: [PATCH 3/8] Update Bug Report.yml (#4702) --- .github/ISSUE_TEMPLATE/Bug Report.yml | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/.github/ISSUE_TEMPLATE/Bug Report.yml b/.github/ISSUE_TEMPLATE/Bug Report.yml index b5ca0db40..f2d2f6507 100644 --- a/.github/ISSUE_TEMPLATE/Bug Report.yml +++ b/.github/ISSUE_TEMPLATE/Bug Report.yml @@ -49,10 +49,24 @@ body: - Heltec V3 - Heltec Wireless Paper - Heltec Wireless Tracker + - Heltec Mesh Node T114 + - Heltec Vision Master E213 + - Heltec Vision Master E290 + - Heltec Vision Master T190 + - Nano G1 + - Nano G1 Explorer + - Nano G2 Ultra - Raspberry Pi Pico (W) - Relay v1 - Relay v2 - Seeed Wio Tracker 1110 + - Seeed Card Tracker T1000-E + - Station G1 + - Station G2 + - unPhone + - CanaryOne + - Chatter + - Linux Native - DIY - Other validations: From b59bd6fee9feb5370d042a4408019627138373cb Mon Sep 17 00:00:00 2001 From: rcarteraz Date: Fri, 13 Sep 2024 14:11:54 -0700 Subject: [PATCH 4/8] Update feature.yml (#4700) --- .github/ISSUE_TEMPLATE/feature.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/ISSUE_TEMPLATE/feature.yml b/.github/ISSUE_TEMPLATE/feature.yml index b027a36cc..b50ccac26 100644 --- a/.github/ISSUE_TEMPLATE/feature.yml +++ b/.github/ISSUE_TEMPLATE/feature.yml @@ -18,6 +18,7 @@ body: - ESP32 - RP2040 - Linux Native + - Cross-Platform - other validations: required: true From 35cfe4318ac422f5820415fe96ceb91ddcf79cf5 Mon Sep 17 00:00:00 2001 From: Ben Meadors Date: Fri, 13 Sep 2024 19:42:31 -0500 Subject: [PATCH 5/8] Stop past timestamps from setting our system time RTC (#4704) * Ignore attempts to set times in the past (before our build epoch) * TRONK --- platformio.ini | 1 + src/gps/RTC.cpp | 6 ++++++ 2 files changed, 7 insertions(+) diff --git a/platformio.ini b/platformio.ini index 7613a2f43..d561aaf74 100644 --- a/platformio.ini +++ b/platformio.ini @@ -81,6 +81,7 @@ build_flags = -Wno-missing-field-initializers -DRADIOLIB_EXCLUDE_APRS -DRADIOLIB_EXCLUDE_LORAWAN -DMESHTASTIC_EXCLUDE_DROPZONE=1 + -DBUILD_EPOCH=$UNIX_TIME ;-D OLED_PL monitor_speed = 115200 diff --git a/src/gps/RTC.cpp b/src/gps/RTC.cpp index c056bb9e4..42a98f568 100644 --- a/src/gps/RTC.cpp +++ b/src/gps/RTC.cpp @@ -109,6 +109,12 @@ bool perhapsSetRTC(RTCQuality q, const struct timeval *tv, bool forceUpdate) static uint32_t lastSetMsec = 0; uint32_t now = millis(); uint32_t printableEpoch = tv->tv_sec; // Print lib only supports 32 bit but time_t can be 64 bit on some platforms +#ifdef BUILD_EPOCH + if (tv->tv_sec < BUILD_EPOCH) { + LOG_WARN("Ignoring time (%ld) before build epoch (%ld)!\n", printableEpoch, BUILD_EPOCH); + return false; + } +#endif bool shouldSet; if (forceUpdate) { From ae791ca7e19583f2ccc9d7190256e8d23d7dfc89 Mon Sep 17 00:00:00 2001 From: Ben Meadors Date: Fri, 13 Sep 2024 19:43:50 -0500 Subject: [PATCH 6/8] Add buildstamp epoch to initial debug output --- src/main.cpp | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/main.cpp b/src/main.cpp index 1401f4f0b..df90c4722 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -586,6 +586,9 @@ void setup() // Hello printInfo(); +#ifdef BUILD_EPOCH + LOG_INFO("Build timestamp: %ld\n", BUILD_EPOCH); +#endif #ifdef ARCH_ESP32 esp32Setup(); From 1ab5bf43559413519d9b4e95273951eaa00da4b8 Mon Sep 17 00:00:00 2001 From: Jonathan Bennett Date: Sat, 14 Sep 2024 07:44:40 -0500 Subject: [PATCH 7/8] Use the time.age() value to correct stale GPS times (#4705) * Use the time.age() value to correct stale GPS times * Trunk --------- Co-authored-by: Ben Meadors --- src/gps/GPS.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/gps/GPS.cpp b/src/gps/GPS.cpp index 046f277ff..8abb4edb1 100644 --- a/src/gps/GPS.cpp +++ b/src/gps/GPS.cpp @@ -1539,7 +1539,7 @@ The Unix epoch (or Unix time or POSIX time or Unix timestamp) is the number of s (midnight UTC/GMT), not counting leap seconds (in ISO 8601: 1970-01-01T00:00:00Z). */ struct tm t; - t.tm_sec = ti.second(); + t.tm_sec = ti.second() + round(ti.age() / 1000); t.tm_min = ti.minute(); t.tm_hour = ti.hour(); t.tm_mday = d.day(); @@ -1547,8 +1547,8 @@ The Unix epoch (or Unix time or POSIX time or Unix timestamp) is the number of s t.tm_year = d.year() - 1900; t.tm_isdst = false; if (t.tm_mon > -1) { - LOG_DEBUG("NMEA GPS time %02d-%02d-%02d %02d:%02d:%02d\n", d.year(), d.month(), t.tm_mday, t.tm_hour, t.tm_min, - t.tm_sec); + LOG_DEBUG("NMEA GPS time %02d-%02d-%02d %02d:%02d:%02d age %d\n", d.year(), d.month(), t.tm_mday, t.tm_hour, t.tm_min, + t.tm_sec, ti.age()); perhapsSetRTC(RTCQualityGPS, t); return true; } else @@ -1807,4 +1807,4 @@ void GPS::toggleGpsMode() enable(); } } -#endif // Exclude GPS \ No newline at end of file +#endif // Exclude GPS From 8893529653cb23060f88f3ff56b092e5291facac Mon Sep 17 00:00:00 2001 From: GUVWAF <78759985+GUVWAF@users.noreply.github.com> Date: Sun, 15 Sep 2024 00:53:27 +0200 Subject: [PATCH 8/8] Make local stats number of Rx packets sum of good and bad (#4709) --- src/modules/Telemetry/DeviceTelemetry.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/modules/Telemetry/DeviceTelemetry.cpp b/src/modules/Telemetry/DeviceTelemetry.cpp index 305be9904..04789af5e 100644 --- a/src/modules/Telemetry/DeviceTelemetry.cpp +++ b/src/modules/Telemetry/DeviceTelemetry.cpp @@ -124,7 +124,7 @@ void DeviceTelemetryModule::sendLocalStatsToPhone() telemetry.variant.local_stats.num_total_nodes = nodeDB->getNumMeshNodes(); if (RadioLibInterface::instance) { telemetry.variant.local_stats.num_packets_tx = RadioLibInterface::instance->txGood; - telemetry.variant.local_stats.num_packets_rx = RadioLibInterface::instance->rxGood; + telemetry.variant.local_stats.num_packets_rx = RadioLibInterface::instance->rxGood + RadioLibInterface::instance->rxBad; telemetry.variant.local_stats.num_packets_rx_bad = RadioLibInterface::instance->rxBad; }