diff --git a/app/src/main/java/info/nightscout/androidaps/plugins/NSClientInternal/services/NSClientService.java b/app/src/main/java/info/nightscout/androidaps/plugins/NSClientInternal/services/NSClientService.java index 272959b21c..23a8eb0ae0 100644 --- a/app/src/main/java/info/nightscout/androidaps/plugins/NSClientInternal/services/NSClientService.java +++ b/app/src/main/java/info/nightscout/androidaps/plugins/NSClientInternal/services/NSClientService.java @@ -79,6 +79,7 @@ public class NSClientService extends Service { public static boolean isConnected = false; public static boolean hasWriteAuth = false; private static Integer dataCounter = 0; + private static Integer connectCounter = 0; public static String nightscoutVersionName = ""; @@ -222,7 +223,8 @@ public class NSClientService extends Service { private Emitter.Listener onConnect = new Emitter.Listener() { @Override public void call(Object... args) { - MainApp.bus().post(new EventNSClientNewLog("NSCLIENT", "connect event. ID: " + mSocket.id())); + connectCounter++; + MainApp.bus().post(new EventNSClientNewLog("NSCLIENT", "connect #" + connectCounter + " event. ID: " + mSocket.id())); sendAuthMessage(new NSAuthAck()); } }; diff --git a/app/src/main/java/info/nightscout/androidaps/plugins/Overview/OverviewFragment.java b/app/src/main/java/info/nightscout/androidaps/plugins/Overview/OverviewFragment.java index ea3d8d551a..2c68363954 100644 --- a/app/src/main/java/info/nightscout/androidaps/plugins/Overview/OverviewFragment.java +++ b/app/src/main/java/info/nightscout/androidaps/plugins/Overview/OverviewFragment.java @@ -720,6 +720,9 @@ public class OverviewFragment extends Fragment { deltaView.setText("Δ " + NSProfile.toUnitsString(glucoseStatus.delta, glucoseStatus.delta * Constants.MGDL_TO_MMOLL, units) + " " + units); avgdeltaView.setText("øΔ15m: " + NSProfile.toUnitsString(glucoseStatus.short_avgdelta, glucoseStatus.short_avgdelta * Constants.MGDL_TO_MMOLL, units) + " øΔ40m: " + NSProfile.toUnitsString(glucoseStatus.long_avgdelta, glucoseStatus.long_avgdelta * Constants.MGDL_TO_MMOLL, units)); + } else { + deltaView.setText("Δ " + MainApp.sResources.getString(R.string.notavailable)); + avgdeltaView.setText(""); } BgReading.units = profile.getUnits(); diff --git a/app/src/main/res/values/strings.xml b/app/src/main/res/values/strings.xml index c1e7737ac4..26d946581c 100644 --- a/app/src/main/res/values/strings.xml +++ b/app/src/main/res/values/strings.xml @@ -541,4 +541,5 @@ Show detailed IOB Break down IOB into bolus and basal IOB on the watchface not successful - please check phone + Not available