-
Notifications
You must be signed in to change notification settings - Fork 622
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
Trio Release 0.2.0 #2
Conversation
Merge pull request #2 from nightscout/alpha
Docs, FAX, Oref0
both single and double line versions worked in zsh, but only the single line version worked in bash
When users enter a trailing / in their Nightscout URL (Eg: "https://url/" rather than "https://url"), this will immediately result in a "Not found!" (404) error, because a / is already being appended. (Resulting in "https://url//"). This check removes the trailing slash to prevent 404's.
build_trio.yml: use actions/upload-artifact@v4
Update README.md: Create ConfigOverride.xcconfig by command line
minor updates about code.
Treatments: Carbs and Temp Targets - and also announcements
To make the Issues clearer to read
“Add pump” button when pump has not been configured
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It’s time! Months of testing and iterating in vivo and in vitro from dozens of contributors and testers. Good work team!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks VERY good to me!
Team, what a combined effort! Already looking forward to 1.0, that holds all our really good stuff!!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Let's do this!
Confirmed to build with Xcode.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Let’s push the boundaries of what's possible together. For diabetics and DIY. #WeAreNotWaiting
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
😃
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Excellent work everyone! :)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Approved :)
Sync with Upstream
Trio 0.2.0
expand details
This app splits from Artificial-Pancreas/iAPS at v2.3.3 on the main branch and this commit. Very minimal UI changes were made in this initial update, but while it may look and for the most part seem the same as iAPS v2.3.3, you can see from the number of commits and files/lines of code changed in this PR that there are extensive changes under the hood. These changes were done to ensure it is truly open source, peer-reviewed and tested, to keep it in sync with updates from Loop's submodules (the stuff that connects your pump, CGM, and services), to fix some bugs, and to add a few new features.
The Team
expand details
Trio is a collaborative project set up by members of the DIY community who welcome a peer reviewed, Open Source iOS implementation of the Oref/APS algorithm.
The team consists of:
The Name
expand details
“Trio” is inspired by several joint efforts:
Hosted by The Nightscout Foundation
expand details
The most obvious change from iAPS, other than the name, is that the repository location has changed to be housed by The Nightscout Foundation, alongside Nightscout and AndroidAPS. The Nightscout Foundation has a long track record of facilitating innovation in DIY diabetes technology and stoking collaboration between many developers and projects. This will keep Trio in the hands of the community rather than a single individual, and ensure all development is peer-reviewed and tested before being released.
New Bundle ID
expand details
If you're switching to Trio from iAPS, another big change is the app's Bundle ID, which is now
org.nightscout.TEAMID.trio
. This means Trio will not overwrite the iAPS app on your iPhone, but all settings must be re-entered and all devices re-connected. Trio will need about 24 hours of data before the dynamic features can be enabled.If you're using Omnipod DASH or Eros, you will have to pair a new pod to start using Trio, but all other devices can transfer mid-session.
New App Group
expand details
Instead of using the Loop's App Group,
group.com.TEAMID.loopkit.LoopGroup
, Trio uses its own -group.org.nightscout.TEAMID.trio.trio-app-group
. This prevents settings from being retained when deleting and reinstalling Trio while Loop or iAPS is also installed. You still need to delete xDrip4iOS to completely reset settings, though.New Icons
expand details
New icons have been created as a symbol of the name Trio. (by @tmhastings, plus some old ones by @tqb43)
Default Setting Changes
expand details
None
(instead ofNightscout
)On
(instead ofOff
)180
(instead of145
)Off
(instead ofOn
)60
(instead of65
, which keeps it more in line with Oref0)0.8
(instead of0.5
)Sigmoid Adjustment Factor
expand details
With Dynamic ISF toggled on, the effects of
Adjustment Factor
vary drastically between havingSigmoid
turnedon
andoff
. Because of this, we've split theAdjustment Factor
in two and given Sigmoid its own setting. This allowsAdjustment Factor
to be defaulted to0.8
withSigmoid
turnedoff
and to0.5
withSigmoid
turnedon
. (by @MikePlante1)External Insulin & Glucose
expand details
External insulin entry (to log non-pump insulin, eg. from an insulin pen) has been moved to the History screen rather than the Bolus screen. External insulin entries will display a warning if amount is larger than Max Bolus setting and will not be allowed if over three times the Max Bolus setting. The History screen also now displays if a bolus was an SMB or External, and uses swipe gestures to delete entries. (by @BrianWieder with many cherry picks from @dnzxy)
Distinguish Manual Glucose Readings
expand details
Manually entered glucose readings are now more noticeable in both the history and the main chart. (by @mountrcg)
Edit Profile Overrides & Temp Targets
expand details
Swiping left on a saved profile override or temp target now gives you the option to edit or delete. Selecting to edit will open a new page where you can change the name and/or any of the settings. (by @dsnallfot)
LoopKit Submodules (pumps/cgms/services)
expand details
The code that's used to connect to pumps, CGMs, and other things was taken from their implementations in Loop. This release changes where that code is housed from within this app to point to the code in @LoopKit or @loopandlearn's repositories. This allows for a better development as it makes it easy to see the differences between the code used in Trio vs the code being used in LoopKit and allows updates in the LoopKit repo to easily be pulled into Trio and vice versa as submodules are improved in Trio and shared to LoopKit. (by @bjornoleh with help from @marionbarker and @bjornoleh)
Updates to submodules versus what was used in iAPS v2.3.3 (by @itsmojo with help from @marionbarker and others):
Critical Pod Fault 049 (0x31)
error which caused a pod loss.Oref
expand details
This part is rather technical. Oref (the algorithm from OpenAPS that drives Trio) is written in the JavaScript programming language. In order to perform well in an iOS app, the algorithm is implemented in a minimized format. Until the algorithm is rewritten into the Swift programming language, it needs to be like this to ensure performance. The source code used to build the minimized files is now included in this repo as well as a separate repo trio-oref. This work is quite extensive and has been done and peer-reviewed by several contributors: (beautified/reconstructed by @JeremyStorring and updated by @bjornoleh, @mountrcg, @avouspierre, @MikePlante1, @tmhastings)
Schedule SMBs Off in Profile Overrides
expand details
The
Schedule when SMBs are Off
option in profile overrides has been improved to make it easier to understand and use. Now, if you want to disable SMBs for the entire time the override is active, toggle onAlways Disable SMBs
, but if you want to specify a timeframe for SMBs to be disabled, you can toggle offAlways Disable SMBs
toggle onSchedule when SMBs are Off
and set the timeframe. Note that setting a timeframe of 22-6 would disable SMBs from 22:00 (10PM) through 5:59 as long as the override is active during that time.Restart Bug Squashed
expand details
Since the beginning of FAX, there was a bug where restarting a phone could potentially cause a loss of pump or cgm connection. This was especially detrimental for Omnipod users, as there's no way to reconnect it after it's lost. The fix for this from LoopKit has now been added to Trio. (by @dnzxy, @kskandis, @avouspierre)
Apple Health Fix
expand details
The 2.3.3 version of iAPS had a bug with Apple Health that would crash the app any time a loop cycle was run. This part of the code was re-written and fixed (by @AndreasStokholm), then thoroughly tested and peer-reviewed by the team. Unfortunately there are still problems with Apple Health, as it still creates an excessive amount of entries that significantly increases storage size and can cause AH to lag.
Fix Multiple Meal Entry Bug
expand details
Some people have had the app freeze while entering a meal and mistakenly entered the same meal multiple times without realizing it. The
Save and continue
is now disabled as soon as it’s pressed to prevent that from happening. (by @MikePlante1)Fix mmol/L Glucose Target Bug
expand details
The bug causing glucose target to not be settable to certain mmol/L values has been fixed. (cherry-picked from @Jon-b-m by @Sjoerd-Bo3)
Tidepool Integration
expand details
Tidepool can now be uploaded to directly from Trio instead of using Apple Health and the Tidepool app on your iPhone. Note that if both are enabled, you will see duplicate entries in Tidepool, and even after turning one off, you could still see up to a week of duplicate data. (by @avouspierre)
Dexcom Share Integration
expand details
Dexcom Share has been fixed so it can now be used as a CGM source. Also, if you use Dexcom G6 as your CGM and you enter your Dexcom Share credentials at the bottom in
⚙️ > CGM > CGM Configuration
, missed readings should backfill in Trio from Dexcom Share. Keep in mind, though, when you change G6 transmitters Trio will continue to pull readings from Dexcom Share causing you to rely on internet for readings until you update your G6 Transmitter ID in Trio. (by @avouspierre)Meal Settings
expand details
There is a new section in settings called
Meal Settings
. In it, you'll findMax Carbs
(which used to be inPump Settings
),Max Fat
,Max Protein
, and theFat and Protein Conversion Settings
that used to be found in it's own section. (by @bjornoleh)Max Macros
expand details
Max Fat
&Max Protein
Max Carbs
' defaultCarbohydrate limit
changed toLimit Per Entry
for Meal Settingsgrams
tog
for the meal entry screeng
to⚠️
PR.226.mov
Max Bolus
expand details
Manually entering a bolus larger than the
Max Bolus
setting used to just deliver the max bolus amount, but now this setting prevents the bolus from being delivered until the amount is less than or equal to the max setting. (cherry-picked from @Jon-b-m and modified by @MikePlante1 with input from @bjornoleh)Also now displays the value read from the pump instead of from settings to ensure the correct value is shown. Important for Medtronic pumps and in the future for Dana pumps. (by @bastiaanv and ported by @dnzxy)
Live Activities (Dynamic Island & Lockscreen Widget
expand details
Live Activities have been added to show relevant data without opening Trio. This displays glucose, delta, and trend on the lock screen (iOS 16.2+) as well as in the Dynamic Island (iPhone 14+). Optionally, a glucose graph and current IOB & COB can also be displayed. Consistently updated every 5 minutes with every loop cycle. (cherry-picked from @nas10, @polscm32 and ported by @MikePlante1)
Turn Live Activity on and switch between display options by going to ⚙️ >
Notifications
(long press)
Dexcom ONE+
expand details
Added support for Dexcom ONE+ (taken from this Zulip discussion)
Nightscout Menu Updated
expand details
The menu for Nightscout has been updated to include sub-menus. The new
Fetch Treatments
toggle controls whether Trio will fetch carbs and temp targets from Nightscout. The duplicateRemote Control
toggle has also been removed fromPreferences
. (by @dsnallfot)Import Settings From Nightscout
expand details
Fixed this so it now also works for mg/dL. Also now allows importing from settings saved to Nightscout from Loop and will use the center of your correction range from Loop for the target range in Trio. (by @kskandis and @MikePlante1)
Settings imported:
Improve Nightscout Uploads
expand details
Previously, only enacted loop cycles were uploaded to Nightscout, which caused information gaps from loop cycles that were just suggested but not actually enacted for one reason or another. Now suggested loop cycles will also be uploaded as well. (by @bjornoleh and suggested by @scottleibrand)
Fat & Protein Upload to Nightscout
expand details
Fat & Protein are now uploaded to Nightscout when you announce them in Trio. (by @aug0211)
FPU Conversion
expand details
Oref ignores any carb entry less than 1.0g. This used to happen when
Interval In Minutes
was set low and/or the amount of fat and protein was small. Now, the carb entries that were converted from fat & protein are saved to ensure they are always at least 1g each and not ignored by oref. (by @dnzxy)For example, with the default
Meal Settings
, 10g of protein and 5g of fat used to converted into 7 entries of 0.7g carbs. Now, it will be converted into 5 entries of 1g carbs.Statistics Range
expand details
The statistics screen now includes the
high
andlow
values in the normal range instead of the high and low ranges. This matches the colors of the glucose dots that were already being used on the Statistics screen. (by @MikePlante1)For this example in a simulator, I kept
high
/low
to the default70
/180
and manually entered these values:Pump Status Icons
expand details
New icons are displayed when your pod status has a warning or critical message. This will help highlight when a problem occurs with the pump to help make the user aware of the issue. (by @avouspierre)
Display icons/buttons when no pump/CGM is selected
expand details
When there is no pump or CGM selected, a button is displayed that will take you to the selection screen for pump or CGM. This does not affect instances where a pump or CGM *is* selected and just not paired. (by @avouspierre)
When Omnipod is removed as a pump source, it will now display
Add pump
rather than the erroneousNo pod
warning. (by @kskandis)Confirm Bolus Faster on Apple Watch
expand details
An option has been added in ⚙️ >
Watch
to require less of a turn of the Apple Watch crown to confirm a bolus. (by @MikePlante1, who likes to confirm boluses with his nose)Screen.Recording.2024-06-18.at.2.05.20.PM.mov
Hide Keyboard and Delete All Buttons added
expand details
There are now buttons on the keyboard to delete all text and to hide the keyboard. (by @polscm32)
mmol/L <-> mg/dL Rounding Improved
expand details
A bug was fixed where entering certain mmol/L manual entries were saved incorrectly due to rounding, such as 7.1 -> 7.0.
Eventual Glucose Rounding for mmol/L
expand details
Eventual Glucose now rounds to 1 decimal place for mmol/L users instead of 2 on the main screen as well as the watch app.
Tests Enabled
expand details
Added ability to run tests on Trio and submodules. (by @avouspierre)
Browser Build Updates
expand details
Browser Build updated to new Apple/GitHub standards. (by @bjornoleh) TestFlight Expiration is now displayed in Settings. (by @bjorkert) Gemfile updated. (by @mountrcg)
Disabled Saving Autotune to Pump
expand details
Removed the button for this functionality until it can be fixed, since 0 U/hr basal rates were causing issues with this feature. Don't worry, this feature will return.
Removed Stats Upload
expand details
Removed the option to upload Statistics to Nightscout, since it is no longer compatible with the website this feature was added for before. (by @MikePlante1)
List of individual PRs included in this large PR:
expand details
actualDate
as introduced in #22 #55Max Bolus exceeded
label #172storeCarbs
function to limit carb equivalents of FPU conversion to 1.0 grams #240Minimum Safety Threshold
update #260alpha
intodev
#333Go Team!🎉
expand details
Thank you to the following developers who have added commits to this PR and the initial version of Trio: @AndreasStokholm, @avouspierre, @bjorkert, @bjornoleh, @BrianWieder, @dnzxy, @dsnallfot, @JeremyStorring, @kskandis, @kylmcw, @lifeguardz, @marionbarker, @MikePlante1, @mountrcg, @polscm32, @Sjoerd-Bo3, @tmhastings
A heartfelt thank you to everyone who has played a crucial role behind the scenes with their valuable contributions in discussions, project management, coaching, documentation, testing, and more: