Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
language: objective-c
osx_image: xcode9
osx_image: xcode9.2

# cache: cocoapods
# podfile: Example/Podfile
Expand All @@ -12,5 +12,5 @@ script:
# Build cocoapods example project
# - set -o pipefail && xcodebuild -workspace Example/xDripG5.xcworkspace -scheme xDripG5-Example -sdk iphonesimulator -destination name="iPhone SE" ONLY_ACTIVE_ARCH=NO | xcpretty
# Build Travis project and run tests
- xcodebuild -project xDripG5.xcodeproj -scheme xDripG5 -sdk iphonesimulator11.0 build -destination name="iPhone SE" test
- xcodebuild -project xDripG5.xcodeproj -scheme xDripG5 -sdk iphonesimulator11.2 build -destination name="iPhone SE" test
# - pod lib lint
26 changes: 26 additions & 0 deletions xDripG5.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,11 @@

/* Begin PBXBuildFile section */
430D64C51CB7846A00FCA750 /* NSData+CRC.swift in Sources */ = {isa = PBXBuildFile; fileRef = 430D64C41CB7846A00FCA750 /* NSData+CRC.swift */; };
431CE7631F8EEF6D00255374 /* CBPeripheral.swift in Sources */ = {isa = PBXBuildFile; fileRef = 431CE7621F8EEF6D00255374 /* CBPeripheral.swift */; };
431CE7671F91D0B300255374 /* PeripheralManager+G5.swift in Sources */ = {isa = PBXBuildFile; fileRef = 431CE7661F91D0B300255374 /* PeripheralManager+G5.swift */; };
4323115F1EFC870300B95E62 /* OSLog.swift in Sources */ = {isa = PBXBuildFile; fileRef = 4323115E1EFC870300B95E62 /* OSLog.swift */; };
43460F88200B30D10030C0E3 /* TransmitterIDTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = 43460F87200B30D10030C0E3 /* TransmitterIDTests.swift */; };
435535D41FB2C1B000CE5A23 /* PeripheralManagerError.swift in Sources */ = {isa = PBXBuildFile; fileRef = 435535D31FB2C1B000CE5A23 /* PeripheralManagerError.swift */; };
43846AC61D8F896C00799272 /* CalibrationDataRxMessage.swift in Sources */ = {isa = PBXBuildFile; fileRef = 43846AC51D8F896C00799272 /* CalibrationDataRxMessage.swift */; };
43846AC81D8F89BE00799272 /* CalibrationDataRxMessageTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = 43846AC71D8F89BE00799272 /* CalibrationDataRxMessageTests.swift */; };
43880F981D9E19FC009061A8 /* TransmitterVersionRxMessage.swift in Sources */ = {isa = PBXBuildFile; fileRef = 43880F971D9E19FC009061A8 /* TransmitterVersionRxMessage.swift */; };
Expand Down Expand Up @@ -45,6 +49,7 @@
43E3978F1D566B170028E321 /* Glucose.swift in Sources */ = {isa = PBXBuildFile; fileRef = 43E3978E1D566B170028E321 /* Glucose.swift */; };
43E397911D5692080028E321 /* GlucoseTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = 43E397901D5692080028E321 /* GlucoseTests.swift */; };
43E397931D56950C0028E321 /* HKUnit.swift in Sources */ = {isa = PBXBuildFile; fileRef = 43E397921D56950C0028E321 /* HKUnit.swift */; };
43E4B1F21F8AF9790038823E /* PeripheralManager.swift in Sources */ = {isa = PBXBuildFile; fileRef = 43E4B1F11F8AF9790038823E /* PeripheralManager.swift */; };
43EEA7111D14DC0800CBBDA0 /* AESCrypt.h in Headers */ = {isa = PBXBuildFile; fileRef = 43EEA70F1D14DC0800CBBDA0 /* AESCrypt.h */; settings = {ATTRIBUTES = (Public, ); }; };
43EEA7121D14DC0800CBBDA0 /* AESCrypt.m in Sources */ = {isa = PBXBuildFile; fileRef = 43EEA7101D14DC0800CBBDA0 /* AESCrypt.m */; };
43F82BCC1D035AA4006F5DD7 /* TransmitterTimeRxMessageTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = 43F82BCB1D035AA4006F5DD7 /* TransmitterTimeRxMessageTests.swift */; };
Expand Down Expand Up @@ -78,7 +83,11 @@

