Skip to content

Show CGM sensor states from Nightscout notes - #763

Merged
marionbarker merged 2 commits into
devfrom
feature/cgm-sensor-state
Oct 17, 2026
Merged

marionbarker merged 2 commits into
devfrom
feature/cgm-sensor-state

Conversation

@bjorkert

@bjorkert bjorkert commented Sep 27, 2026 •

Copy link
Copy Markdown
Member

Loop (with the cgm_sensor_notes customization) and Trio (nightscout/Trio#1420) can upload a note like "CGM: temporarySensorIssue" when a Dexcom G6 or G7 reading has no reliable glucose. LoopFollow now recognizes these notes.

They get an orange triangle on the graph, placed at the last reading before the note. Before this, a note newer than the last reading was drawn at 100. The pill shows the state in plain words, for example "Temporary sensor issue".

As long as no newer reading has arrived, the state is shown under the BG on the main screen, on the snoozer and on the Live Activity (lock screen and Dynamic Island). It is also added to the text of the Missed Reading and Not Looping notifications. The next reading clears it. Alarm behavior is unchanged.

Nothing changes for users whose uploader does not send these notes.

Home Snoozer Live Activity
Notification Reading resumed
Graph pill

Loop and Trio can upload a note like "CGM: temporarySensorIssue" when the
Dexcom has no reliable reading. These notes get their own marker on the
graph, placed at the last reading before the note. While no newer reading
has arrived, the state is shown under the BG on the main screen, the
snoozer and the Live Activity, and is added to the Missed Reading and Not
Looping notifications. Alarm behavior is unchanged.
codebymini
codebymini previously approved these changes Oct 4, 2026

@codebymini codebymini left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍

# Conflicts:
#	LoopFollow/ViewControllers/BGDisplayView.swift
bjorkert added a commit to bjorkert/LoopFollow that referenced this pull request Oct 17, 2026

@marionbarker marionbarker left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code change already approved.
Test the build to an ✅ SE 2nd gen iOS 18 and an ✅ SE 3rd gen iOS 27 phone.

@marionbarker
marionbarker merged commit b89bee9 into dev Oct 17, 2026
1 check passed
@marionbarker
marionbarker deleted the feature/cgm-sensor-state branch October 17, 2026 23:39
kristinkand added a commit to kristinkand/LoopFollow that referenced this pull request Oct 25, 2026
… own start date

The merge brought upstream's loopandlearn#763 a second time (this branch had it already as 2d9a42c), so BGDisplayView
declared cgmSensorState twice. The override pills' details (loopandlearn#781) use upstream's startDate, which this branch
computes per entry: the entry's own start now.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01LgnnHLJbhxmQaEjQNYR5VZ
(cherry picked from commit d25a62f)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants