Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allows to open CGM setting view when tapping on the homescree #24

Conversation

avouspierre
Copy link
Contributor

Change the behavior of the tap of the BG on the home screen :

  • if nightscout, open directly nightscout web site
  • if xdrip, glucose direct and (old) app transmetter, open the app
  • if dexcom (G5,G6 G7) or Libre transmitter, open the Settings View.

The beahavior is compliance with Pump tap.

CleanShot 2024-03-20 at 06 34 35

Change the behavior of the tap of the BG on the home screen :
- if nightscout, open directly nightscout web site
- if xdrip, glucose direct and (old) app transmetter, open the app
- if dexcom (G5,G6 G7) or Libre transmitter, open the Settings View like Pump manager.
@Sjoerd-Bo3
Copy link
Contributor

Sjoerd-Bo3 commented Mar 20, 2024

Okay, I get that it is uniform behaviour. But I use G7 and I never use the settings screen ever. Only tap bg to go to the dexcom app to start it up or wake it up. I don’t get the use case for the settings. Please enlight me😂

@AndreasStokholm
Copy link
Contributor

I'm with @Sjoerd-Bo3 here. I touch the settings for CGM maybe once every 2 months, but I do use the CGM reading to quickly go to the Dexcom app. I'd like to understand what the use case for going to settings is too 😄

@avouspierre
Copy link
Contributor Author

Arg ! I found the similar behavior with Pump (and with Loop) could be important and when I use G6 or freestyle, I prefer to go to the CGM settings because it's the only solution to know the age of my transmitter (G6 with anubus) and more useful information with Libre.

I can propose to add a option (toggle) in CGM like " Tap on the CGM open directly the app" ? @AndreasStokholm @Sjoerd-Bo3 ?

For G6, the default app is Dexcom G6 or xDRIP ?

@Sjoerd-Bo3
Copy link
Contributor

A toggle works for me

@AndreasStokholm
Copy link
Contributor

Toggle works for me too. I know that G6 can use both xDrip and the Dexcom G6 app. Not sure how the config around that works though. @dnzxy can you maybe weigh in?

@bjornoleh
Copy link
Contributor

bjornoleh commented Mar 20, 2024

Arg ! I found the similar behavior with Pump (and with Loop) could be important and when I use G6 or freestyle, I prefer to go to the CGM settings because it's the only solution to know the age of my transmitter (G6 with anubus) and more useful information with Libre.

I can propose to add a option (toggle) in CGM like " Tap on the CGM open directly the app" ? @AndreasStokholm @Sjoerd-Bo3 ?

For G6, the default app is Dexcom G6 or xDRIP ?

For G6, I'd have tapping the BG value open the Dexcom G6 app. And of course, if Xdrip4iOS is selected as CGM, go to that app.

The combo of G6 as CGM selected in OiAPS, G6 app as receiver app and xdrip in "listening mode" does not really involve OiAPS in any way, and can be disregarded? I think that combination would perhaps be used by some to get xdrip alarms or xdrip statistics, but OiAPS would currently not know about this.

@bjornoleh
Copy link
Contributor

bjornoleh commented Mar 20, 2024

On a related note, I have disliked the dual functionality of opening the CGM app and dealing with alarms by short tap on the BG value. For myself (who are not using the built in alarms), I have changed the behaviour to always open the CGM app, and only on long press open the alarms dialogue (which is never really used). I'd suggest a different shortcut for alarms, for those that use this. Perhaps something to consider for the new UI (outside of the scope here). But in general, long presses is not my favourite (it's fine for forced loop, once you know about it).

@avouspierre
Copy link
Contributor Author

@bjornoleh I can propose in this PR to have the same behavior even if you are low BG with tap --> open CGM and snooze alarm --> long tap.

@bjornoleh
Copy link
Contributor

For the use case of accessing the sensor age within OiAPS, we could do this a different way than by opening CGM settings:

