Skip to content

Remote Overrides Don't Support All Loop Functions #26

@gestrich

Description

@gestrich

Loop supports overrides to start at a time in the future. This capability does not exist as a remote feature in Nightscout. The fields in Nightscout are available to set a time but that is not forwarded to Loop in the push notification.

Additionally, Loop supports "indefinite" overrides but there is not a field to send this. Loop treats Double.inifinite as an indefinite override but we likely can't send that kind of value through JSON. We could include a checkbox on Nightscout for this and a boolean indefinite that gets sent in the payload. Care will be needed to handle cases where both a duration and indefinite=true is sent -- which is undefined.

Finally, we could support changing the % percent of the override temporarily, like Loop allows.

A few notes to get started on these change:

Caregiver Updates

A few places to add the start time:

  • OverrideAction
  • NSRemoteCommandPayload
  • OverrideRemoteNotification (consider using either startDate or "start-time", like carbs).

Nightscout Updates

  • careportal.js. See the inputMatrix assigned for overrides
  • lib/plugins/loop.js: We can add new UI - See lines like prebolus: false for examples
  • lib/server/loop.js: Parse new values. See example if (data.duration !== undefined && parseInt(data.duration) > 0) {

Loop Updates

We will need to parse the new values on the Loop side and validate them.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions