From 04720e2f0e758084cfa26d90e8b357af30ea327b Mon Sep 17 00:00:00 2001 From: geeksville Date: Thu, 12 Mar 2020 12:03:40 -0700 Subject: [PATCH] fix crashlytics: if user shuts off bluetooth during scan, ignore failure # Conflicts: # app/src/main/java/com/geeksville/mesh/ui/BTScanScreen.kt --- TODO.md | 3 ++- .../mesh/service/{SimRadio.disabled => SimRadio.kt} | 5 ++--- 2 files changed, 4 insertions(+), 4 deletions(-) rename app/src/main/java/com/geeksville/mesh/service/{SimRadio.disabled => SimRadio.kt} (93%) diff --git a/TODO.md b/TODO.md index 33c9cae2..f8f6a73d 100644 --- a/TODO.md +++ b/TODO.md @@ -5,7 +5,6 @@ Work items for soon alpha builds * make link sharing work * finish map view * run services in sim mode on emulator -* track radio brands/regions as a user property (include no-radio as an option) * show offline nodes as greyed out * show time since last contact on the node info card * show pointer arrow on the outside of the user icons, always pointing towoards them @@ -214,3 +213,5 @@ Transition powerFSM transition=Screen-on timeout, from=ON to=DARK NOTE: no debug messages on device, though we see in radio interface service we are repeatedly reading FromRadio and getting the same seven bytes. It sure seems like the old service is still sort of alive... +* track radio brands/regions as a user property (include no-radio as an option) + diff --git a/app/src/main/java/com/geeksville/mesh/service/SimRadio.disabled b/app/src/main/java/com/geeksville/mesh/service/SimRadio.kt similarity index 93% rename from app/src/main/java/com/geeksville/mesh/service/SimRadio.disabled rename to app/src/main/java/com/geeksville/mesh/service/SimRadio.kt index 96822be0..88330844 100644 --- a/app/src/main/java/com/geeksville/mesh/service/SimRadio.disabled +++ b/app/src/main/java/com/geeksville/mesh/service/SimRadio.kt @@ -1,10 +1,9 @@ package com.geeksville.mesh import android.content.Context -import com.google.protobuf.util.JsonFormat +import com.geeksville.mesh.service.RadioInterfaceService class SimRadio(private val context: Context) { - private val jsonParser = JsonFormat.parser() /** * When simulating we parse these MeshPackets as if they arrived at startup @@ -42,7 +41,7 @@ class SimRadio(private val context: Context) { simInitPackets.forEach { json -> val fromRadio = MeshProtos.FromRadio.newBuilder().apply { packet = MeshProtos.MeshPacket.newBuilder().apply { - jsonParser.merge(json, this) + // jsonParser.merge(json, this) }.build() }.build()