more debug on setting temp basal
This commit is contained in:
parent
4e4088f164
commit
6ab6f82b10
1 changed files with 7 additions and 1 deletions
|
@ -380,6 +380,9 @@ public class DanaRPlugin implements PluginBase, PumpInterface, DanaRInterface, C
|
||||||
if (percentRate > getPumpDescription().maxTempPercent) {
|
if (percentRate > getPumpDescription().maxTempPercent) {
|
||||||
percentRate = getPumpDescription().maxTempPercent;
|
percentRate = getPumpDescription().maxTempPercent;
|
||||||
}
|
}
|
||||||
|
if (Config.logPumpActions)
|
||||||
|
log.debug("setTempBasalAbsolute: Calculated percent rate: " + percentRate);
|
||||||
|
|
||||||
// If extended in progress
|
// If extended in progress
|
||||||
if (MainApp.getConfigBuilder().isInHistoryExtendedBoluslInProgress() && useExtendedBoluses) {
|
if (MainApp.getConfigBuilder().isInHistoryExtendedBoluslInProgress() && useExtendedBoluses) {
|
||||||
if (Config.logPumpActions)
|
if (Config.logPumpActions)
|
||||||
|
@ -393,7 +396,10 @@ public class DanaRPlugin implements PluginBase, PumpInterface, DanaRInterface, C
|
||||||
// Check if some temp is already in progress
|
// Check if some temp is already in progress
|
||||||
if (MainApp.getConfigBuilder().isInHistoryRealTempBasalInProgress()) {
|
if (MainApp.getConfigBuilder().isInHistoryRealTempBasalInProgress()) {
|
||||||
// Correct basal already set ?
|
// Correct basal already set ?
|
||||||
if (MainApp.getConfigBuilder().getRealTempBasalFromHistory(System.currentTimeMillis()).percentRate == percentRate) {
|
TemporaryBasal running = MainApp.getConfigBuilder().getRealTempBasalFromHistory(System.currentTimeMillis());
|
||||||
|
if (Config.logPumpActions)
|
||||||
|
log.debug("setTempBasalAbsolute: currently running: " + running.toString());
|
||||||
|
if (running.percentRate == percentRate) {
|
||||||
result.success = true;
|
result.success = true;
|
||||||
result.percent = percentRate;
|
result.percent = percentRate;
|
||||||
result.absolute = MainApp.getConfigBuilder().getTempBasalAbsoluteRateHistory();
|
result.absolute = MainApp.getConfigBuilder().getTempBasalAbsoluteRateHistory();
|
||||||
|
|
Loading…
Reference in a new issue