From ae117fcd9eeba4ad94a1cc99bed64fc2f663ad89 Mon Sep 17 00:00:00 2001 From: geeksville Date: Fri, 24 Jul 2020 13:00:27 -0700 Subject: [PATCH 1/6] add debug output --- .../java/com/geeksville/mesh/service/BluetoothInterface.kt | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/app/src/main/java/com/geeksville/mesh/service/BluetoothInterface.kt b/app/src/main/java/com/geeksville/mesh/service/BluetoothInterface.kt index 3be7ecf51..eb256d149 100644 --- a/app/src/main/java/com/geeksville/mesh/service/BluetoothInterface.kt +++ b/app/src/main/java/com/geeksville/mesh/service/BluetoothInterface.kt @@ -229,7 +229,7 @@ class BluetoothInterface(val service: RadioInterfaceService, val address: String s.asyncWriteCharacteristic(toRadio, a) { r -> try { r.getOrThrow() - debug("write of ${a.size} bytes completed") + debug("write of ${a.size} bytes to $uuid completed") if (isFirstSend) { isFirstSend = false @@ -295,6 +295,7 @@ class BluetoothInterface(val service: RadioInterfaceService, val address: String exceptionReporter { // If the gatt has been destroyed, skip the refresh attempt safe?.gatt?.let { gatt -> + debug("DOING FORCE REFRESH") val refresh: Method = gatt.javaClass.getMethod("refresh") refresh.invoke(gatt) } From 6265c7c32280157257b5d73eb829a871a81a44ec Mon Sep 17 00:00:00 2001 From: geeksville Date: Fri, 24 Jul 2020 13:00:38 -0700 Subject: [PATCH 2/6] update libs --- TODO.md | 1 + app/build.gradle | 4 ++-- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/TODO.md b/TODO.md index e0d620d0c..faa8c387a 100644 --- a/TODO.md +++ b/TODO.md @@ -1,5 +1,6 @@ # Remaining tasks before declaring 1.0 +- add new languages from eric: https://meshtastic.discourse.group/t/call-for-help-please-localize-the-app-for-your-language/107/61?u=geeksville - add faq entry about range and antennas and rain - first message sent is still doubled for some people - let users set arbitrary params in android diff --git a/app/build.gradle b/app/build.gradle index feac428f9..2cf6bd087 100644 --- a/app/build.gradle +++ b/app/build.gradle @@ -108,7 +108,7 @@ dependencies { implementation fileTree(dir: 'libs', include: ['*.jar']) implementation "org.jetbrains.kotlin:kotlin-stdlib:$kotlin_version" implementation 'androidx.appcompat:appcompat:1.2.0-rc01' - implementation 'androidx.core:core-ktx:1.3.0' + implementation 'androidx.core:core-ktx:1.3.1' implementation 'androidx.fragment:fragment-ktx:1.2.5' implementation 'androidx.cardview:cardview:1.0.0' implementation 'androidx.recyclerview:recyclerview:1.1.0' @@ -167,7 +167,7 @@ dependencies { implementation('com.journeyapps:zxing-android-embedded:4.1.0') { transitive = false } implementation 'com.google.zxing:core:3.4.0' - def work_version = "2.3.4" + def work_version = '2.4.0' // Work Request - used to delay boot event handling // implementation "androidx.work:work-runtime:$work_version" From 54d83dd6890007fd32212a6f44340161774728fe Mon Sep 17 00:00:00 2001 From: geeksville Date: Fri, 24 Jul 2020 15:07:51 -0700 Subject: [PATCH 3/6] add amazon appstore link --- README.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/README.md b/README.md index f3ff908d2..11ab6bbf7 100644 --- a/README.md +++ b/README.md @@ -17,6 +17,8 @@ not bleeding edge alpha test builds skip to the next step. 2. Go to this [URL](https://play.google.com/apps/testing/com.geeksville.mesh) to opt-in to the alpha/beta test. 3. If you encounter any problems or have questions, [post in the forum](https://meshtastic.discourse.group/)t and we'll help. +The app is also distributed for Amazon Fire devices via the Amazon appstore: [![Amazon appstore link](https://raw.githubusercontent.com/meshtastic/Meshtastic-device/master/images/amazon-fire-button.png)](https://www.amazon.com/Geeksville-Industries-Meshtastic/dp/B08CY9394Q) + ## Build instructions If you would like to develop this application we'd love your help! These build instructions are brief From 36e7c64fff95077b866e6cc4083ef4b876f6393a Mon Sep 17 00:00:00 2001 From: geeksville Date: Fri, 24 Jul 2020 20:51:59 -0700 Subject: [PATCH 4/6] update libs --- app/build.gradle | 2 +- geeksville-androidlib | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/app/build.gradle b/app/build.gradle index 2cf6bd087..faa6b981f 100644 --- a/app/build.gradle +++ b/app/build.gradle @@ -151,7 +151,7 @@ dependencies { implementation 'com.google.android.gms:play-services-location:17.0.0' // For Google Sign-In (owner name accesss) - implementation 'com.google.android.gms:play-services-auth:18.0.0' + implementation 'com.google.android.gms:play-services-auth:18.1.0' // Add the Firebase SDK for Crashlytics. implementation 'com.google.firebase:firebase-crashlytics:17.1.1' diff --git a/geeksville-androidlib b/geeksville-androidlib index 3cbda1733..629a5b162 160000 --- a/geeksville-androidlib +++ b/geeksville-androidlib @@ -1 +1 @@ -Subproject commit 3cbda1733e7c9b1c713f5e8c438cde3e5032026f +Subproject commit 629a5b1621d1e79772ddf00290da1edec3a74e10 From 3bcbff2f0fcbfcbf0a4d4edb222b93fd55c49c1d Mon Sep 17 00:00:00 2001 From: geeksville Date: Fri, 24 Jul 2020 21:00:58 -0700 Subject: [PATCH 5/6] update serial lib --- app/build.gradle | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/build.gradle b/app/build.gradle index faa6b981f..2bb8e9131 100644 --- a/app/build.gradle +++ b/app/build.gradle @@ -139,7 +139,7 @@ dependencies { // For UART access // implementation 'com.google.android.things:androidthings:1.0' - implementation 'com.github.mik3y:usb-serial-for-android:v2.2.2' + implementation 'com.github.mik3y:usb-serial-for-android:v2.3.0' // mapbox implementation 'com.mapbox.mapboxsdk:mapbox-android-sdk:9.2.1' From 384bb3759e87cd1438d977471df7d7577fdb2f83 Mon Sep 17 00:00:00 2001 From: geeksville Date: Sat, 25 Jul 2020 20:40:00 -0700 Subject: [PATCH 6/6] fix autobug - location callback might come after activty is dead https://console.firebase.google.com/u/0/project/meshutil/crashlytics/app/android:com.geeksville.mesh/issues/714e0b9e232289ddc9162fd3aebc1510?time=last-seven-days&sessionId=5F1C562E03E2000142C73D26354B80BF_DNE_0_v2 --- .../com/geeksville/mesh/ui/SettingsFragment.kt | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) diff --git a/app/src/main/java/com/geeksville/mesh/ui/SettingsFragment.kt b/app/src/main/java/com/geeksville/mesh/ui/SettingsFragment.kt index e8d92f8ed..284ca7f80 100644 --- a/app/src/main/java/com/geeksville/mesh/ui/SettingsFragment.kt +++ b/app/src/main/java/com/geeksville/mesh/ui/SettingsFragment.kt @@ -810,11 +810,15 @@ class SettingsFragment : ScreenFragment("Settings"), Logging { // exception.startResolutionForResult(this@MainActivity, REQUEST_CHECK_SETTINGS) // For now just punt and show a dialog - Toast.makeText( - requireContext(), - getString(R.string.location_disabled_warning), - Toast.LENGTH_SHORT - ).show() + + // The context might be gone (if activity is going away) by the time this handler is called + context?.let { c -> + Toast.makeText( + c, + getString(R.string.location_disabled_warning), + Toast.LENGTH_SHORT + ).show() + } //} else // Exceptions.report(exception)