creepymonster / GlucoseDirect

App programmed in Swift/SwiftUI for using Libre blood glucose sensors.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Ascertain age > 0 before setting state to .starting

gui-dos opened this issue · comments

[EDITED]

Hello gui-dos,

thank you for your message - I'm always happy to hear from you.

I suspect the problem is more difficult to solve. Right now I can't get the age of the sensor from the NFC scan of the Libre 3. I don't get the real age of the sensor until I retrieve the data from LibreLinkUp.

Therefore, I set the age of the sensor to 0 during the NFC scan, which means that the sensor is set to "Starting" until the first data retrieval. I do this because I only allow connections to the sensor when the status is "Starting" or "Ready".

If I would not do this, the sensor might not be connected otherwise, and then the real age of LibreLinkUp could not be retrieved.

It would be better to determine the age from the NFC scan. Maybe you have a tip.

Many greetings
Reimar

Thanks for the explanation, that "starting" message from an already started sensor always puzzled me. 😋