For the sensors that support this, we could display sensor age (SAGE) directly. Possibly by only displaying an icon or similar visible notification towards the end of the sensor life. I think Jon added something similar for pump age, a clock icon of sorts? Then perhaps a user setting for when the notification/icon will appear (after xx days/hours).

In Loop, I think they added a small indicator line whose length is analogous to the sensor life or remaining sensor life. I remember that there were discussions about difficulties in understanding the graphical representation, not sure what they have landed on now.

@bjornoleh
Copy link
Contributor

@bjornoleh I can propose in this PR to have the same behavior even if you are low BG with tap --> open CGM and snooze alarm --> long tap.

Yes, that would work for me (it's what I did), but I never used the alarms, so those that do use them should also weigh in :-)

@dnzxy
Copy link
Contributor

dnzxy commented Mar 20, 2024

Admittedly haven’t read all comments. From a standardization point of view, I welcome this behavior simply because for NS and xDrip4iOS (other 3rd party apps) this did not work like it does for G6 and G7 stock apps.

I do have to say I find it very weird though that the CGM app opens anyways. It doesn’t really make sense to me and accidentally tapping the glucose value breaks the "app user interaction“ and sends you to another app.

I also really really dislike the double functionality of glucose values paired with the absolutely unnecessary glucose push notifications ("alerts") of the app. When there is no alert happening, tapping the glucose sends you to the app and long pressing it opens the snooze menu. When there is an alert, tapping it opens the snooze menu and long pressing will take you to the CGM app. It’s such a nonsensical UX and super unnecessary to exist in the first place 😂

edit to add: @bjornoleh already mentioned this, I concur!

edit 2 to add: long pressing is also bad UI/UX. user actions that are necessary, such as alert snoozing or other functionality, should always be intuitive and visible to the user. Something like hiding away functionality with a long press is a thing that is not good and anyone involved in HCI would scold you for that type of functionality 😂

@AndreasStokholm
Copy link
Contributor

I think what you're saying makes a lot of sense @dnzxy - I could be convinced to unlearn going to an external app by tapping the glucose value.

@flyingpie101
Copy link

I am with @dnzxy here. I have always found it weird to launch other apps. I always expect the tapping to either bring me to settings for that 'feature' or to bring up a more detailed view of the tappable area.

@dnzxy
Copy link
Contributor

dnzxy commented Mar 20, 2024

I am with @dnzxy here. I have always found it weird to launch other apps. I always expect the tapping to either bring me to settings for that 'feature' or to bring up a more detailed view of the tappable area.

Shared expectation here. I always expect to be taken to the detail view of Settings > CGM just like it works when you tap the pump related info and it takes you to that section of the settings.

@bjornoleh
Copy link
Contributor

bjornoleh commented Mar 20, 2024

For the case of Xdrip, there’s not much to display in terms of settings, but maybe it could be appropriate to add a button to open the app from here?:

image

It could actually be convenient to easily see that screen, to see that the transmitter BT address is populated (unlike in my screenshot on a non looping phone)

@bjornoleh
Copy link
Contributor

I checked in Loop, and with NS as CGM, the NS site is opened. With G6 the settings screen is opened, which has an “Open App” button, G7 and Libre settings screens doesn’t have such a button (a PR to LoopKit might get that in place if needed).

Loop also lets you set up a CGM by tapping the same are if not already configured

@marionbarker
Copy link
Contributor

marionbarker commented Mar 20, 2024

I have read all the comments and my preference is for consistency, in other words a tap on CGM value on main screen takes you to the (Loop or APS) settings screen. There should be easy access on the settings screen to take you to the source app as well.

Regarding G7 - there already is a LoopKit G7SensorKit PR. I just updated my comments to request a change to move the Open Dexcom App higher on the screen. This comment contains a graphic of the proposed modification to the PR.

LoopKit/G7SensorKit#21 (comment)

@avouspierre
Copy link
Contributor Author

What I can implement :

  • default: open the settings screen exception for NS
  • Toggle button in CGM screen : “tap on CGM value open the specific app”. Off by default

@dnzxy
Copy link
Contributor

dnzxy commented Mar 20, 2024

What happens for NS? Still opens NS site?

@avouspierre
Copy link
Contributor Author

for NS, open the website

@dnzxy
Copy link
Contributor

dnzxy commented Mar 20, 2024

Why not make it consistent and navigate here?
image

Maybe add a „GO TO NIGHTSCOUT“ button there.

@avouspierre
Copy link
Contributor Author

In this case, the behavior will be :

  • dexcom ajnd FreeStyle : settings View provided by Loop
  • NS : Nighscout settings with adding link to URL
  • other : CGM settings with the link to the app (glucose direct, ...)

+1 : 👍 or 👎

@dnzxy
Copy link
Contributor

dnzxy commented Mar 20, 2024

Side note: We should probably delete Scrappy‘s / Marc Fournier‘s data collection link too.

Change the config to allow to run OiAPS tests and submodules.
Add a fileStorage test for OiAPS
@dnzxy
Copy link
Contributor

dnzxy commented Mar 24, 2024

@avouspierre since you are working on this, may I suggest another change that goes in the same direction? What do we think about having a real "NO CGM PAIRED" state, where Nightscout isn’t just the general fallback? I always found it an odd UX, that even on a fresh install, it looks as if there is a CGM source in place, i.e. Nightscout, even if the user hasn’t entered the NS credentials.

What do you think?

@avouspierre
Copy link
Contributor Author

@dnzxy I added a none option. So now in a fresh install, no CGM is associated by default. Just to find a logo for the Home Screen like Loop to say « no CGM »..

@dnzxy
Copy link
Contributor

dnzxy commented Mar 24, 2024

@dnzxy I added a none option. So now in a fresh install, no CGM is associated by default. Just to find a logo for the Home Screen like Loop to say « no CGM »..

@avouspierre awesome! There is a super fitting SF Symbol sensor.tag.radiowaves.forward.fill that looks like a great abstract type CGM:
image

- Add submodule TidePoolManager and package required
- Add tests for pluginManager
- Add template for TidePoolManager service
TidePool connexion to the service in Settings menu :
- add menu and views to display the views provided by packages
- add TidePoolManager as a injected service
- add BuildDetails.plist with the clientID required by TidePool to access authentication
- store the information in persistedStore

⚠️ : Do not send any data to the service
- upload glucose
- upload (and delete) carbs
- upload (and delete) dose basal and bolus
- upload event from pump

+ improve the deletion of TidePool.
Add a function to force all uploads in TidePool
Call this function when close the windows "TidePool" config
@bjornoleh
Copy link
Contributor

These changes has already been introduced in alpha by #89 , closing this PR

@bjornoleh bjornoleh closed this May 3, 2024
mountrcg pushed a commit to mountrcg/Trio that referenced this pull request Aug 1, 2024
* Backport LoopKit OmniBLE nightscout#110 and OmniKit nightscout#24 (iAPS #542)

* Backport OmniBLE nightscout#113 and OmniKit nightscout#27 (fixes Loop issue #2117) (iAPS #554)
mountrcg pushed a commit to mountrcg/Trio that referenced this pull request Aug 1, 2024
* Change treatment view calculation handling
* Add onChange handler for carb input
* onChange listener handles input in a debounced fashion; waits for user input to stop before calculation
* Remove Calculate button from treatment view, no longer required

* Address review feedback by @polscm32
* Remove obsolete state variable
* Lower debounce delay from 0.5s to 0.35s
* Gracefully unwrap variable debounce when assigning it to the Dispatch queue
Sjoerd-Bo3 pushed a commit to Sjoerd-Bo3/Trio that referenced this pull request Aug 3, 2024
don't allow treatment button to be pressed twice
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.

None yet

7 participants