Commit graph

129 commits

Author SHA1 Message Date
Johannes Mockenhaupt 03e75ab23f
Typos. 2017-12-13 15:44:07 +01:00
Johannes Mockenhaupt 5b31d39f28
Extract method checkAndWaitIfExistingTbrIsAboutToEnd. 2017-12-13 14:26:41 +01:00
Johannes Mockenhaupt 7ed64c5a7d
SetTbrCommand: verify current menu when checking running TBR. 2017-12-13 14:22:06 +01:00
Johannes Mockenhaupt 3156efaaf6
SetTbr: wait if an existing TBR is about to run out.
See code comment.
2017-12-13 13:17:04 +01:00
Johannes Mockenhaupt 536bd10e9b
Raise hard limit of max duration for zero-temp from 2h to 3h.
(cherry picked from commit 4bf6369)
2017-12-13 13:16:19 +01:00
Johannes Mockenhaupt f83dd1cb67
Unbreak RuffyCommandsV1Impl.readHistory, cleanups. 2017-12-12 00:57:04 +01:00
Johannes Mockenhaupt a6cba8b2d1
RuffyCommandsV1Impl: actually do delegation.
(cherry picked from commit 5e447ad)
2017-12-10 22:24:07 +01:00
Johannes Mockenhaupt ca9fe3e755
Fixes around bolus cancellation. 2017-12-10 01:39:58 +01:00
Johannes Mockenhaupt 6527b13934
Ignore disconnect failures. 2017-12-09 22:21:24 +01:00
Johannes Mockenhaupt bb1c1f79f1
RuffyScripter: fix on-connect checks to detect running bolus properly. 2017-12-09 22:11:41 +01:00
Johannes Mockenhaupt b8ad44ba43
Fix ReadHistoryCommand to not ignore TDD requests. 2017-12-09 19:46:28 +01:00
Johannes Mockenhaupt e286b9e3c2
RuffyScripter: read/infer pump time from menu. 2017-12-09 19:43:24 +01:00
Johannes Mockenhaupt cf142a4538
Merge pull request #4 from jotomo/verify-record-date-after-bolus-cancel
Verify and return delivered bolus amount in BolusCommand
2017-12-09 19:41:16 +01:00
Johannes Mockenhaupt 8bba8c4d5a
SetTbrCommand: handle edge case where TBR expires while a new one is being programmed. 2017-12-09 16:21:40 +01:00
Johannes Mockenhaupt d18fdc4974
Bolus used to determine last bolus must be within last/next 10min. 2017-12-09 00:37:38 +01:00
Johannes Mockenhaupt 197c116c0b
Document corner-cases when bolusing fails. 2017-12-09 00:34:08 +01:00
Johannes Mockenhaupt 2c8c25c082
Another NPE fix when ruffy isn't available. 2017-12-08 13:10:54 +01:00
Johannes Mockenhaupt f09464e5d6
Move detection of partial bolus delivery to BolusCommand.
Have BolusCommand verify delivered bolus if needed and return the
actually delivered bolus amount. This makes more sense now,
given history is only read if unavoidable.
2017-12-08 12:56:15 +01:00
Johannes Mockenhaupt e5a68608a0
Fix NPE when there's no pump. 2017-12-08 12:55:05 +01:00
Johannes Mockenhaupt 8009b32b16
Fix reading history when bolus was attempted to cancel but bolus finished before pump accepted request. 2017-12-06 20:06:56 +01:00
Johannes Mockenhaupt 60d6f305b5
Debug code. 2017-12-06 19:31:51 +01:00
Johannes Mockenhaupt 865fc63bd4
RuffyScripter: consider pump connected when BT connection is there AND menu updates are being received. 2017-12-06 17:14:30 +01:00
Johannes Mockenhaupt 1cbfefffb8
RuffyScripter: wait for command thread to finish up. 2017-12-06 16:06:16 +01:00
Johannes Mockenhaupt 960cb92789
Remove idle-disconnect-monitor and let the command queue take care of that. 2017-12-05 23:17:05 +01:00
Johannes Mockenhaupt f9867c69fb
Remove warning if pump time is off. 2017-12-05 21:46:12 +01:00
Johannes Mockenhaupt 4c1c1c43a3
Use timestamp for TBR, not pump minutes. 2017-12-05 00:08:42 +01:00
Johannes Mockenhaupt 47718723fe
RuffyScripter.confirmAlert: wait till alarm isn't displayed anymore.
(cherry picked from commit 2af7df3)
2017-11-26 12:52:24 +01:00
Johannes Mockenhaupt a0ba857279
Move WarningOrErrorCode class to parent package.
(cherry picked from commit 38922ba)
2017-11-25 21:19:21 +01:00
Johannes Mockenhaupt 63afb7bd84
SetBasalProfileCommand: fix waiting for input scrolling to complete. 2017-11-24 23:06:21 +01:00
Johannes Mockenhaupt 71b32ac078
Fix RuffyScripter.navigateToMenu one last time. 2017-11-24 23:05:46 +01:00
Johannes Mockenhaupt 5bd010d8f1
When recovering from connection loss, return to main menu to be ready for the net command. 2017-11-24 23:04:37 +01:00
Johannes Mockenhaupt 5e79900411
Small robustness improvements. 2017-11-24 23:03:34 +01:00
Johannes Mockenhaupt a95a00377b
RuffyScripter: extract and extend runPreCommandChecks(). 2017-11-24 23:03:06 +01:00
Johannes Mockenhaupt b8e320ae6f
Increase timeouts.
* Disconnect timeout: back from 2.5 to 5s.
* Overall command timeout: 4 to 10m (setting basal profile toke 5.5m
  shifting by 12h and increasing from 100% to 200%.
2017-11-24 23:00:29 +01:00
Johannes Mockenhaupt 2d7a8a2e4d
SetBasalProfileCommand, calculating steps: revert to Adrian's simpler version, add clarifying comments. 2017-11-24 21:03:49 +01:00
Johannes Mockenhaupt 9698863f90
SetBasalProfileCommand: step calculation for all ranges. 2017-11-24 08:55:36 +01:00
Johannes Mockenhaupt 90611a1792
Fix menu overshoots hopefully finally. 2017-11-23 20:54:28 +01:00
AdrianLxM 3f10c316a4 combo set basal: account for different granularity > 1 U/h 2017-11-23 01:47:14 +01:00
Johannes Mockenhaupt 0558e23eb4
SetBasalCommand: actually confirm entered values. 2017-11-23 00:11:45 +01:00
Johannes Mockenhaupt 83be0a8315
Setting basal rate on pump (combo side). 2017-11-22 22:16:28 +01:00
Johannes Mockenhaupt 1f14f37373
Make code more robust against sluggish screen updates.
Pump might take longer than a screen refresh to react to a button press,
so call waitForScreenUpdate() until we see the next desired screen has
actually arrived (used to work previously with fixed times, but that's
even less desirable).
2017-11-22 22:16:28 +01:00
Johannes Mockenhaupt 1897051782
Fix taking over low* alerts on connect. 2017-11-22 22:16:28 +01:00
Johannes Mockenhaupt f3bbf861f3
In Stop mode pump shows menus not supported by ruffy, thus require run mode for most commands. 2017-11-22 22:16:28 +01:00
Johannes Mockenhaupt b4d2d9f71d
Rename 'error' to 'alert' when referring to Combo pump alerts. 2017-11-22 00:41:56 +01:00
Johannes Mockenhaupt bb2e885b95
RuffyScripter: fix pump state check before running command. 2017-11-22 00:41:52 +01:00
Johannes Mockenhaupt 28b80697f9
Make RuffyScripter.returnToRootMenu more robust. 2017-11-22 00:05:59 +01:00
Johannes Mockenhaupt a3fe804c3d
Fix overshoot navigating to menu (again). 2017-11-22 00:05:59 +01:00
Johannes Mockenhaupt b27ee06ebe
Fix issues during history read. 2017-11-22 00:05:59 +01:00
Johannes Mockenhaupt 066d138e59
Double comparisons. 2017-11-21 22:31:28 +01:00
Johannes Mockenhaupt 426379c6d3
Remoe SetBasalProfileCommand.
Too slow, unclear usage (ProfileInterface), likely superseeded soon.
2017-11-21 09:45:34 +01:00