Disable loop when selected basal rate is not 1.
This commit is contained in:
parent
dd98d9f7ae
commit
cda621f32b
|
@ -798,7 +798,7 @@
|
|||
<string name="combo_pump_bolus_verification_failed">Bolus delivery verification failed. The pump history will be read again on the next loop run or when refreshing from the Combo page. Please check and bolus again if needed.</string>
|
||||
<string name="combo_pump_unsupported_operation">Requested operation not supported by pump</string>
|
||||
<string name="combo_bolus_bolus_delivery_failed">Bolus delivery failed. A (partial) bolus might have been delivered. Attempting to update history from pump. Please check the Combo page and bolus again as needed.</string>
|
||||
<string name="combo_force_disabled">Unsafe usage: extended or multiwave boluses have been delivered within the last 6 hours. Loop mode has been disabled until 6 hours after the last unsupported bolus. Only normal boluses are supported in loop mode.</string>
|
||||
<string name="combo_force_disabled">Unsafe usage: extended or multiwave boluses have been delivered within the last 6 hours or the selected basal rate is not 1. Loop mode has been disabled until 6 hours after the last unsupported bolus or basal rate profile. Only normal boluses are supported in loop mode with basal rate profile 1.</string>
|
||||
<string name="bolus_frequency_exceeded">A bolus with the same amount was requested within the last minute. For safety reasons this is disallowed.</string>
|
||||
</resources>
|
||||
|
||||
|
|
|
@ -442,8 +442,9 @@ public class RuffyScripter implements RuffyCommands {
|
|||
if (menuType == MenuType.MAIN_MENU) {
|
||||
Double tbrPercentage = (Double) menu.getAttribute(MenuAttribute.TBR);
|
||||
BolusType bolusType = (BolusType) menu.getAttribute(MenuAttribute.BOLUS_TYPE);
|
||||
if (bolusType != null && bolusType != BolusType.NORMAL) {
|
||||
// unsupported Extended/Multiwave bolus running
|
||||
Integer activeBasalRate = (Integer) menu.getAttribute(MenuAttribute.BASAL_SELECTED);
|
||||
|
||||
if (bolusType != null && bolusType != BolusType.NORMAL || !activeBasalRate.equals(1)) {
|
||||
state.unsafeUsageDetected = true;
|
||||
} else if (tbrPercentage != 100) {
|
||||
state.tbrActive = true;
|
||||
|
|
Loading…
Reference in a new issue