Przeglądaj źródła

First version

master
iot_user 5 lat temu
commit
fd6043bf35
26 zmienionych plików z 1126 dodań i 0 usunięć
  1. BIN
      BleTpms_SDK_Demo_URL.pdf
  2. BIN
      TPMSBleSDK - iOS_English.docx
  3. BIN
      TPMSBleSDK - iOS中文.docx
  4. 485
    0
      TPMSBleSDKDemo/TPMSBleSDKDemo.xcodeproj/project.pbxproj
  5. 7
    0
      TPMSBleSDKDemo/TPMSBleSDKDemo.xcodeproj/project.xcworkspace/contents.xcworkspacedata
  6. 8
    0
      TPMSBleSDKDemo/TPMSBleSDKDemo.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist
  7. BIN
      TPMSBleSDKDemo/TPMSBleSDKDemo.xcodeproj/project.xcworkspace/xcuserdata/iot_user.xcuserdatad/UserInterfaceState.xcuserstate
  8. 14
    0
      TPMSBleSDKDemo/TPMSBleSDKDemo.xcodeproj/xcuserdata/iot_user.xcuserdatad/xcschemes/xcschememanagement.plist
  9. 17
    0
      TPMSBleSDKDemo/TPMSBleSDKDemo/AppDelegate.h
  10. 53
    0
      TPMSBleSDKDemo/TPMSBleSDKDemo/AppDelegate.m
  11. 98
    0
      TPMSBleSDKDemo/TPMSBleSDKDemo/Assets.xcassets/AppIcon.appiconset/Contents.json
  12. 6
    0
      TPMSBleSDKDemo/TPMSBleSDKDemo/Assets.xcassets/Contents.json
  13. 25
    0
      TPMSBleSDKDemo/TPMSBleSDKDemo/Base.lproj/LaunchScreen.storyboard
  14. 24
    0
      TPMSBleSDKDemo/TPMSBleSDKDemo/Base.lproj/Main.storyboard
  15. 47
    0
      TPMSBleSDKDemo/TPMSBleSDKDemo/Info.plist
  16. 80
    0
      TPMSBleSDKDemo/TPMSBleSDKDemo/TPMSBleSDK.framework/Headers/ELTPMSBleManager.h
  17. 73
    0
      TPMSBleSDKDemo/TPMSBleSDKDemo/TPMSBleSDK.framework/Headers/ELTPMSDataModel.h
  18. 64
    0
      TPMSBleSDKDemo/TPMSBleSDKDemo/TPMSBleSDK.framework/Headers/ELTPMSHeader.h
  19. BIN
      TPMSBleSDKDemo/TPMSBleSDKDemo/TPMSBleSDK.framework/Info.plist
  20. BIN
      TPMSBleSDKDemo/TPMSBleSDKDemo/TPMSBleSDK.framework/TPMSBleSDK
  21. 15
    0
      TPMSBleSDKDemo/TPMSBleSDKDemo/ViewController.h
  22. 34
    0
      TPMSBleSDKDemo/TPMSBleSDKDemo/ViewController.m
  23. 16
    0
      TPMSBleSDKDemo/TPMSBleSDKDemo/main.m
  24. 22
    0
      TPMSBleSDKDemo/TPMSBleSDKDemoUITests/Info.plist
  25. 38
    0
      TPMSBleSDKDemo/TPMSBleSDKDemoUITests/TPMSBleSDKDemoUITests.m
  26. BIN
      TPMSBleSDK发布说明.doc

BIN
BleTpms_SDK_Demo_URL.pdf Wyświetl plik


BIN
TPMSBleSDK - iOS_English.docx Wyświetl plik


BIN
TPMSBleSDK - iOS中文.docx Wyświetl plik


+ 485
- 0
TPMSBleSDKDemo/TPMSBleSDKDemo.xcodeproj/project.pbxproj Wyświetl plik

@@ -0,0 +1,485 @@
// !$*UTF8*$!
{
archiveVersion = 1;
classes = {
};
objectVersion = 50;
objects = {

/* Begin PBXBuildFile section */
E6AD2F7A244073A900D362AB /* TPMSBleSDK.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = E6AD2F79244073A900D362AB /* TPMSBleSDK.framework */; };
E6EF567322D3314800F8B2DA /* AppDelegate.m in Sources */ = {isa = PBXBuildFile; fileRef = E6EF567222D3314800F8B2DA /* AppDelegate.m */; };
E6EF567622D3314800F8B2DA /* ViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = E6EF567522D3314800F8B2DA /* ViewController.m */; };
E6EF567922D3314800F8B2DA /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = E6EF567722D3314800F8B2DA /* Main.storyboard */; };
E6EF567B22D3314900F8B2DA /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = E6EF567A22D3314900F8B2DA /* Assets.xcassets */; };
E6EF567E22D3314900F8B2DA /* LaunchScreen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = E6EF567C22D3314900F8B2DA /* LaunchScreen.storyboard */; };
E6EF568122D3314900F8B2DA /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = E6EF568022D3314900F8B2DA /* main.m */; };
E6EF568B22D3314900F8B2DA /* TPMSBleSDKDemoUITests.m in Sources */ = {isa = PBXBuildFile; fileRef = E6EF568A22D3314900F8B2DA /* TPMSBleSDKDemoUITests.m */; };
/* End PBXBuildFile section */

/* Begin PBXContainerItemProxy section */
E6EF568722D3314900F8B2DA /* PBXContainerItemProxy */ = {
isa = PBXContainerItemProxy;
containerPortal = E6EF566622D3314800F8B2DA /* Project object */;
proxyType = 1;
remoteGlobalIDString = E6EF566D22D3314800F8B2DA;
remoteInfo = TPMSBleSDKDemo;
};
/* End PBXContainerItemProxy section */

