Skip to content

Commit

Permalink
Merge branch 'wristband_floble_mini_ti'
Browse files Browse the repository at this point in the history
This is the working app for Wristband FMV commit f9c6da3315878fbe00 in flomio_hardware_floble repo
  • Loading branch information
grundyoso committed Nov 27, 2016
2 parents 84634c4 + ab56e31 commit 0ce6f46
Show file tree
Hide file tree
Showing 12 changed files with 197 additions and 320 deletions.
12 changes: 11 additions & 1 deletion FloBLE-Mini/FloJack.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -448,7 +448,8 @@
15C4B2C315C832DF009DE0E5 /* Project object */ = {
isa = PBXProject;
attributes = {
LastUpgradeCheck = 0610;
LastTestingUpgradeCheck = 0730;
LastUpgradeCheck = 0730;
ORGANIZATIONNAME = "John Bullard";
TargetAttributes = {
1559F28D16517FF100B43633 = {
Expand Down Expand Up @@ -605,6 +606,7 @@
CLANG_WARN_EMPTY_BODY = YES;
CODE_SIGN_IDENTITY = "iPhone Developer";
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
DEVELOPMENT_TEAM = Q338UYGFZ8;
FRAMEWORK_SEARCH_PATHS = (
"$(inherited)",
"\"$(SYSTEM_APPS_DIR)/Xcode.app/Contents/Developer/Library/Frameworks\"",
Expand All @@ -613,6 +615,7 @@
GCC_PREFIX_HEADER = "FloJackExample/FloJackExample-Prefix.pch";
INFOPLIST_FILE = "FloJackExample/FloJackExample-Info.plist";
IPHONEOS_DEPLOYMENT_TARGET = 8.1;
PRODUCT_BUNDLE_IDENTIFIER = "com.flomio.${PRODUCT_NAME:rfc1034identifier}";
PRODUCT_NAME = "$(TARGET_NAME)";
PROVISIONING_PROFILE = "";
"PROVISIONING_PROFILE[sdk=iphoneos*]" = "";
Expand All @@ -627,6 +630,7 @@
CLANG_WARN_EMPTY_BODY = YES;
CODE_SIGN_IDENTITY = "iPhone Developer";
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
DEVELOPMENT_TEAM = Q338UYGFZ8;
FRAMEWORK_SEARCH_PATHS = (
"$(inherited)",
"\"$(SYSTEM_APPS_DIR)/Xcode.app/Contents/Developer/Library/Frameworks\"",
Expand All @@ -636,6 +640,7 @@
INFOPLIST_FILE = "FloJackExample/FloJackExample-Info.plist";
IPHONEOS_DEPLOYMENT_TARGET = 8.1;
OTHER_CFLAGS = "-DNS_BLOCK_ASSERTIONS=1";
PRODUCT_BUNDLE_IDENTIFIER = "com.flomio.${PRODUCT_NAME:rfc1034identifier}";
PRODUCT_NAME = "$(TARGET_NAME)";
PROVISIONING_PROFILE = "";
"PROVISIONING_PROFILE[sdk=iphoneos*]" = "";
Expand All @@ -658,9 +663,11 @@
CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
COPY_PHASE_STRIP = NO;
ENABLE_STRICT_OBJC_MSGSEND = YES;
ENABLE_TESTABILITY = YES;
GCC_C_LANGUAGE_STANDARD = gnu99;
GCC_DYNAMIC_NO_PIC = NO;
GCC_INPUT_FILETYPE = sourcecode.cpp.objcpp;
GCC_NO_COMMON_BLOCKS = YES;
GCC_OPTIMIZATION_LEVEL = 0;
GCC_PREPROCESSOR_DEFINITIONS = (
"DEBUG=1",
Expand Down Expand Up @@ -705,6 +712,7 @@
ENABLE_STRICT_OBJC_MSGSEND = YES;
GCC_C_LANGUAGE_STANDARD = gnu99;
GCC_INPUT_FILETYPE = sourcecode.cpp.objcpp;
GCC_NO_COMMON_BLOCKS = YES;
GCC_THUMB_SUPPORT = NO;
GCC_VERSION = com.apple.compilers.llvm.clang.1_0;
GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
Expand Down Expand Up @@ -802,6 +810,7 @@
GCC_PRECOMPILE_PREFIX_HEADER = YES;
GCC_PREFIX_HEADER = "FloJack/FloJack-Prefix.pch";
INFOPLIST_FILE = "FloJackTests/FloJackTests-Info.plist";
PRODUCT_BUNDLE_IDENTIFIER = "Flomio.${PRODUCT_NAME:rfc1034identifier}";
PRODUCT_NAME = "$(TARGET_NAME)";
WRAPPER_EXTENSION = octest;
};
Expand All @@ -822,6 +831,7 @@
GCC_PRECOMPILE_PREFIX_HEADER = YES;
GCC_PREFIX_HEADER = "FloJack/FloJack-Prefix.pch";
INFOPLIST_FILE = "FloJackTests/FloJackTests-Info.plist";
PRODUCT_BUNDLE_IDENTIFIER = "Flomio.${PRODUCT_NAME:rfc1034identifier}";
PRODUCT_NAME = "$(TARGET_NAME)";
WRAPPER_EXTENSION = octest;
};
Expand Down
4 changes: 4 additions & 0 deletions FloBLE-Mini/FloJackExample/AppDelegate.m
Original file line number Diff line number Diff line change
Expand Up @@ -230,6 +230,10 @@ - (void)floReaderManager:(FLOReaderManager *)theFloReaderManager didReceiveSniff

}

- (void)floReaderManager:(FLOReaderManager *)theFloReaderManager didReceiveWristbandState:(NSString*)theState; {
[self.tagReadWriteViewController floReaderManager:theFloReaderManager didReceiveWristbandState:theState];
}

#pragma mark - OadScreenViewController delegate

- (void)updateButtonPress
Expand Down
2 changes: 1 addition & 1 deletion FloBLE-Mini/FloJackExample/FloJackExample-Info.plist
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@
</dict>
</dict>
<key>CFBundleIdentifier</key>
<string>com.flomio.${PRODUCT_NAME:rfc1034identifier}</string>
<string>$(PRODUCT_BUNDLE_IDENTIFIER)</string>
<key>CFBundleInfoDictionaryVersion</key>
<string>6.0</string>
<key>CFBundleName</key>
Expand Down
5 changes: 5 additions & 0 deletions FloBLE-Mini/FloJackExample/TagReadWriteViewController.mm
Original file line number Diff line number Diff line change
Expand Up @@ -448,6 +448,11 @@ - (void)floReaderManager:(FLOReaderManager *)floReaderManager didReceiveSnifferC
[self updateLogTextViewWithString:textUpdate];
}

- (void)floReaderManager:(FLOReaderManager *)floReaderManager didReceiveWristbandState:(NSString *)theState; {
NSString *textUpdate = [NSString stringWithFormat:@":::FloBLE Wristband State %@", theState];
[self updateLogTextViewWithString:textUpdate];
}

- (bool)textFieldShouldReturn:(UITextField *)textField {
if ([textField isEqual:_urlInputField]) {
[_appDelegate.floReaderManager setModeWriteTagWithNdefMessage:[NDEFMessage createURIWithString:_urlInputField.text]];
Expand Down
6 changes: 3 additions & 3 deletions FloBLE-Mini/FloJackTests/FloJackTests-Info.plist
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,14 @@
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key></key>
<string></string>
<key>CFBundleDevelopmentRegion</key>
<string>en</string>
<key>CFBundleExecutable</key>
<string>${EXECUTABLE_NAME}</string>
<key>CFBundleIdentifier</key>
<string>Flomio.${PRODUCT_NAME:rfc1034identifier}</string>
<string>$(PRODUCT_BUNDLE_IDENTIFIER)</string>
<key>CFBundleInfoDictionaryVersion</key>
<string>6.0</string>
<key>CFBundlePackageType</key>
Expand All @@ -18,7 +20,5 @@
<string>????</string>
<key>CFBundleVersion</key>
<string>1</string>
<key></key>
<string></string>
</dict>
</plist>
3 changes: 2 additions & 1 deletion FloBLE-Mini/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,7 @@ Implement these guys:
- (void)nfcAdapter:(FJNFCAdapter *)nfcAdapter didReceiveFirmwareVersion:(NSString*)theVersionNumber;
- (void)nfcAdapter:(FJNFCAdapter *)nfcAdapter didReceiveHardwareVersion:(NSString*)theVersionNumber;
- (void)nfcAdapter:(FJNFCAdapter *)nfcAdapter didReceiveSnifferThresh:(NSString*)theSnifferValue;
- (void)nfcAdapter:(FJNFCAdapter *)nfcAdapter didReceiveWristbandState:(NSString *)theState;
- (void)nfcAdapterDidDetectFloJackConnected:(FJNFCAdapter *)nfcAdapter;
- (void)nfcAdapterDidDetectFloJackDisconnected:(FJNFCAdapter *)nfcAdapter;

Expand All @@ -72,4 +73,4 @@ This library is actively under development, much will be changing.

Contributing
---------------
Interested in bringing NFC to iOS? Get in touch info at flomio dot com.
Interested in bringing NFC to iOS? Get in touch info at flomio dot com.
33 changes: 13 additions & 20 deletions FloBLE-Mini/Reader Folder/FloBLEReader.h
Original file line number Diff line number Diff line change
Expand Up @@ -30,8 +30,7 @@ extern NSString * const floReaderConnectionStatusChangeNotification;
{
CBCentralManager * myCentralManager;
CBPeripheral *activePeripheral;
CBCharacteristic * serialF2hPortCharacteristic;
CBCharacteristic * serialPortH2fCharacteristic;
CBCharacteristic * batteryLevelCharacteristic;
CBCharacteristic * serialF2hPortBlockCharacteristic;
CBCharacteristic * serialH2fPortBlockCharacteristic;
CBCharacteristic * oadServiceCharacteristic;
Expand All @@ -48,8 +47,7 @@ extern NSString * const floReaderConnectionStatusChangeNotification;
@property (assign) BOOL isConnected;
@property (strong, nonatomic) CBCentralManager * myCentralManager;
@property (strong, nonatomic) CBPeripheral *activePeripheral;
@property (strong, nonatomic) CBCharacteristic * serialPortF2hCharacteristic;
@property (strong, nonatomic) CBCharacteristic * serialPortH2fCharacteristic;
@property (strong, nonatomic) CBCharacteristic * batteryLevelCharacteristic;
@property (strong, nonatomic) CBCharacteristic * serialF2hPortBlockCharacteristic;
@property (strong, nonatomic) CBCharacteristic * serialH2fPortBlockCharacteristic;
@property (strong, nonatomic) CBCharacteristic * oadServiceCharacteristic;
Expand Down Expand Up @@ -80,21 +78,16 @@ extern NSString * const floReaderConnectionStatusChangeNotification;
- (void)writeBlockToOadImageBlockTransferWithOutResponse:(UInt8*)dataToWrite ofLength:(UInt8)len;
- (protocolType_t)protocolType;

+ (CBUUID *) floBLEserviceUUID;
+ (CBUUID *) floBLEserviceUUID_03;
+ (CBUUID *) floBLEserviceUUID_04;
+ (CBUUID *) floBLEserviceUUID_08;
+ (CBUUID *) floBLEserviceUUID_11;
+ (CBUUID *) floBLEserviceUUID_12;
+ (CBUUID *) floBLEserviceUUID_13;
+ (CBUUID *) floBLEserviceUUID_14;
+ (CBUUID *) floBLEserviceUUID_19;
+ (CBUUID *) floBLEserviceUUID_20;
+ (CBUUID *) f2HcharacteristicUUID;
+ (CBUUID *) h2FhcharacteristicUUID;
+ (CBUUID *) f2HBlockcharacteristicUUID;
+ (CBUUID *) h2FBlockcharacteristicUUID;
+ (CBUUID *) deviceInformationServiceUUID;
+ (CBUUID *) hardwareRevisionStringUUID;
+ (CBUUID *) deviceInformationServiceUuid16bit;
+ (CBUUID *) batteryServiceUuid16bit;
+ (CBUUID *) batteryLevelCharacteristicUuid128bit;
+ (CBUUID *) oadServiceUuid16bit;
+ (CBUUID *) oadServiceUuid128bit;
+ (CBUUID *) floBleServiceUuid16bit;
+ (CBUUID *) floBleServiceUuid128bit;
+ (CBUUID *) f2hBlockCharacteristicUuid128bit;
+ (CBUUID *) h2fBlockCharacteristicUuid128bit;
+ (CBUUID *) oadImageIdentifyCharacteristicUuid128bit;
+ (CBUUID *) oadImageBlockTransferCharacteristicUuid128bit;

@end
Loading

0 comments on commit 0ce6f46

Please sign in to comment.