swissalpine / GARMIN-xDrip-Spike-Nightscout-Watchface

15 stars 2 forks source link

Glucose data not showing after some time - all relevant apps are not restricted by data or battery savings #5

Closed 0xBABA closed 10 months ago

0xBABA commented 1 year ago

Hello I am using xDrip+ as data source. I turned off battery restrictions and enabled background data for xDrip, Garmin Connect, Bluetooth (system app) and Bluetooth services (system app). My phone is a pixel (5a) running android 13 (with Feb security update) and the watch is a Venu sq (SW ver 4.6). With all of the above CGM data synchronization keeps dropping several times a day (I see data is live in xDrip when this happens - so the drop occurs somewhere between xDrip to Connect to from Connect to the watch). Your input on this is welcome.

Thanks!

swissalpine commented 1 year ago

I am sorry that you have problems. Also, it's hard to help remotely with any combination of devices and software/firmware versions. First of all, I can say that I never had problems with various smartphones (Sony z3c, Xiaomi Redmi 4, Uniherz Atom and Jelly 2, now Samsung Flip 4) and Garmin devices (most recently Edge 520, Fenix 5s plus, Forerunner 945 LTE) - as long as I had really turned off battery optimization and other battery saving measures (e.g. background eliminations) successfully. But you did that and you know the dontkillmyapp.com website? Also, I have friends who have no problems with Pixel smartphones (Pixel 3a, Pixel 6). Very rarely, maybe once in four weeks, I observe that for some reason the background process on my Garmin watch stops running. Then, however, calling up a widget helps, and everything runs again when I return to the Watchface. But that seems to happen more often with you. Does this workaround help? WIFI is disabled, right? Is there an error message or an error code?

0xBABA commented 1 year ago

Hi and thanks. How do you identify that the background process in the watch stops? Just by seeing there's no sync for aome time? If that is the case, i can't say that flipping up for a widget helps. What do you mean by wifi disabled? Where should i disbale wifi (and why?) There's no error message it just missing data from X minutes ago and bg is striked out.

Thanks.

nyancow commented 8 months ago

@0xBABA did you end up solving this somehow? I am experiencing the same issue with a Venu Sq on a Samsung Galaxy device. Everything was actually working fine up until a couple months ago (which makes me think it must be an update that broke it - OS or Garmin app or watchface). Since then I am able to get some readings, but eventually they stop coming in and the BG is crossed out, for hours/days. I've almost given up on it but recently tried debugging it again. Tried both XDrip and AAPS as sources, played around with the delay time, even tried the constant 5min option, but no combination helps. The local ports for XDrip and AAPS are both working and reporting up to date values. Even if I manually launch the Garmin app on my phone every 30min, the watchface BG value remains crossed out. Disabled every battery optimization feature I could find.

0xBABA commented 8 months ago

For me changing to nightscout as data source improved the situation (still issues but much better than before) . I think it only pulls every 10 minutes with this configuration, but i'd rather get a reading every 10 minutes than spuriously not getting them at all. I never tried AAPS as a source, didn't have it installed back then. Might give it a try...

nyancow commented 8 months ago

AAPS as a source is actually rather new, make sure you're on the latest version of AAPS. XDrip used to work great for me, I doubt it's an issue with the source. Do you see the Garmin Connect service notification constantly? Or does it come and go?

nyancow commented 8 months ago

@swissalpine any way I can debug this to pinpoint the issue? Feel free to get as technical as needed.

swissalpine commented 8 months ago

Have you disabled the optimations of the Bluetooth App (System Apps)?

nyancow commented 8 months ago

I looked into that, saw it mentioned in the readme, but I don't think there's an option to control the system Bluetooth app's battery usage on the latest Samsung Galaxy devices. There are no apps with "Bluetooth" in the name in the apps list, and I couldn't find a "System apps" list either.

swissalpine commented 8 months ago

Shure, it is (on my Samsung Flip 4 with Android 14): Screenshot_20240131_090230_Settings Screenshot_20240131_090245_Settings

nyancow commented 8 months ago

I can't believe I missed that, it's exactly where it always was. 🤦‍♂️ Thank you @swissalpine! I'll try disabling battery optimization for it and see if it has an effect on watch readings.