/* Begin PBXFileReference section */
E6AD2F79244073A900D362AB /* TPMSBleSDK.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; path = TPMSBleSDK.framework; sourceTree = "<group>"; };
E6EF566E22D3314800F8B2DA /* TPMSBleSDKDemo.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = TPMSBleSDKDemo.app; sourceTree = BUILT_PRODUCTS_DIR; };
E6EF567122D3314800F8B2DA /* AppDelegate.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = AppDelegate.h; sourceTree = "<group>"; };
E6EF567222D3314800F8B2DA /* AppDelegate.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = AppDelegate.m; sourceTree = "<group>"; };
E6EF567422D3314800F8B2DA /* ViewController.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = ViewController.h; sourceTree = "<group>"; };
E6EF567522D3314800F8B2DA /* ViewController.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = ViewController.m; sourceTree = "<group>"; };
E6EF567822D3314800F8B2DA /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/Main.storyboard; sourceTree = "<group>"; };
E6EF567A22D3314900F8B2DA /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = "<group>"; };
E6EF567D22D3314900F8B2DA /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/LaunchScreen.storyboard; sourceTree = "<group>"; };
E6EF567F22D3314900F8B2DA /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = "<group>"; };
E6EF568022D3314900F8B2DA /* main.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = main.m; sourceTree = "<group>"; };
E6EF568622D3314900F8B2DA /* TPMSBleSDKDemoUITests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = TPMSBleSDKDemoUITests.xctest; sourceTree = BUILT_PRODUCTS_DIR; };
E6EF568A22D3314900F8B2DA /* TPMSBleSDKDemoUITests.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = TPMSBleSDKDemoUITests.m; sourceTree = "<group>"; };
E6EF568C22D3314900F8B2DA /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = "<group>"; };
/* End PBXFileReference section */

/* Begin PBXFrameworksBuildPhase section */
E6EF566B22D3314800F8B2DA /* Frameworks */ = {
isa = PBXFrameworksBuildPhase;
buildActionMask = 2147483647;
files = (
E6AD2F7A244073A900D362AB /* TPMSBleSDK.framework in Frameworks */,
);
runOnlyForDeploymentPostprocessing = 0;
};
E6EF568322D3314900F8B2DA /* Frameworks */ = {
isa = PBXFrameworksBuildPhase;
buildActionMask = 2147483647;
files = (
);
runOnlyForDeploymentPostprocessing = 0;
};
/* End PBXFrameworksBuildPhase section */

/* Begin PBXGroup section */
E6EF566522D3314800F8B2DA = {
isa = PBXGroup;
children = (
E6EF567022D3314800F8B2DA /* TPMSBleSDKDemo */,
E6EF568922D3314900F8B2DA /* TPMSBleSDKDemoUITests */,
E6EF566F22D3314800F8B2DA /* Products */,
);
sourceTree = "<group>";
};
E6EF566F22D3314800F8B2DA /* Products */ = {
isa = PBXGroup;
children = (
E6EF566E22D3314800F8B2DA /* TPMSBleSDKDemo.app */,
E6EF568622D3314900F8B2DA /* TPMSBleSDKDemoUITests.xctest */,
);
name = Products;
sourceTree = "<group>";
};
E6EF567022D3314800F8B2DA /* TPMSBleSDKDemo */ = {
isa = PBXGroup;
children = (
E6AD2F79244073A900D362AB /* TPMSBleSDK.framework */,
E6EF567122D3314800F8B2DA /* AppDelegate.h */,
E6EF567222D3314800F8B2DA /* AppDelegate.m */,
E6EF567422D3314800F8B2DA /* ViewController.h */,
E6EF567522D3314800F8B2DA /* ViewController.m */,
E6EF567722D3314800F8B2DA /* Main.storyboard */,
E6EF567A22D3314900F8B2DA /* Assets.xcassets */,
E6EF567C22D3314900F8B2DA /* LaunchScreen.storyboard */,
E6EF567F22D3314900F8B2DA /* Info.plist */,
E6EF568022D3314900F8B2DA /* main.m */,
);
path = TPMSBleSDKDemo;
sourceTree = "<group>";
};
E6EF568922D3314900F8B2DA /* TPMSBleSDKDemoUITests */ = {
isa = PBXGroup;
children = (
E6EF568A22D3314900F8B2DA /* TPMSBleSDKDemoUITests.m */,
E6EF568C22D3314900F8B2DA /* Info.plist */,
);
path = TPMSBleSDKDemoUITests;
sourceTree = "<group>";
};
/* End PBXGroup section */

/* Begin PBXNativeTarget section */
E6EF566D22D3314800F8B2DA /* TPMSBleSDKDemo */ = {
isa = PBXNativeTarget;
buildConfigurationList = E6EF568F22D3314900F8B2DA /* Build configuration list for PBXNativeTarget "TPMSBleSDKDemo" */;
buildPhases = (
E6EF566A22D3314800F8B2DA /* Sources */,
E6EF566B22D3314800F8B2DA /* Frameworks */,
E6EF566C22D3314800F8B2DA /* Resources */,
);
buildRules = (
);
dependencies = (
);
name = TPMSBleSDKDemo;
productName = TPMSBleSDKDemo;
productReference = E6EF566E22D3314800F8B2DA /* TPMSBleSDKDemo.app */;
productType = "com.apple.product-type.application";
};
E6EF568522D3314900F8B2DA /* TPMSBleSDKDemoUITests */ = {
isa = PBXNativeTarget;
buildConfigurationList = E6EF569222D3314900F8B2DA /* Build configuration list for PBXNativeTarget "TPMSBleSDKDemoUITests" */;
buildPhases = (
E6EF568222D3314900F8B2DA /* Sources */,
E6EF568322D3314900F8B2DA /* Frameworks */,
E6EF568422D3314900F8B2DA /* Resources */,
);
buildRules = (
);
dependencies = (
E6EF568822D3314900F8B2DA /* PBXTargetDependency */,
);
name = TPMSBleSDKDemoUITests;
productName = TPMSBleSDKDemoUITests;
productReference = E6EF568622D3314900F8B2DA /* TPMSBleSDKDemoUITests.xctest */;
productType = "com.apple.product-type.bundle.ui-testing";
};
/* End PBXNativeTarget section */

