-
Notifications
You must be signed in to change notification settings - Fork 1.9k
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
Insulin Management within Profile #3853
base: dev
Are you sure you want to change the base?
Conversation
Note, this PR will replace draft PR #3782
|
I will try to help test this PR by adding it to my test rig. Virtual pump though but still useful? |
I have setup AAPS test-rig with Ultra-Rapid Oref. If I change DIA on AAPSClient and save, the following happen: |
Did you install this PR on both sides (master loop and AAPSClient)?
This PR is only a first step, (working locally), but I didn't test NSClient synchro.
|
A new item has been added in my todo list, Check AAPS <=> Syncho (insulin sync and profile sync, with same or different versions...). |
I built AAPSClient with same branch👍 Since AAPSClient can't select which insulintype in config builder, it could be that it reverts to some default value when changing DIA and saving, but it's sending both DIA and INS type to AAPS, since AAPS is updated. So there is probably some choice we need to make here. Do we want AAPSClient to be able to change INS also? I don't see a problem with that, but it would make sense if it was part of the actual profile dialog then perhaps instead of config builder, but that was next step right? |
Good question, to be discussed...
The other modification can be update of an existing insulin (without changing insulin within pump).
Finally, a ProfileSwitches managed within AAPS UI (Overview, Activity, Automation, SMS...) should only be available between profiles sharing the same insulin.
That's why I included within future InsulinPlugin a tab to list and show the profiles using selected insulin 😉. Again these are my thoughts, but of course opened to discuss on UI, features... |
|
@olorinmaia I now included the proposed InsulinPlugin (unique) to manage all type of insulin. |
@Philoul I've tested your latest commits, and it seem to be working fine, with some minor issues with deleting / saving insulin profiles. I really like this approach that you can have multiple insulin profiles and can change this in your profile. We however use only Fiasp, but I understand the need for it. It simplify UX abit also, by being able to set all this in profile. I'm wondering though, if we should hide the possibility to change Insulin Profile in AAPSClient, and only show What InsType, Peak, DIA is set for each profile when activated. If this is to be changed, it should be done on AAPS. Today in AAPSClient you can change DIA, but not insulintype or peak. One could say we take something from AAPSClient, but we also give more information as you now can see ins type, dia and peak when you open profile. Problem is that changes to Insulin profiles seem to sync very slow with AAPSClient, which could lead to issues. It seem to sync whenever AAPS is restarted. If that could be improved I see less issues with Insulin Profiles being available to change on AAPSClient. You can try to add a few new Insulin Profiles on AAPS and delete a few, and then activate profile. And notice that on AAPSClient, you won't see it, until you restart AAPS and wait some. |
This PR is a first step to replace dia management within profile (deprecated in profile interface) by a global insulin management within profile:
Within this first step when a profileswitch is done, it will use Insulin Recorded within profile (dia and peak), so it will no more use current InsulinPlugin peak value.
A clone Profile will also clone insulin included into source profile (this will be improved on next step)
A new profile will use CurrentInsulin (concerning peak)
UI concerning dia value is still within ProfilePlugin (will be moved to InsulinPlugin in next step).
Next steps I have in mind: