JohanDegraeve / xdripswift

xdrip for iOS, written in Swift
GNU General Public License v3.0
327 stars 320 forks source link

5min share to Loop #427

Closed Menno86 closed 1 year ago

Menno86 commented 1 year ago

The new function "Share to Loop every 5 min" is intended to prevent Loop3 update every minute. This causes users with a Medtronic pump and Orange Link (or similar) excessive battery drainage.

Activating the new function doesn't prevent Loop from updating every (1) minute (as can be seen since the automatic bolus function works ever (1) minute). The function does limit the amount of readings sent to Loop to every 5 minutes, so the function itself seems to be working fine. However the desired goal is nog accomplished.

Is a fix needed for this from the xDrip4IOS community, or is an adjustment of Loop necessary?

[Version 4.11.1, Build 4184]

JohanDegraeve commented 1 year ago

that's probably because the Libre 2 is waking up Loop every 1 minute. Either because Loop is directly connected to Libre 2 or because you use xDrip4iOS client with "use CGM as heartbeat" switched on.

In the second case, you may try to switch that off. I think Orange link will wake up Loop every 5 minutes, so no need for the heartbeat mechanism

Menno86 commented 1 year ago

Thanks. I’m using (only) Xdrip to connect to Loop. Indeed i had turned Heartbeat on, I turned it off. It does seem to have some do fewer updates.

But as you can see in the screenshot it did still do every minute update this night. My phone was on the charger, screen locked and since i was sleeping the phone was not used.

Can I provide any other info? 929C91B6-346B-48D5-9727-66D3CEFD7E81

Menno86 commented 1 year ago

Update. Tested this night with only temp basal, but still the ‘5min update’ fun function does not do it’s magic. B443757D-04A7-4A85-B06A-192AF122DE45

paulplant commented 1 year ago

The option in xDrip4iOS does what it says. It just limits data share to once every 5 minutes. And as far as we know, this is working correctly.

What Loop does after this is unfortunately out of the scope of xDrip4iOS and is something you'd need to discuss in Zulip with Pete.

Of course, I'm assuming here that the xDrip client isn't causing this to happen (which I don't think it will if heartbeat is disabled).

Could you maybe try changing CGM source to Nightscout and see if Loop still triggers too often?

Menno86 commented 1 year ago

Tnx Paul for the follow up. I changed the source to Nightscout. Strangely the behavior of Loop is the same. That confirms your suspicion that xDrip is not the cause, but Loop is (updated yesterday to 3.2, but no improvement).

I’ll move this topic to Loop and will close this one.

89D27414-F9D6-4138-986F-250A0EE95BF0

paulplant commented 1 year ago

Thanks for the feedback @Menno86 !