Wrong handling of specialBasalDurations (Duration15 and Duartion30 flags), and added some logging.
This commit is contained in:
parent
f5a23b2921
commit
6f19ad1407
|
@ -311,6 +311,15 @@ public enum PumpType {
|
|||
|
||||
|
||||
public PumpCapability getSpecialBasalDurations() {
|
||||
return specialBasalDurations;
|
||||
|
||||
if (isParentSet())
|
||||
{
|
||||
return parent.getSpecialBasalDurations();
|
||||
}
|
||||
else
|
||||
{
|
||||
return specialBasalDurations == null ? //
|
||||
PumpCapability.BasalRate_Duration15and30minNotAllowed : specialBasalDurations;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -420,9 +420,13 @@ public class VirtualPumpPlugin extends PluginBase implements PumpInterface {
|
|||
|
||||
PumpType pumpTypeNew = PumpType.getByDescription(pumptype);
|
||||
|
||||
log.debug("Pump in configuration: {}, PumpType object: {}", pumptype, pumpTypeNew);
|
||||
|
||||
if (pumpType == pumpTypeNew)
|
||||
return;
|
||||
|
||||
log.debug("New pump configuration found ({}), changing from previous ({})", pumpTypeNew, pumpType);
|
||||
|
||||
// reset
|
||||
pumpDescription.resetSettings();
|
||||
|
||||
|
|
Loading…
Reference in a new issue