/* Begin PBXProject section */
E6EF566622D3314800F8B2DA /* Project object */ = {
isa = PBXProject;
attributes = {
LastUpgradeCheck = 1020;
ORGANIZATIONNAME = IOT;
TargetAttributes = {
E6EF566D22D3314800F8B2DA = {
CreatedOnToolsVersion = 10.2;
};
E6EF568522D3314900F8B2DA = {
CreatedOnToolsVersion = 10.2;
TestTargetID = E6EF566D22D3314800F8B2DA;
};
};
};
buildConfigurationList = E6EF566922D3314800F8B2DA /* Build configuration list for PBXProject "TPMSBleSDKDemo" */;
compatibilityVersion = "Xcode 9.3";
developmentRegion = en;
hasScannedForEncodings = 0;
knownRegions = (
en,
Base,
);
mainGroup = E6EF566522D3314800F8B2DA;
productRefGroup = E6EF566F22D3314800F8B2DA /* Products */;
projectDirPath = "";
projectRoot = "";
targets = (
E6EF566D22D3314800F8B2DA /* TPMSBleSDKDemo */,
E6EF568522D3314900F8B2DA /* TPMSBleSDKDemoUITests */,
);
};
/* End PBXProject section */

/* Begin PBXResourcesBuildPhase section */
E6EF566C22D3314800F8B2DA /* Resources */ = {
isa = PBXResourcesBuildPhase;
buildActionMask = 2147483647;
files = (
E6EF567E22D3314900F8B2DA /* LaunchScreen.storyboard in Resources */,
E6EF567B22D3314900F8B2DA /* Assets.xcassets in Resources */,
E6EF567922D3314800F8B2DA /* Main.storyboard in Resources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
E6EF568422D3314900F8B2DA /* Resources */ = {
isa = PBXResourcesBuildPhase;
buildActionMask = 2147483647;
files = (
);
runOnlyForDeploymentPostprocessing = 0;
};
/* End PBXResourcesBuildPhase section */

/* Begin PBXSourcesBuildPhase section */
E6EF566A22D3314800F8B2DA /* Sources */ = {
isa = PBXSourcesBuildPhase;
buildActionMask = 2147483647;
files = (
E6EF567622D3314800F8B2DA /* ViewController.m in Sources */,
E6EF568122D3314900F8B2DA /* main.m in Sources */,
E6EF567322D3314800F8B2DA /* AppDelegate.m in Sources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
E6EF568222D3314900F8B2DA /* Sources */ = {
isa = PBXSourcesBuildPhase;
buildActionMask = 2147483647;
files = (
E6EF568B22D3314900F8B2DA /* TPMSBleSDKDemoUITests.m in Sources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
/* End PBXSourcesBuildPhase section */

/* Begin PBXTargetDependency section */
E6EF568822D3314900F8B2DA /* PBXTargetDependency */ = {
isa = PBXTargetDependency;
target = E6EF566D22D3314800F8B2DA /* TPMSBleSDKDemo */;
targetProxy = E6EF568722D3314900F8B2DA /* PBXContainerItemProxy */;
};
/* End PBXTargetDependency section */

/* Begin PBXVariantGroup section */
E6EF567722D3314800F8B2DA /* Main.storyboard */ = {
isa = PBXVariantGroup;
children = (
E6EF567822D3314800F8B2DA /* Base */,
);
name = Main.storyboard;
sourceTree = "<group>";
};
E6EF567C22D3314900F8B2DA /* LaunchScreen.storyboard */ = {
isa = PBXVariantGroup;
children = (
E6EF567D22D3314900F8B2DA /* Base */,
);
name = LaunchScreen.storyboard;
sourceTree = "<group>";
};
/* End PBXVariantGroup section */

/* Begin XCBuildConfiguration section */
E6EF568D22D3314900F8B2DA /* Debug */ = {
isa = XCBuildConfiguration;
buildSettings = {
ALWAYS_SEARCH_USER_PATHS = NO;
CLANG_ANALYZER_NONNULL = YES;
CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE;
CLANG_CXX_LANGUAGE_STANDARD = "gnu++14";
CLANG_CXX_LIBRARY = "libc++";
CLANG_ENABLE_MODULES = YES;
CLANG_ENABLE_OBJC_ARC = YES;
CLANG_ENABLE_OBJC_WEAK = YES;
CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES;
CLANG_WARN_BOOL_CONVERSION = YES;
CLANG_WARN_COMMA = YES;
CLANG_WARN_CONSTANT_CONVERSION = YES;
CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES;
CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
CLANG_WARN_DOCUMENTATION_COMMENTS = YES;
CLANG_WARN_EMPTY_BODY = YES;
CLANG_WARN_ENUM_CONVERSION = YES;
CLANG_WARN_INFINITE_RECURSION = YES;
CLANG_WARN_INT_CONVERSION = YES;
CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES;
CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES;
CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
CLANG_WARN_STRICT_PROTOTYPES = YES;
CLANG_WARN_SUSPICIOUS_MOVE = YES;
CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE;
CLANG_WARN_UNREACHABLE_CODE = YES;
CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
CODE_SIGN_IDENTITY = "iPhone Developer";
COPY_PHASE_STRIP = NO;
DEBUG_INFORMATION_FORMAT = dwarf;
ENABLE_STRICT_OBJC_MSGSEND = YES;
ENABLE_TESTABILITY = YES;
GCC_C_LANGUAGE_STANDARD = gnu11;
GCC_DYNAMIC_NO_PIC = NO;
GCC_NO_COMMON_BLOCKS = YES;
GCC_OPTIMIZATION_LEVEL = 0;
GCC_PREPROCESSOR_DEFINITIONS = (
"DEBUG=1",
"$(inherited)",
);
GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR;
GCC_WARN_UNDECLARED_SELECTOR = YES;
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
IPHONEOS_DEPLOYMENT_TARGET = 12.2;
MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE;
MTL_FAST_MATH = YES;
ONLY_ACTIVE_ARCH = YES;
SDKROOT = iphoneos;
};
name = Debug;
};
E6EF568E22D3314900F8B2DA /* Release */ = {
isa = XCBuildConfiguration;
buildSettings = {
ALWAYS_SEARCH_USER_PATHS = NO;
CLANG_ANALYZER_NONNULL = YES;
CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE;
CLANG_CXX_LANGUAGE_STANDARD = "gnu++14";
CLANG_CXX_LIBRARY = "libc++";
CLANG_ENABLE_MODULES = YES;
CLANG_ENABLE_OBJC_ARC = YES;
CLANG_ENABLE_OBJC_WEAK = YES;
CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES;
CLANG_WARN_BOOL_CONVERSION = YES;
CLANG_WARN_COMMA = YES;
CLANG_WARN_CONSTANT_CONVERSION = YES;
CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES;
CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
CLANG_WARN_DOCUMENTATION_COMMENTS = YES;
CLANG_WARN_EMPTY_BODY = YES;
CLANG_WARN_ENUM_CONVERSION = YES;
CLANG_WARN_INFINITE_RECURSION = YES;
CLANG_WARN_INT_CONVERSION = YES;
CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES;
CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES;
CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
CLANG_WARN_STRICT_PROTOTYPES = YES;
CLANG_WARN_SUSPICIOUS_MOVE = YES;
CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE;
CLANG_WARN_UNREACHABLE_CODE = YES;
CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
CODE_SIGN_IDENTITY = "iPhone Developer";
COPY_PHASE_STRIP = NO;
DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
ENABLE_NS_ASSERTIONS = NO;
ENABLE_STRICT_OBJC_MSGSEND = YES;
GCC_C_LANGUAGE_STANDARD = gnu11;
GCC_NO_COMMON_BLOCKS = YES;
GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR;
GCC_WARN_UNDECLARED_SELECTOR = YES;
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
IPHONEOS_DEPLOYMENT_TARGET = 12.2;
MTL_ENABLE_DEBUG_INFO = NO;
MTL_FAST_MATH = YES;
SDKROOT = iphoneos;
VALIDATE_PRODUCT = YES;
};
name = Release;
};
E6EF569022D3314900F8B2DA /* Debug */ = {
isa = XCBuildConfiguration;
buildSettings = {
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
CODE_SIGN_IDENTITY = "Apple Development";
CODE_SIGN_STYLE = Automatic;
DEVELOPMENT_TEAM = UGR97GV55J;
ENABLE_BITCODE = NO;
FRAMEWORK_SEARCH_PATHS = (
"$(inherited)",
"$(PROJECT_DIR)/TPMSBleSDKDemo",
);
INFOPLIST_FILE = TPMSBleSDKDemo/Info.plist;
IPHONEOS_DEPLOYMENT_TARGET = 9.0;
LD_RUNPATH_SEARCH_PATHS = (
"$(inherited)",
"@executable_path/Frameworks",
);
PRODUCT_BUNDLE_IDENTIFIER = com.pingwang.TPMSBleSDK;
PRODUCT_NAME = "$(TARGET_NAME)";
PROVISIONING_PROFILE_SPECIFIER = "";
TARGETED_DEVICE_FAMILY = "1,2";
};
name = Debug;
};
E6EF569122D3314900F8B2DA /* Release */ = {
isa = XCBuildConfiguration;
buildSettings = {
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
CODE_SIGN_IDENTITY = "Apple Development";
CODE_SIGN_STYLE = Automatic;
DEVELOPMENT_TEAM = UGR97GV55J;
ENABLE_BITCODE = NO;
FRAMEWORK_SEARCH_PATHS = (
"$(inherited)",
"$(PROJECT_DIR)/TPMSBleSDKDemo",
);
INFOPLIST_FILE = TPMSBleSDKDemo/Info.plist;
IPHONEOS_DEPLOYMENT_TARGET = 9.0;
LD_RUNPATH_SEARCH_PATHS = (
"$(inherited)",
"@executable_path/Frameworks",
);
PRODUCT_BUNDLE_IDENTIFIER = com.pingwang.TPMSBleSDK;
PRODUCT_NAME = "$(TARGET_NAME)";
PROVISIONING_PROFILE_SPECIFIER = "";
TARGETED_DEVICE_FAMILY = "1,2";
};
name = Release;
};
E6EF569322D3314900F8B2DA /* Debug */ = {
isa = XCBuildConfiguration;
buildSettings = {
CODE_SIGN_STYLE = Automatic;
DEVELOPMENT_TEAM = YEU77XR292;
INFOPLIST_FILE = TPMSBleSDKDemoUITests/Info.plist;
LD_RUNPATH_SEARCH_PATHS = (
"$(inherited)",
"@executable_path/Frameworks",
"@loader_path/Frameworks",
);
PRODUCT_BUNDLE_IDENTIFIER = com.pingwang.TPMSBleSDKDemoUITests;
PRODUCT_NAME = "$(TARGET_NAME)";
TARGETED_DEVICE_FAMILY = "1,2";
TEST_TARGET_NAME = TPMSBleSDKDemo;
};
name = Debug;
};
E6EF569422D3314900F8B2DA /* Release */ = {
isa = XCBuildConfiguration;
buildSettings = {
CODE_SIGN_STYLE = Automatic;
DEVELOPMENT_TEAM = YEU77XR292;
INFOPLIST_FILE = TPMSBleSDKDemoUITests/Info.plist;
LD_RUNPATH_SEARCH_PATHS = (
"$(inherited)",
"@executable_path/Frameworks",
"@loader_path/Frameworks",
);
PRODUCT_BUNDLE_IDENTIFIER = com.pingwang.TPMSBleSDKDemoUITests;
PRODUCT_NAME = "$(TARGET_NAME)";
TARGETED_DEVICE_FAMILY = "1,2";
TEST_TARGET_NAME = TPMSBleSDKDemo;
};
name = Release;
};
/* End XCBuildConfiguration section */

/* Begin XCConfigurationList section */
E6EF566922D3314800F8B2DA /* Build configuration list for PBXProject "TPMSBleSDKDemo" */ = {
isa = XCConfigurationList;
buildConfigurations = (
E6EF568D22D3314900F8B2DA /* Debug */,
E6EF568E22D3314900F8B2DA /* Release */,
);
defaultConfigurationIsVisible = 0;
defaultConfigurationName = Release;
};
E6EF568F22D3314900F8B2DA /* Build configuration list for PBXNativeTarget "TPMSBleSDKDemo" */ = {
isa = XCConfigurationList;
buildConfigurations = (
E6EF569022D3314900F8B2DA /* Debug */,
E6EF569122D3314900F8B2DA /* Release */,
);
defaultConfigurationIsVisible = 0;
defaultConfigurationName = Release;
};
E6EF569222D3314900F8B2DA /* Build configuration list for PBXNativeTarget "TPMSBleSDKDemoUITests" */ = {
isa = XCConfigurationList;
buildConfigurations = (
E6EF569322D3314900F8B2DA /* Debug */,
E6EF569422D3314900F8B2DA /* Release */,
);
defaultConfigurationIsVisible = 0;
defaultConfigurationName = Release;
};
/* End XCConfigurationList section */
};
rootObject = E6EF566622D3314800F8B2DA /* Project object */;
}

+ 7
- 0
TPMSBleSDKDemo/TPMSBleSDKDemo.xcodeproj/project.xcworkspace/contents.xcworkspacedata Wyświetl plik

@@ -0,0 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<Workspace
version = "1.0">
<FileRef
location = "self:TPMSBleSDKDemo.xcodeproj">
</FileRef>
</Workspace>

+ 8
- 0
TPMSBleSDKDemo/TPMSBleSDKDemo.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist Wyświetl plik

@@ -0,0 +1,8 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>IDEDidComputeMac32BitWarning</key>
<true/>
</dict>
</plist>

BIN
TPMSBleSDKDemo/TPMSBleSDKDemo.xcodeproj/project.xcworkspace/xcuserdata/iot_user.xcuserdatad/UserInterfaceState.xcuserstate Wyświetl plik


+ 14
- 0
TPMSBleSDKDemo/TPMSBleSDKDemo.xcodeproj/xcuserdata/iot_user.xcuserdatad/xcschemes/xcschememanagement.plist Wyświetl plik

@@ -0,0 +1,14 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>SchemeUserState</key>
<dict>
<key>TPMSBleSDKDemo.xcscheme_^#shared#^_</key>
<dict>
<key>orderHint</key>
<integer>0</integer>
</dict>
</dict>
</dict>
</plist>

+ 17
- 0
TPMSBleSDKDemo/TPMSBleSDKDemo/AppDelegate.h Wyświetl plik

@@ -0,0 +1,17 @@
//
// AppDelegate.h
// TPMSBleSDKDemo
//
// Created by iot_user on 2019/7/8.
// Copyright © 2019 IOT. All rights reserved.
//

#import <UIKit/UIKit.h>

@interface AppDelegate : UIResponder <UIApplicationDelegate>

@property (strong, nonatomic) UIWindow *window;


@end


+ 53
- 0
TPMSBleSDKDemo/TPMSBleSDKDemo/AppDelegate.m Wyświetl plik

@@ -0,0 +1,53 @@
//
// AppDelegate.m
// TPMSBleSDKDemo
//
// Created by iot_user on 2019/7/8.
// Copyright © 2019 IOT. All rights reserved.
//

#import "AppDelegate.h"
#import <TPMSBleSDK/ELTPMSBleManager.h>

@interface AppDelegate ()

@end

@implementation AppDelegate


- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions {
// Override point for customization after application launch.
[ELTPMSBleManager setAppKey:@"1fe0a76abf0abba7" appSecret:@"00ad68a8f1f7057f8eda6ed7a9"];
return YES;
}


- (void)applicationWillResignActive:(UIApplication *)application {
// Sent when the application is about to move from active to inactive state. This can occur for certain types of temporary interruptions (such as an incoming phone call or SMS message) or when the user quits the application and it begins the transition to the background state.
// Use this method to pause ongoing tasks, disable timers, and invalidate graphics rendering callbacks. Games should use this method to pause the game.
}


- (void)applicationDidEnterBackground:(UIApplication *)application {
// Use this method to release shared resources, save user data, invalidate timers, and store enough application state information to restore your application to its current state in case it is terminated later.
// If your application supports background execution, this method is called instead of applicationWillTerminate: when the user quits.
}


- (void)applicationWillEnterForeground:(UIApplication *)application {
// Called as part of the transition from the background to the active state; here you can undo many of the changes made on entering the background.
}


- (void)applicationDidBecomeActive:(UIApplication *)application {
// Restart any tasks that were paused (or not yet started) while the application was inactive. If the application was previously in the background, optionally refresh the user interface.
}


- (void)applicationWillTerminate:(UIApplication *)application {
// Called when the application is about to terminate. Save data if appropriate. See also applicationDidEnterBackground:.
}


@end

+ 98
- 0
TPMSBleSDKDemo/TPMSBleSDKDemo/Assets.xcassets/AppIcon.appiconset/Contents.json Wyświetl plik

@@ -0,0 +1,98 @@
{
"images" : [
{
"idiom" : "iphone",
"size" : "20x20",
"scale" : "2x"
},
{
"idiom" : "iphone",
"size" : "20x20",
"scale" : "3x"
},
{
"idiom" : "iphone",
"size" : "29x29",
"scale" : "2x"
},
{
"idiom" : "iphone",
"size" : "29x29",
"scale" : "3x"
},
{
"idiom" : "iphone",
"size" : "40x40",
"scale" : "2x"
},
{
"idiom" : "iphone",
"size" : "40x40",
"scale" : "3x"
},
{
"idiom" : "iphone",
"size" : "60x60",
"scale" : "2x"
},
{
"idiom" : "iphone",
"size" : "60x60",
"scale" : "3x"
},
{
"idiom" : "ipad",
"size" : "20x20",
"scale" : "1x"
},
{
"idiom" : "ipad",
"size" : "20x20",
"scale" : "2x"
},
{
"idiom" : "ipad",
"size" : "29x29",
"scale" : "1x"
},
{
"idiom" : "ipad",
"size" : "29x29",
"scale" : "2x"
},
{
"idiom" : "ipad",
"size" : "40x40",
"scale" : "1x"
},
{
"idiom" : "ipad",
"size" : "40x40",
"scale" : "2x"
},
{
"idiom" : "ipad",
"size" : "76x76",
"scale" : "1x"
},
{
"idiom" : "ipad",
"size" : "76x76",
"scale" : "2x"
},
{
"idiom" : "ipad",
"size" : "83.5x83.5",
"scale" : "2x"
},
{
"idiom" : "ios-marketing",
"size" : "1024x1024",
"scale" : "1x"
}
],
"info" : {
"version" : 1,
"author" : "xcode"
}
}

+ 6
- 0
TPMSBleSDKDemo/TPMSBleSDKDemo/Assets.xcassets/Contents.json Wyświetl plik

@@ -0,0 +1,6 @@
{
"info" : {
"version" : 1,
"author" : "xcode"
}
}

+ 25
- 0
TPMSBleSDKDemo/TPMSBleSDKDemo/Base.lproj/LaunchScreen.storyboard Wyświetl plik

@@ -0,0 +1,25 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<document type="com.apple.InterfaceBuilder3.CocoaTouch.Storyboard.XIB" version="3.0" toolsVersion="13122.16" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" launchScreen="YES" useTraitCollections="YES" useSafeAreas="YES" colorMatched="YES" initialViewController="01J-lp-oVM">
<dependencies>
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="13104.12"/>
<capability name="Safe area layout guides" minToolsVersion="9.0"/>
<capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
</dependencies>
<scenes>
<!--View Controller-->
<scene sceneID="EHf-IW-A2E">
<objects>
<viewController id="01J-lp-oVM" sceneMemberID="viewController">
<view key="view" contentMode="scaleToFill" id="Ze5-6b-2t3">
<rect key="frame" x="0.0" y="0.0" width="375" height="667"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<color key="backgroundColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
<viewLayoutGuide key="safeArea" id="6Tk-OE-BBY"/>
</view>
</viewController>
<placeholder placeholderIdentifier="IBFirstResponder" id="iYj-Kq-Ea1" userLabel="First Responder" sceneMemberID="firstResponder"/>
</objects>
<point key="canvasLocation" x="53" y="375"/>
</scene>
</scenes>
</document>

+ 24
- 0
TPMSBleSDKDemo/TPMSBleSDKDemo/Base.lproj/Main.storyboard Wyświetl plik

@@ -0,0 +1,24 @@
<?xml version="1.0" encoding="UTF-8"?>
<document type="com.apple.InterfaceBuilder3.CocoaTouch.Storyboard.XIB" version="3.0" toolsVersion="13122.16" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" useSafeAreas="YES" colorMatched="YES" initialViewController="BYZ-38-t0r">
<dependencies>
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="13104.12"/>
<capability name="Safe area layout guides" minToolsVersion="9.0"/>
<capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
</dependencies>
<scenes>
<!--View Controller-->
<scene sceneID="tne-QT-ifu">
<objects>
<viewController id="BYZ-38-t0r" customClass="ViewController" customModuleProvider="" sceneMemberID="viewController">
<view key="view" contentMode="scaleToFill" id="8bC-Xf-vdC">
<rect key="frame" x="0.0" y="0.0" width="375" height="667"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<color key="backgroundColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
<viewLayoutGuide key="safeArea" id="6Tk-OE-BBY"/>
</view>
</viewController>
<placeholder placeholderIdentifier="IBFirstResponder" id="dkx-z0-nzr" sceneMemberID="firstResponder"/>
</objects>
</scene>
</scenes>
</document>

+ 47
- 0
TPMSBleSDKDemo/TPMSBleSDKDemo/Info.plist Wyświetl plik

@@ -0,0 +1,47 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>CFBundleDevelopmentRegion</key>
<string>$(DEVELOPMENT_LANGUAGE)</string>
<key>CFBundleExecutable</key>
<string>$(EXECUTABLE_NAME)</string>
<key>CFBundleIdentifier</key>
<string>$(PRODUCT_BUNDLE_IDENTIFIER)</string>
<key>CFBundleInfoDictionaryVersion</key>
<string>6.0</string>
<key>CFBundleName</key>
<string>$(PRODUCT_NAME)</string>
<key>CFBundlePackageType</key>
<string>APPL</string>
<key>CFBundleShortVersionString</key>
<string>1.0</string>
<key>CFBundleVersion</key>
<string>1</string>
<key>LSRequiresIPhoneOS</key>
<true/>
<key>UILaunchStoryboardName</key>
<string>LaunchScreen</string>
<key>UIMainStoryboardFile</key>
<string>Main</string>
<key>UIRequiredDeviceCapabilities</key>
<array>
<string>armv7</string>
</array>
<key>UISupportedInterfaceOrientations</key>
<array>
<string>UIInterfaceOrientationPortrait</string>
<string>UIInterfaceOrientationLandscapeLeft</string>
<string>UIInterfaceOrientationLandscapeRight</string>
</array>
<key>UISupportedInterfaceOrientations~ipad</key>
<array>
<string>UIInterfaceOrientationPortrait</string>
<string>UIInterfaceOrientationPortraitUpsideDown</string>
<string>UIInterfaceOrientationLandscapeLeft</string>
<string>UIInterfaceOrientationLandscapeRight</string>
</array>
<key>NSBluetoothAlwaysUsageDescription</key>
<string></string>
</dict>
</plist>

+ 80
- 0
TPMSBleSDKDemo/TPMSBleSDKDemo/TPMSBleSDK.framework/Headers/ELTPMSBleManager.h Wyświetl plik

@@ -0,0 +1,80 @@
//
// ELTPMSBleManager.h
// Elink
//
// Created by iot_user on 2019/5/23.
// Copyright © 2019 iot_iMac. All rights reserved.
//

#import <Foundation/Foundation.h>
#import "ELTPMSDataModel.h"

typedef NS_ENUM(NSUInteger, TPMSBluetoothState) {
TPMSBluetoothStateAvailable = 0, //Open available(打开可用)
TPMSBluetoothStateUnavailable = 1, //unavailable(不可用)
TPMSBluetoothStateBroadcasting = 2, //Broadcasting(正在广播)
TPMSBluetoothStateStopBroadcasting = 3, //Stop broadcasting(停止广播)
};


//Bluetooth name prefix(蓝牙名称前缀)
#define TPMSName @"TPMS_" //Such as:TPMS_B9F5BB

@protocol ELTPMSBleManagerDelegate <NSObject>

/**
Return to Bluetooth status(返回蓝牙状态)

@param state Bluetooth status(蓝牙状态)
*/
-(void)TPMSBleManagerUpdateBleState:(TPMSBluetoothState)state;

/**
Callback tire pressure data(回调胎压数据)

@param model Tire pressure data model(胎压数据模型)
*/
-(void)TPMSBleManagerReceiveData:(ELTPMSDataModel *_Nonnull)model;

@end


NS_ASSUME_NONNULL_BEGIN

@interface ELTPMSBleManager : NSObject

/**
Bluetooth is available to open(蓝牙是否打开可用)
*/
@property (nonatomic, assign, readonly) BOOL isOn;

/**
Agent callback(代理回调)
*/
@property (nonatomic, weak) id<ELTPMSBleManagerDelegate> delegate;


+(void)setAppKey:(NSString *)key appSecret:(NSString *)secret;


+(instancetype)shareManager;

/**
Start scanning(开始扫描)
*/
-(void)startScan;

/**
Stop scanning(停止扫描)
*/
-(void)stopScan;

/**
Get the SDK version number(获取SDK版本号)

@return version
*/
-(NSString *)sdkVersion;
@end

NS_ASSUME_NONNULL_END

+ 73
- 0
TPMSBleSDKDemo/TPMSBleSDKDemo/TPMSBleSDK.framework/Headers/ELTPMSDataModel.h Wyświetl plik

@@ -0,0 +1,73 @@
//
// ELTPMSDataModel.h
// Elink
//
// Created by iot_user on 2019/5/23.
// Copyright © 2019 iot_iMac. All rights reserved.
//

#import <Foundation/Foundation.h>

typedef NS_ENUM(NSUInteger, ELTPMSDataType) {
ELTPMSDataType_Mode1_87 = 0, //Mode 1 87(模式一87)
ELTPMSDataType_Mode1_87E = 1, //Mode 1 87E(模式一87E)
ELTPMSDataType_Mode2 = 2, //Mode 2
};

typedef NS_ENUM(NSInteger, ELTPMSDeviceState) {
ELTPMSDeviceStateNormal = 0x00, //Normal(正常)
ELTPMSDeviceStateAirLeakage = 0x01, //Air Leakage (漏气)
ELTPMSDeviceStateInflatable = 0x02, //Inflatable(充气)
ELTPMSDeviceStateStart = 0x03, //Start(启动)
ELTPMSDeviceStatePowerOn = 0x04, //Power On(上电)
ELTPMSDeviceStateWakeUp = 0x05, //Wake Up(唤醒)
};


NS_ASSUME_NONNULL_BEGIN

@interface ELTPMSDataModel : NSObject<NSCopying>

@property (nonatomic, assign) ELTPMSDataType type;//

@property (nonatomic, assign) int classID;//Product number(产品型号 CID)

@property (nonatomic, assign) double v;//Voltage coefficient (unit: V)(电压系数(单位:V))

@property (nonatomic, assign) double p;//Pressure coefficient (unit: kPa)(压力系数(单位:kPa))

@property (nonatomic, assign) int t;//Temperature coefficient (unit: °C)(温度系数( 单位:°C ))

@property (nonatomic, assign) ELTPMSDeviceState state;//status(状态)

@property (nonatomic, copy) NSString *mcuVersion; // Reserved byte (MCU version number)(保留字节(MCU 版本号))

@property (nonatomic, assign) int startCount;//The number of starts, when the state is ELTPMSDeviceStateStart, it means the number of times the startup state was sent (maximum of 4)(启动次数,当状态 state 为ELTPMSDeviceStateStart时,代表发送了启动状态的次数(最大为 4 次))

@property (nonatomic, assign) int stopCount;//When the state state is ELTPMSDeviceStateNormal, value<10 appears, indicating the number of sneak stops (maximum of 6)(当状态 state 为ELTPMSDeviceStateNormal时,出现 value<10,表示潜停次数(最大为 6 次))

@property (nonatomic, copy) NSString *bleVersion; //BLE version number

@property (nonatomic, copy) NSString *macAddress; // MAC address

@property (nonatomic, copy) NSString *name;//name

@property (nonatomic, assign) NSInteger createTime;//Time when data was received(接收到数据的时间)




/**
analyze data(分析数据)

@param data Bluetooth broadcast raw data(蓝牙广播的原始数据)
@param name Bluetooth name(蓝牙名称)
@param type Bluetooth module type(蓝牙模块类型)
@return Tire pressure data model(胎压数据模型)
*/
+(ELTPMSDataModel *)analysisData:(NSData *)data peripheralName:(NSString *)name type:(ELTPMSDataType)type;

@end

NS_ASSUME_NONNULL_END

+ 64
- 0
TPMSBleSDKDemo/TPMSBleSDKDemo/TPMSBleSDK.framework/Headers/ELTPMSHeader.h Wyświetl plik

@@ -0,0 +1,64 @@
//
// ELTPMSHeader.h
// Elink
//
// Created by iot_user on 2019/6/10.
// Copyright © 2019 iot_iMac. All rights reserved.
//

#ifndef ELTPMSHeader_h
#define ELTPMSHeader_h

typedef NS_ENUM(NSUInteger, TPMSTyreUnitType) {
TPMSTyreUnitType_Bar = 0,
TPMSTyreUnitType_Psi = 1,
TPMSTyreUnitType_Kpa = 2,
};

typedef NS_ENUM(NSUInteger, TPMSTempUnitType) {
TPMSTempUnitType_C = 0,
TPMSTempUnitType_F = 1
};

typedef NS_ENUM(NSUInteger, TPMSWheelTyreType) {
TPMSWheelTyreTypeNormal = 0,//normal(正常)
TPMSWheelTyreTypeLow = 1,//Low pressure(胎压过低)
TPMSWheelTyreTypeHigh = 2,//High pressure(胎压过高)
};
//Air leak, high temperature, high tire pressure, low tire pressure, low battery(漏气、温度过高、胎压过高、胎压过低、电量低)
typedef NS_ENUM(NSUInteger, TPMSWheelExceptionType) {
TPMSWheelExceptionTypeNormal = 0, //normal(正常)
TPMSWheelExceptionTypeAirLeakage = 1, //Air leak(漏气)
TPMSWheelExceptionTypeTempHigh = 2, //high temperature(温度过高)
TPMSWheelExceptionTypeTyreHigh = 3, //high tire pressure(胎压过高)
TPMSWheelExceptionTypeTyreLow = 4, //low tire pressure(胎压过低)
TPMSWheelExceptionTypeLowPower = 5, //low battery(电量低)
TPMSWheelExceptionTypeNoSignal = 6, //no signal(无信号)
};



#define TPMSTyreUnitDic @{\
@(TPMSTyreUnitType_Bar):@"Bar",\
@(TPMSTyreUnitType_Psi):@"Psi",\
@(TPMSTyreUnitType_Kpa):@"Kpa"\
}\

#define TPMSTempUnitDic @{@(TPMSTempUnitType_C):@"℃",@(TPMSTempUnitType_F):@"℉"}


#define TPMSTyreUnit_Bar @"Bar"
#define TPMSTyreUnit_Psi @"Psi"
#define TPMSTyreUnit_Kpa @"Kpa"

#define TPMSTempUnit_C @"℃"
#define TPMSTempUnit_F @"℉"

#define Kpa_To_Bar 0.01
#define Kpa_To_Psi 0.1450377
#define Bar_TO_Kpa 100
#define Bar_TO_Psi 14.5037744

#define C_TO_F(C) (C*1.8+32) //F = C*1.8 + 32
#define F_To_C(F) ((F-32)/1.8)
#endif /* ELTPMSHeader_h */

BIN
TPMSBleSDKDemo/TPMSBleSDKDemo/TPMSBleSDK.framework/Info.plist Wyświetl plik


BIN
TPMSBleSDKDemo/TPMSBleSDKDemo/TPMSBleSDK.framework/TPMSBleSDK Wyświetl plik


+ 15
- 0
TPMSBleSDKDemo/TPMSBleSDKDemo/ViewController.h Wyświetl plik

@@ -0,0 +1,15 @@
//
// ViewController.h
// TPMSBleSDKDemo
//
// Created by iot_user on 2019/7/8.
// Copyright © 2019 IOT. All rights reserved.
//

#import <UIKit/UIKit.h>

@interface ViewController : UIViewController


@end


+ 34
- 0
TPMSBleSDKDemo/TPMSBleSDKDemo/ViewController.m Wyświetl plik

@@ -0,0 +1,34 @@
//
// ViewController.m
// TPMSBleSDKDemo
//
// Created by iot_user on 2019/7/8.
// Copyright © 2019 IOT. All rights reserved.
//

#import "ViewController.h"

#import <TPMSBleSDK/ELTPMSBleManager.h>


@interface ViewController ()<ELTPMSBleManagerDelegate>

@end

@implementation ViewController

- (void)viewDidLoad {
[super viewDidLoad];
[ELTPMSBleManager shareManager].delegate = self;
[[ELTPMSBleManager shareManager] startScan];
}
#pragma mark ============ ELTPMSBleManagerDelegate ==============
-(void)TPMSBleManagerUpdateBleState:(TPMSBluetoothState)state{
NSLog(@"TPMSBleManagerUpdateBleState = %ld",state);
}
-(void)TPMSBleManagerReceiveData:(ELTPMSDataModel *)model{
NSLog(@"TPMSBleManagerReceiveData = %@",model.description);
}

@end

+ 16
- 0
TPMSBleSDKDemo/TPMSBleSDKDemo/main.m Wyświetl plik

@@ -0,0 +1,16 @@
//
// main.m
// TPMSBleSDKDemo
//
// Created by iot_user on 2019/7/8.
// Copyright © 2019 IOT. All rights reserved.
//

#import <UIKit/UIKit.h>
#import "AppDelegate.h"

int main(int argc, char * argv[]) {
@autoreleasepool {
return UIApplicationMain(argc, argv, nil, NSStringFromClass([AppDelegate class]));
}
}

+ 22
- 0
TPMSBleSDKDemo/TPMSBleSDKDemoUITests/Info.plist Wyświetl plik

@@ -0,0 +1,22 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>CFBundleDevelopmentRegion</key>
<string>$(DEVELOPMENT_LANGUAGE)</string>
<key>CFBundleExecutable</key>
<string>$(EXECUTABLE_NAME)</string>
<key>CFBundleIdentifier</key>
<string>$(PRODUCT_BUNDLE_IDENTIFIER)</string>
<key>CFBundleInfoDictionaryVersion</key>
<string>6.0</string>
<key>CFBundleName</key>
<string>$(PRODUCT_NAME)</string>
<key>CFBundlePackageType</key>
<string>BNDL</string>
<key>CFBundleShortVersionString</key>
<string>1.0</string>
<key>CFBundleVersion</key>
<string>1</string>
</dict>
</plist>

+ 38
- 0
TPMSBleSDKDemo/TPMSBleSDKDemoUITests/TPMSBleSDKDemoUITests.m Wyświetl plik

@@ -0,0 +1,38 @@
//
// TPMSBleSDKDemoUITests.m
// TPMSBleSDKDemoUITests
//
// Created by iot_user on 2019/7/8.
// Copyright © 2019 IOT. All rights reserved.
//

#import <XCTest/XCTest.h>

@interface TPMSBleSDKDemoUITests : XCTestCase

@end

@implementation TPMSBleSDKDemoUITests

- (void)setUp {
// Put setup code here. This method is called before the invocation of each test method in the class.

// In UI tests it is usually best to stop immediately when a failure occurs.
self.continueAfterFailure = NO;

// UI tests must launch the application that they test. Doing this in setup will make sure it happens for each test method.
[[[XCUIApplication alloc] init] launch];

// In UI tests it’s important to set the initial state - such as interface orientation - required for your tests before they run. The setUp method is a good place to do this.
}

- (void)tearDown {
// Put teardown code here. This method is called after the invocation of each test method in the class.
}

- (void)testExample {
// Use recording to get started writing UI tests.
// Use XCTAssert and related functions to verify your tests produce the correct results.
}

@end

BIN
TPMSBleSDK发布说明.doc Wyświetl plik


Ładowanie…
Anuluj
Zapisz