mirror of
https://github.com/meshtastic/Meshtastic-Android.git
synced 2026-04-20 22:23:37 +00:00
commit
c5df728f02
5 changed files with 16 additions and 10 deletions
6
TODO.md
6
TODO.md
|
|
@ -1,12 +1,12 @@
|
|||
# Remaining tasks before declaring 1.0
|
||||
|
||||
- fix release build inclusion of firmware
|
||||
- feh123 problem sony
|
||||
- fix release build inclusion of firmware - per https://developer.android.com/studio/build/build-variants
|
||||
- Android frontend should refetch the android messages from backend service on Resume
|
||||
- disable software update button after update finishes
|
||||
- first message sent is still doubled for some people
|
||||
- let users set arbitrary params in android
|
||||
* add a low level settings screen (let user change any of the RadioConfig parameters)
|
||||
- optionally include firmware files in debug builds - currently they are release only. per https://developer.android.com/studio/build/build-variants
|
||||
- add a low level settings screen (let user change any of the RadioConfig parameters)
|
||||
|
||||
Things for the betaish period.
|
||||
|
||||
|
|
|
|||
|
|
@ -17,8 +17,8 @@ android {
|
|||
applicationId "com.geeksville.mesh"
|
||||
minSdkVersion 21 // The oldest emulator image I have tried is 22 (though 21 probably works)
|
||||
targetSdkVersion 29
|
||||
versionCode 10783 // format is Mmmss (where M is 1+the numeric major number
|
||||
versionName "0.7.83"
|
||||
versionCode 10784 // format is Mmmss (where M is 1+the numeric major number
|
||||
versionName "0.7.84"
|
||||
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
|
||||
}
|
||||
buildTypes {
|
||||
|
|
|
|||
|
|
@ -10,6 +10,7 @@ import com.geeksville.concurrent.handledLaunch
|
|||
import com.geeksville.util.anonymize
|
||||
import com.geeksville.util.exceptionReporter
|
||||
import com.geeksville.util.ignoreException
|
||||
import kotlinx.coroutines.CancellationException
|
||||
import kotlinx.coroutines.Job
|
||||
import kotlinx.coroutines.delay
|
||||
import java.lang.reflect.Method
|
||||
|
|
@ -319,7 +320,7 @@ class BluetoothInterface(val service: RadioInterfaceService, val address: String
|
|||
* Some buggy BLE stacks can fail on initial connect, with either missing services or missing characteristics. If that happens we
|
||||
* disconnect and try again when the device reenumerates.
|
||||
*/
|
||||
private suspend fun retryDueToException() {
|
||||
private suspend fun retryDueToException() = try {
|
||||
/// We gracefully handle safe being null because this can occur if someone has unpaired from our device - just abandon the reconnect attempt
|
||||
val s = safe
|
||||
if (s != null) {
|
||||
|
|
@ -340,6 +341,8 @@ class BluetoothInterface(val service: RadioInterfaceService, val address: String
|
|||
} else {
|
||||
warn("Abandoning reconnect because safe==null, someone must have closed the device")
|
||||
}
|
||||
} catch (ex: CancellationException) {
|
||||
warn("retryDueToException was cancelled")
|
||||
}
|
||||
|
||||
/// We only try to set MTU once, because some buggy implementations fail
|
||||
|
|
@ -402,7 +405,7 @@ class BluetoothInterface(val service: RadioInterfaceService, val address: String
|
|||
|
||||
// we begin by setting our MTU size as high as it can go (if we can)
|
||||
if (shouldSetMtu)
|
||||
safe!!.asyncRequestMtu(512) { mtuRes ->
|
||||
safe?.asyncRequestMtu(512) { mtuRes ->
|
||||
try {
|
||||
mtuRes.getOrThrow() // FIXME - why sometimes is the result Unit!?!
|
||||
debug("MTU change attempted")
|
||||
|
|
@ -424,6 +427,9 @@ class BluetoothInterface(val service: RadioInterfaceService, val address: String
|
|||
|
||||
|
||||
override fun close() {
|
||||
reconnectJob?.cancel() // Cancel any queued reconnect attempts
|
||||
reconnectJob = null
|
||||
|
||||
if (safe != null) {
|
||||
info("Closing BluetoothInterface")
|
||||
val s = safe
|
||||
|
|
|
|||
|
|
@ -1180,7 +1180,7 @@ class MeshService : Service(), Logging {
|
|||
else -> errormsg("Unexpected FromRadio variant")
|
||||
}
|
||||
} catch (ex: InvalidProtocolBufferException) {
|
||||
Exceptions.report(ex, "Invalid Protobuf from radio, len=${bytes.size}")
|
||||
errormsg("Invalid Protobuf from radio, len=${bytes.size}", ex)
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -1285,7 +1285,7 @@ class MeshService : Service(), Logging {
|
|||
if (configCompleteId == configNonce) {
|
||||
// This was our config request
|
||||
if (newMyNodeInfo == null || newNodes.isEmpty())
|
||||
reportError("Did not receive a valid config")
|
||||
errormsg("Did not receive a valid config")
|
||||
else {
|
||||
debug("Installing new node DB")
|
||||
discardNodeDB()
|
||||
|
|
|
|||
|
|
@ -1 +1 @@
|
|||
Subproject commit 792b33a4a82316d0e15be1e15fcf2d777fdc41e0
|
||||
Subproject commit 9f83006768de5ca714f4c43e723a3477a91d0713
|
||||
Loading…
Add table
Add a link
Reference in a new issue