Merge pull request #1108 from avereha/avereha/fix-1

Dash: Reconnect on pod activation
This commit is contained in:
Milos Kozak 2021-12-30 18:50:40 +01:00 committed by GitHub
commit 46b55157ba
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 4 additions and 0 deletions

View file

@ -377,6 +377,7 @@ class OmnipodDashManagerImpl @Inject constructor(
)
}
if (podStateManager.activationProgress.isBefore(ActivationProgress.INSERTING_CANNULA)) {
observables.add(observeConnectToPod) // connection can time out while waiting
observables.add(
Observable.defer {
Observable.timer(podStateManager.secondPrimeBolusVolume!!.toLong(), TimeUnit.SECONDS)

View file

@ -2,6 +2,7 @@ package info.nightscout.androidaps.plugins.pump.omnipod.dash.util
import info.nightscout.androidaps.plugins.pump.omnipod.dash.R
import info.nightscout.androidaps.plugins.pump.omnipod.dash.driver.comm.exceptions.FailedToConnectException
import info.nightscout.androidaps.plugins.pump.omnipod.dash.driver.comm.exceptions.NotConnectedException
import info.nightscout.androidaps.plugins.pump.omnipod.dash.driver.comm.exceptions.ScanException
import info.nightscout.androidaps.plugins.pump.omnipod.dash.driver.comm.exceptions.ScanFailFoundTooManyException
import info.nightscout.androidaps.utils.resources.ResourceHelper
@ -13,6 +14,7 @@ class I8n {
is FailedToConnectException -> rs.gs(R.string.omnipod_dash_failed_to_connect)
is ScanFailFoundTooManyException -> rs.gs(R.string.omnipod_dash_found_too_many_pods)
is ScanException -> rs.gs(R.string.omnipod_dash_scan_failed)
is NotConnectedException -> rs.gs(R.string.omnipod_dash_connection_lost)
else ->
rs.gs(R.string.omnipod_dash_generic_error, exception.toString())
}

View file

@ -48,4 +48,5 @@
<string name="omnipod_common_history_bolus_value">%1$.2f U</string>
<string name="dash_bolusdelivering">Delivering %1$.2f U</string>
<string name="omnipod_common_alert_delivery_suspended">Insulin delivery is suspended</string>
<string name="omnipod_dash_connection_lost">Lost connection to pod</string>
</resources>