/* Begin PBXFileReference section */
430D64C41CB7846A00FCA750 /* NSData+CRC.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = "NSData+CRC.swift"; sourceTree = "<group>"; };
431CE7621F8EEF6D00255374 /* CBPeripheral.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = CBPeripheral.swift; sourceTree = "<group>"; };
431CE7661F91D0B300255374 /* PeripheralManager+G5.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = "PeripheralManager+G5.swift"; sourceTree = "<group>"; };
4323115E1EFC870300B95E62 /* OSLog.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = OSLog.swift; sourceTree = "<group>"; };
43460F87200B30D10030C0E3 /* TransmitterIDTests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = TransmitterIDTests.swift; sourceTree = "<group>"; };
435535D31FB2C1B000CE5A23 /* PeripheralManagerError.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = PeripheralManagerError.swift; sourceTree = "<group>"; };
43846AC51D8F896C00799272 /* CalibrationDataRxMessage.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = CalibrationDataRxMessage.swift; sourceTree = "<group>"; };
43846AC71D8F89BE00799272 /* CalibrationDataRxMessageTests.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = CalibrationDataRxMessageTests.swift; sourceTree = "<group>"; };
43880F971D9E19FC009061A8 /* TransmitterVersionRxMessage.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = TransmitterVersionRxMessage.swift; sourceTree = "<group>"; };
Expand Down Expand Up @@ -118,6 +127,7 @@
43E3978E1D566B170028E321 /* Glucose.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = Glucose.swift; sourceTree = "<group>"; };
43E397901D5692080028E321 /* GlucoseTests.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = GlucoseTests.swift; sourceTree = "<group>"; };
43E397921D56950C0028E321 /* HKUnit.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = HKUnit.swift; sourceTree = "<group>"; };
43E4B1F11F8AF9790038823E /* PeripheralManager.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = PeripheralManager.swift; sourceTree = "<group>"; };
43EEA70F1D14DC0800CBBDA0 /* AESCrypt.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = AESCrypt.h; sourceTree = "<group>"; };
43EEA7101D14DC0800CBBDA0 /* AESCrypt.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = AESCrypt.m; sourceTree = "<group>"; };
43F82BCB1D035AA4006F5DD7 /* TransmitterTimeRxMessageTests.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = TransmitterTimeRxMessageTests.swift; sourceTree = "<group>"; };
Expand Down Expand Up @@ -173,12 +183,16 @@
43EEA7101D14DC0800CBBDA0 /* AESCrypt.m */,
43CABE0E1C350B2800005705 /* BluetoothManager.swift */,
43CABE0F1C350B2800005705 /* BluetoothServices.swift */,
431CE7621F8EEF6D00255374 /* CBPeripheral.swift */,
43E3978A1D5668BD0028E321 /* CalibrationState.swift */,
43E3978E1D566B170028E321 /* Glucose.swift */,
43E397921D56950C0028E321 /* HKUnit.swift */,
43CABDF81C3506F100005705 /* Info.plist */,
430D64C41CB7846A00FCA750 /* NSData+CRC.swift */,
4323115E1EFC870300B95E62 /* OSLog.swift */,
43E4B1F11F8AF9790038823E /* PeripheralManager.swift */,
435535D31FB2C1B000CE5A23 /* PeripheralManagerError.swift */,
431CE7661F91D0B300255374 /* PeripheralManager+G5.swift */,
43CABE111C350B2800005705 /* Transmitter.swift */,
43CE7CDB1CA77468003CC1B0 /* TransmitterStatus.swift */,
43CABDF61C3506F100005705 /* xDripG5.h */,
Expand All @@ -197,6 +211,7 @@
43DC87BF1C8B509B005BC30D /* NSData.swift */,
43F82BD31D037227006F5DD7 /* SessionStartRxMessageTests.swift */,
43F82BD11D037040006F5DD7 /* SessionStopRxMessageTests.swift */,
43460F87200B30D10030C0E3 /* TransmitterIDTests.swift */,
43F82BCB1D035AA4006F5DD7 /* TransmitterTimeRxMessageTests.swift */,
43880F991D9E1BD7009061A8 /* TransmitterVersionRxMessageTests.swift */,
);
Expand Down Expand Up @@ -347,17 +362,20 @@
files = (
43CE7CCA1CA73B94003CC1B0 /* TransmitterVersionTxMessage.swift in Sources */,
43E3978B1D5668BD0028E321 /* CalibrationState.swift in Sources */,
431CE7631F8EEF6D00255374 /* CBPeripheral.swift in Sources */,
43CABE2D1C350B3D00005705 /* TransmitterTimeRxMessage.swift in Sources */,
43CABE291C350B3D00005705 /* GlucoseRxMessage.swift in Sources */,
43CE7CDC1CA77468003CC1B0 /* TransmitterStatus.swift in Sources */,
43CABE271C350B3D00005705 /* BondRequestTxMessage.swift in Sources */,
4323115F1EFC870300B95E62 /* OSLog.swift in Sources */,
43E4B1F21F8AF9790038823E /* PeripheralManager.swift in Sources */,
43CABE231C350B3D00005705 /* AuthChallengeRxMessage.swift in Sources */,
43CABE261C350B3D00005705 /* AuthStatusRxMessage.swift in Sources */,
43CE7CD41CA73CE8003CC1B0 /* GlucoseHistoryTxMessage.swift in Sources */,
43E397931D56950C0028E321 /* HKUnit.swift in Sources */,
43846AC61D8F896C00799272 /* CalibrationDataRxMessage.swift in Sources */,
43CE7CD01CA73C57003CC1B0 /* SessionStopTxMessage.swift in Sources */,
431CE7671F91D0B300255374 /* PeripheralManager+G5.swift in Sources */,
43CABE2A1C350B3D00005705 /* GlucoseTxMessage.swift in Sources */,
43CE7CC81CA73AEB003CC1B0 /* FirmwareVersionTxMessage.swift in Sources */,
43CE7CCC1CA73BCC003CC1B0 /* BatteryStatusTxMessage.swift in Sources */,
Expand All @@ -376,6 +394,7 @@
43CE7CD21CA73CBC003CC1B0 /* CalibrateGlucoseTxMessage.swift in Sources */,
43F82BD01D035D68006F5DD7 /* SessionStopRxMessage.swift in Sources */,
43F82BCE1D035D5C006F5DD7 /* SessionStartRxMessage.swift in Sources */,
435535D41FB2C1B000CE5A23 /* PeripheralManagerError.swift in Sources */,
43CABE251C350B3D00005705 /* AuthRequestTxMessage.swift in Sources */,
430D64C51CB7846A00FCA750 /* NSData+CRC.swift in Sources */,
);
Expand All @@ -385,6 +404,7 @@
isa = PBXSourcesBuildPhase;
buildActionMask = 2147483647;
files = (
43460F88200B30D10030C0E3 /* TransmitterIDTests.swift in Sources */,
43F82BCC1D035AA4006F5DD7 /* TransmitterTimeRxMessageTests.swift in Sources */,
43F82BD41D037227006F5DD7 /* SessionStartRxMessageTests.swift in Sources */,
43846AC81D8F89BE00799272 /* CalibrationDataRxMessageTests.swift in Sources */,
Expand Down Expand Up @@ -461,6 +481,7 @@
TARGETED_DEVICE_FAMILY = "1,2";
VERSIONING_SYSTEM = "apple-generic";
VERSION_INFO_PREFIX = "";
WATCHOS_DEPLOYMENT_TARGET = 4.0;
};
name = Debug;
};
Expand Down Expand Up @@ -512,6 +533,7 @@
VALIDATE_PRODUCT = YES;
VERSIONING_SYSTEM = "apple-generic";
VERSION_INFO_PREFIX = "";
WATCHOS_DEPLOYMENT_TARGET = 4.0;
};
name = Release;
};
Expand All @@ -530,7 +552,9 @@
PRODUCT_BUNDLE_IDENTIFIER = com.loudnate.xDripG5;
PRODUCT_NAME = "$(TARGET_NAME)";
SKIP_INSTALL = YES;
SUPPORTED_PLATFORMS = "iphonesimulator iphoneos watchos watchsimulator";
SWIFT_OPTIMIZATION_LEVEL = "-Onone";
TARGETED_DEVICE_FAMILY = "1,2,4";
};
name = Debug;
};
Expand All @@ -549,6 +573,8 @@
PRODUCT_BUNDLE_IDENTIFIER = com.loudnate.xDripG5;
PRODUCT_NAME = "$(TARGET_NAME)";
SKIP_INSTALL = YES;
SUPPORTED_PLATFORMS = "iphonesimulator iphoneos watchos watchsimulator";
TARGETED_DEVICE_FAMILY = "1,2,4";
};
name = Release;
};
Expand Down
2 changes: 1 addition & 1 deletion xDripG5.xcodeproj/xcshareddata/xcschemes/xDripG5.xcscheme
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<Scheme
LastUpgradeVersion = "0900"
LastUpgradeVersion = "0920"
version = "1.3">
<BuildAction
parallelizeBuildables = "YES"
Expand Down
2 changes: 1 addition & 1 deletion xDripG5/AESCrypt.m
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ @implementation AESCrypt

+ (NSData *)encryptData:(NSData *)data usingKey:(NSData *)key error:(NSError * _Nullable __autoreleasing *)error
{
NSMutableData *dataOut = [[NSMutableData alloc] initWithCapacity:16];
NSMutableData *dataOut = [[NSMutableData alloc] initWithLength:data.length + kCCBlockSizeAES128];

CCCryptorStatus status = CCCrypt(kCCEncrypt,
kCCAlgorithmAES,
Expand Down
Loading