Skip to content

Merge pull request #896 from bastiaanv/feat/dev-medtrum#25

Merged
Sjoerd-Bo3 merged 20 commits intobuild-medtrumfrom
feat/dev-medtrum
Jan 18, 2026
Merged

Merge pull request #896 from bastiaanv/feat/dev-medtrum#25
Sjoerd-Bo3 merged 20 commits intobuild-medtrumfrom
feat/dev-medtrum

Conversation

@Sjoerd-Bo3
Copy link
Copy Markdown
Owner

No description provided.

Copilot AI review requested due to automatic review settings December 25, 2025 17:11
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR integrates MedtrumKit to add support for Medtrum Nano insulin pumps (200u/300u variants) to the Trio application. The changes enable users to select, configure, and monitor Medtrum pumps alongside existing pump options.

Key changes:

  • Added MedtrumKit as a git submodule and integrated it into the Xcode project
  • Extended pump selection UI and onboarding flows to include Medtrum Nano option
  • Implemented patch timer display logic to show either expiration countdown or activation time based on pump configuration

Reviewed changes

Copilot reviewed 18 out of 19 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
scripts/swiftformat.sh Added MedtrumKit to the list of modules for Swift formatting
Trio/Sources/Modules/PumpConfig/View/PumpSetupView.swift Added import and setup configuration for MedtrumPumpManager
Trio/Sources/Modules/PumpConfig/View/PumpConfigRootView.swift Added Medtrum Nano to pump selection UI with image scaling improvements
Trio/Sources/Modules/PumpConfig/PumpConfigDataFlow.swift Added medtrum case to PumpType enum
Trio/Sources/Modules/Onboarding/View/OnboardingView+Util.swift Added medtrum option to onboarding pump selection
Trio/Sources/Modules/Onboarding/View/OnboardingSteps/AlgorithmSettings/AlgorithmSettingsSubstepView.swift Grouped medtrum with Omnipod pumps for autosens behavior
Trio/Sources/Modules/Onboarding/View/OnboardingRootView.swift Updated navigation logic to handle medtrum pump type
Trio/Sources/Modules/Onboarding/OnboardingStateModel.swift Added MedtrumKit import and pump manager detection logic
Trio/Sources/Modules/Home/View/HomeRootView.swift Added Medtrum Nano button and activatedAtDate parameter
Trio/Sources/Modules/Home/View/Header/PumpView.swift Refactored timer display to support both expiration and activation timers
Trio/Sources/Modules/Home/HomeStateModel.swift Added state property and publisher subscription for pumpActivatedAtDate
Trio/Sources/Localizations/Main/Localizable.xcstrings Added localization entries for Medtrum Nano display strings
Trio/Sources/APS/DeviceDataManager.swift Integrated MedtrumPumpManager and added logic to handle patch timer modes
Trio/Sources/APS/APSManager.swift Exposed pumpActivatedAtDate publisher through APSManager protocol
Trio.xcodeproj/project.pbxproj Added MedtrumKit.framework to build configuration
MedtrumKit Added as git submodule pointing to loopandlearn repository
DanaKit Updated submodule commit reference
.gitmodules Added MedtrumKit submodule configuration
Files not reviewed (1)
  • Trio.xcworkspace/contents.xcworkspacedata: Language not supported

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

let battery: [OpenAPS_Battery]
@Environment(\.colorScheme) var colorScheme

let NORMAL_PATCH_AGE = TimeInterval.hours(80)
Copy link

Copilot AI Dec 25, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Constant name should follow Swift naming conventions and be lowercase (e.g., 'normalPatchAge').

Suggested change
let NORMAL_PATCH_AGE = TimeInterval.hours(80)
let normalPatchAge = TimeInterval.hours(80)

Copilot uses AI. Check for mistakes.
@Sjoerd-Bo3
Copy link
Copy Markdown
Owner Author

@copilot can you merge this?

Copy link
Copy Markdown

Copilot AI commented Dec 25, 2025

@Sjoerd-Bo3 I've opened a new pull request, #26, to work on those changes. Once the pull request is ready, I'll request review from you.

@Sjoerd-Bo3 Sjoerd-Bo3 merged commit bf7bae1 into build-medtrum Jan 18, 2026
5 of 6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants