Skip to content

RossKNI/AndroidAPS-2

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

AndroidAPS

Support Server

Build status Crowdin Documentation Status codecov dev: codecov

BTC 3KawK8aQe48478s6fxJ8Ms6VTWkwjgr9f2

To access Dynamic ISF, please use the Dynamic ISF branch. This has the following changes from standard AAPS Master:

Dynamic ISF

Dynamic ISF uses Chris WIlson's model to determine ISF instead of a static profile settings. This is applied only in the openAPSSMB plugin. The openAPSAMA plugin continues to use profile settings for ISF.

The equation implemented is: ISF = 277700 / BG * TDD

The implementation here splits the use into two. One to calculate current ISF for use with predictions, the other to calculate future ISF for use with dosing.

Current ISF

This uses a combination of the 7 day average TDD and a linear extrapolation of the pumps current total insulin delivered to calculate a TDD for today.

The total daily dose used in the above equation is generally weighted 40% to the 7 day average and 60% to the extrapolation from the pump data. There are some special cases where this isn't applied. These are:

  • When the time is earlier than 5am and the pump TDD is greater than 7 day TDD
  • When the time is earlier than 7am and the pump TDD is less than 80% of 7 day TDD

In both these cases, a value of 80% of TDD is used in the caluclation.

When the pump TDD is less than 33% of 7 day TDD

In this case, the weighting is changed to be 75% pump TDD, 25% 7 day average TDD.

The dynamic ISF value is still adjusted when setting an activity or eating soon temp target, as per the standard oref model.

Future ISF

Future ISF uses the same TDD value as generated above. It then uses different glucose values dependent on the case:

If delta is +ve or zero, or delta is negative but predicted glucose is above target, the future ISF value used for determining insulin required is the same as the current ISF.

If delta is -ve, and the predicted glucose level is below target, then the future ISF value is used, as this is a less aggressive value.

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Kotlin 72.4%
  • Java 26.5%
  • JavaScript 1.1%