Skip to content

Commit f6d3a83

Browse files
authored
Merge pull request #33 from loopandlearn/dexcomoneplus
Patch for dexcom one+
2 parents 669f20f + 22495f7 commit f6d3a83

File tree

1 file changed

+14
-0
lines changed

1 file changed

+14
-0
lines changed
Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
diff --git a/G7SensorKit/G7SensorKit/G7CGMManager/G7Sensor.swift b/G7SensorKit/G7SensorKit/G7CGMManager/G7Sensor.swift
2+
index d5c0b46..b1745a1 100644
3+
--- a/G7SensorKit/G7SensorKit/G7CGMManager/G7Sensor.swift
4+
+++ b/G7SensorKit/G7SensorKit/G7CGMManager/G7Sensor.swift
5+
@@ -215,7 +215,8 @@ public final class G7Sensor: G7BluetoothManagerDelegate {
6+
}
7+
8+
/// The Dexcom G7 advertises a peripheral name of "DXCMxx", and later reports a full name of "Dexcomxx"
9+
- if name.hasPrefix("DXCM") {
10+
+ /// Dexcom One+ peripheral name start with "DX02"
11+
+ if name.hasPrefix("DXCM") || name.hasPrefix("DX02"){
12+
// If we're following this name or if we're scanning, connect
13+
if let sensorName = sensorID, name.suffix(2) == sensorName.suffix(2) {
14+
return .makeActive

0 commit comments

Comments
 (0)