├── .gitignore ├── AHAP Tester.xcodeproj ├── project.pbxproj └── project.xcworkspace │ ├── contents.xcworkspacedata │ └── xcshareddata │ └── IDEWorkspaceChecks.plist ├── AHAP Tester ├── AppDelegate.swift ├── AppStoryboards.swift ├── Assets.xcassets │ ├── AppIcon.appiconset │ │ ├── AppIcon-1024.0x1024.0@1x.png │ │ ├── AppIcon-20.0x20.0@2x.png │ │ ├── AppIcon-20.0x20.0@3x.png │ │ ├── AppIcon-29.0x29.0@2x.png │ │ ├── AppIcon-29.0x29.0@3x.png │ │ ├── AppIcon-40.0x40.0@2x.png │ │ ├── AppIcon-40.0x40.0@3x.png │ │ ├── AppIcon-60.0x60.0@2x.png │ │ ├── AppIcon-60.0x60.0@3x.png │ │ └── Contents.json │ ├── Contents.json │ ├── MainTint.colorset │ │ └── Contents.json │ └── lines.imageset │ │ ├── Artboard Copy.pdf │ │ └── Contents.json ├── Base.lproj │ ├── LaunchScreen.storyboard │ └── Main.storyboard ├── Info.plist ├── SceneDelegate.swift ├── ViewControllers │ ├── ScanViewController.swift │ └── ViewController.swift └── demo.json ├── README.md └── assets ├── ahap.png └── cover.png /.gitignore: -------------------------------------------------------------------------------- 1 | # Xcode 2 | .DS_Store 3 | */build/* 4 | *.pbxuser 5 | !default.pbxuser 6 | *.mode1v3 7 | !default.mode1v3 8 | *.mode2v3 9 | !default.mode2v3 10 | *.perspectivev3 11 | !default.perspectivev3 12 | xcuserdata 13 | profile 14 | *.moved-aside 15 | DerivedData 16 | .idea/ 17 | *.hmap 18 | *.xccheckout 19 | *.xcscmblueprint 20 | 21 | # Carthage 22 | Carthage/Build 23 | -------------------------------------------------------------------------------- /AHAP Tester.xcodeproj/project.pbxproj: -------------------------------------------------------------------------------- 1 | // !$*UTF8*$! 2 | { 3 | archiveVersion = 1; 4 | classes = { 5 | }; 6 | objectVersion = 50; 7 | objects = { 8 | 9 | /* Begin PBXBuildFile section */ 10 | 65C6A4CA22C379DE006ACFC2 /* ScanViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 65C6A4C922C379DE006ACFC2 /* ScanViewController.swift */; }; 11 | 65C6A4CE22C37BBC006ACFC2 /* AppStoryboards.swift in Sources */ = {isa = PBXBuildFile; fileRef = 65C6A4CD22C37BBC006ACFC2 /* AppStoryboards.swift */; }; 12 | 65DB981D22C3585E001CE26D /* AppDelegate.swift in Sources */ = {isa = PBXBuildFile; fileRef = 65DB981C22C3585E001CE26D /* AppDelegate.swift */; }; 13 | 65DB981F22C3585E001CE26D /* SceneDelegate.swift in Sources */ = {isa = PBXBuildFile; fileRef = 65DB981E22C3585E001CE26D /* SceneDelegate.swift */; }; 14 | 65DB982122C3585E001CE26D /* ViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 65DB982022C3585E001CE26D /* ViewController.swift */; }; 15 | 65DB982422C3585E001CE26D /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 65DB982222C3585E001CE26D /* Main.storyboard */; }; 16 | 65DB982622C3585F001CE26D /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 65DB982522C3585F001CE26D /* Assets.xcassets */; }; 17 | 65DB982922C3585F001CE26D /* LaunchScreen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 65DB982722C3585F001CE26D /* LaunchScreen.storyboard */; }; 18 | 65DB983122C35ADE001CE26D /* demo.json in Resources */ = {isa = PBXBuildFile; fileRef = 65DB983022C35ADE001CE26D /* demo.json */; }; 19 | /* End PBXBuildFile section */ 20 | 21 | /* Begin PBXFileReference section */ 22 | 65C6A4C922C379DE006ACFC2 /* ScanViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ScanViewController.swift; sourceTree = ""; }; 23 | 65C6A4CD22C37BBC006ACFC2 /* AppStoryboards.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AppStoryboards.swift; sourceTree = ""; }; 24 | 65DB981922C3585E001CE26D /* Moby.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = Moby.app; sourceTree = BUILT_PRODUCTS_DIR; }; 25 | 65DB981C22C3585E001CE26D /* AppDelegate.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AppDelegate.swift; sourceTree = ""; }; 26 | 65DB981E22C3585E001CE26D /* SceneDelegate.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = SceneDelegate.swift; sourceTree = ""; }; 27 | 65DB982022C3585E001CE26D /* ViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ViewController.swift; sourceTree = ""; }; 28 | 65DB982322C3585E001CE26D /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/Main.storyboard; sourceTree = ""; }; 29 | 65DB982522C3585F001CE26D /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = ""; }; 30 | 65DB982822C3585F001CE26D /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/LaunchScreen.storyboard; sourceTree = ""; }; 31 | 65DB982A22C3585F001CE26D /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; 32 | 65DB983022C35ADE001CE26D /* demo.json */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.json; path = demo.json; sourceTree = ""; }; 33 | /* End PBXFileReference section */ 34 | 35 | /* Begin PBXFrameworksBuildPhase section */ 36 | 65DB981622C3585E001CE26D /* Frameworks */ = { 37 | isa = PBXFrameworksBuildPhase; 38 | buildActionMask = 2147483647; 39 | files = ( 40 | ); 41 | runOnlyForDeploymentPostprocessing = 0; 42 | }; 43 | /* End PBXFrameworksBuildPhase section */ 44 | 45 | /* Begin PBXGroup section */ 46 | 65C6A4C722C37953006ACFC2 /* ViewControllers */ = { 47 | isa = PBXGroup; 48 | children = ( 49 | 65DB982022C3585E001CE26D /* ViewController.swift */, 50 | 65C6A4C922C379DE006ACFC2 /* ScanViewController.swift */, 51 | ); 52 | path = ViewControllers; 53 | sourceTree = ""; 54 | }; 55 | 65C6A4C822C3796E006ACFC2 /* Resources */ = { 56 | isa = PBXGroup; 57 | children = ( 58 | 65DB983022C35ADE001CE26D /* demo.json */, 59 | 65DB982222C3585E001CE26D /* Main.storyboard */, 60 | 65DB982522C3585F001CE26D /* Assets.xcassets */, 61 | 65DB982722C3585F001CE26D /* LaunchScreen.storyboard */, 62 | 65DB982A22C3585F001CE26D /* Info.plist */, 63 | ); 64 | name = Resources; 65 | sourceTree = ""; 66 | }; 67 | 65DB981022C3585E001CE26D = { 68 | isa = PBXGroup; 69 | children = ( 70 | 65DB981B22C3585E001CE26D /* AHAP Tester */, 71 | 65DB981A22C3585E001CE26D /* Products */, 72 | ); 73 | sourceTree = ""; 74 | }; 75 | 65DB981A22C3585E001CE26D /* Products */ = { 76 | isa = PBXGroup; 77 | children = ( 78 | 65DB981922C3585E001CE26D /* Moby.app */, 79 | ); 80 | name = Products; 81 | sourceTree = ""; 82 | }; 83 | 65DB981B22C3585E001CE26D /* AHAP Tester */ = { 84 | isa = PBXGroup; 85 | children = ( 86 | 65C6A4C822C3796E006ACFC2 /* Resources */, 87 | 65C6A4C722C37953006ACFC2 /* ViewControllers */, 88 | 65DB981C22C3585E001CE26D /* AppDelegate.swift */, 89 | 65DB981E22C3585E001CE26D /* SceneDelegate.swift */, 90 | 65C6A4CD22C37BBC006ACFC2 /* AppStoryboards.swift */, 91 | ); 92 | path = "AHAP Tester"; 93 | sourceTree = ""; 94 | }; 95 | /* End PBXGroup section */ 96 | 97 | /* Begin PBXNativeTarget section */ 98 | 65DB981822C3585E001CE26D /* AHAP Tester */ = { 99 | isa = PBXNativeTarget; 100 | buildConfigurationList = 65DB982D22C3585F001CE26D /* Build configuration list for PBXNativeTarget "AHAP Tester" */; 101 | buildPhases = ( 102 | 65DB981522C3585E001CE26D /* Sources */, 103 | 65DB981622C3585E001CE26D /* Frameworks */, 104 | 65DB981722C3585E001CE26D /* Resources */, 105 | ); 106 | buildRules = ( 107 | ); 108 | dependencies = ( 109 | ); 110 | name = "AHAP Tester"; 111 | productName = "AHAP Tester"; 112 | productReference = 65DB981922C3585E001CE26D /* Moby.app */; 113 | productType = "com.apple.product-type.application"; 114 | }; 115 | /* End PBXNativeTarget section */ 116 | 117 | /* Begin PBXProject section */ 118 | 65DB981122C3585E001CE26D /* Project object */ = { 119 | isa = PBXProject; 120 | attributes = { 121 | LastSwiftUpdateCheck = 1100; 122 | LastUpgradeCheck = 1100; 123 | ORGANIZATIONNAME = "Fancy Pixel"; 124 | TargetAttributes = { 125 | 65DB981822C3585E001CE26D = { 126 | CreatedOnToolsVersion = 11.0; 127 | }; 128 | }; 129 | }; 130 | buildConfigurationList = 65DB981422C3585E001CE26D /* Build configuration list for PBXProject "AHAP Tester" */; 131 | compatibilityVersion = "Xcode 9.3"; 132 | developmentRegion = en; 133 | hasScannedForEncodings = 0; 134 | knownRegions = ( 135 | en, 136 | Base, 137 | ); 138 | mainGroup = 65DB981022C3585E001CE26D; 139 | productRefGroup = 65DB981A22C3585E001CE26D /* Products */; 140 | projectDirPath = ""; 141 | projectRoot = ""; 142 | targets = ( 143 | 65DB981822C3585E001CE26D /* AHAP Tester */, 144 | ); 145 | }; 146 | /* End PBXProject section */ 147 | 148 | /* Begin PBXResourcesBuildPhase section */ 149 | 65DB981722C3585E001CE26D /* Resources */ = { 150 | isa = PBXResourcesBuildPhase; 151 | buildActionMask = 2147483647; 152 | files = ( 153 | 65DB982922C3585F001CE26D /* LaunchScreen.storyboard in Resources */, 154 | 65DB982622C3585F001CE26D /* Assets.xcassets in Resources */, 155 | 65DB983122C35ADE001CE26D /* demo.json in Resources */, 156 | 65DB982422C3585E001CE26D /* Main.storyboard in Resources */, 157 | ); 158 | runOnlyForDeploymentPostprocessing = 0; 159 | }; 160 | /* End PBXResourcesBuildPhase section */ 161 | 162 | /* Begin PBXSourcesBuildPhase section */ 163 | 65DB981522C3585E001CE26D /* Sources */ = { 164 | isa = PBXSourcesBuildPhase; 165 | buildActionMask = 2147483647; 166 | files = ( 167 | 65C6A4CE22C37BBC006ACFC2 /* AppStoryboards.swift in Sources */, 168 | 65DB982122C3585E001CE26D /* ViewController.swift in Sources */, 169 | 65DB981D22C3585E001CE26D /* AppDelegate.swift in Sources */, 170 | 65DB981F22C3585E001CE26D /* SceneDelegate.swift in Sources */, 171 | 65C6A4CA22C379DE006ACFC2 /* ScanViewController.swift in Sources */, 172 | ); 173 | runOnlyForDeploymentPostprocessing = 0; 174 | }; 175 | /* End PBXSourcesBuildPhase section */ 176 | 177 | /* Begin PBXVariantGroup section */ 178 | 65DB982222C3585E001CE26D /* Main.storyboard */ = { 179 | isa = PBXVariantGroup; 180 | children = ( 181 | 65DB982322C3585E001CE26D /* Base */, 182 | ); 183 | name = Main.storyboard; 184 | sourceTree = ""; 185 | }; 186 | 65DB982722C3585F001CE26D /* LaunchScreen.storyboard */ = { 187 | isa = PBXVariantGroup; 188 | children = ( 189 | 65DB982822C3585F001CE26D /* Base */, 190 | ); 191 | name = LaunchScreen.storyboard; 192 | sourceTree = ""; 193 | }; 194 | /* End PBXVariantGroup section */ 195 | 196 | /* Begin XCBuildConfiguration section */ 197 | 65DB982B22C3585F001CE26D /* Debug */ = { 198 | isa = XCBuildConfiguration; 199 | buildSettings = { 200 | ALWAYS_SEARCH_USER_PATHS = NO; 201 | CLANG_ANALYZER_NONNULL = YES; 202 | CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; 203 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; 204 | CLANG_CXX_LIBRARY = "libc++"; 205 | CLANG_ENABLE_MODULES = YES; 206 | CLANG_ENABLE_OBJC_ARC = YES; 207 | CLANG_ENABLE_OBJC_WEAK = YES; 208 | CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; 209 | CLANG_WARN_BOOL_CONVERSION = YES; 210 | CLANG_WARN_COMMA = YES; 211 | CLANG_WARN_CONSTANT_CONVERSION = YES; 212 | CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; 213 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; 214 | CLANG_WARN_DOCUMENTATION_COMMENTS = YES; 215 | CLANG_WARN_EMPTY_BODY = YES; 216 | CLANG_WARN_ENUM_CONVERSION = YES; 217 | CLANG_WARN_INFINITE_RECURSION = YES; 218 | CLANG_WARN_INT_CONVERSION = YES; 219 | CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; 220 | CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; 221 | CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; 222 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; 223 | CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; 224 | CLANG_WARN_STRICT_PROTOTYPES = YES; 225 | CLANG_WARN_SUSPICIOUS_MOVE = YES; 226 | CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; 227 | CLANG_WARN_UNREACHABLE_CODE = YES; 228 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; 229 | COPY_PHASE_STRIP = NO; 230 | DEBUG_INFORMATION_FORMAT = dwarf; 231 | ENABLE_STRICT_OBJC_MSGSEND = YES; 232 | ENABLE_TESTABILITY = YES; 233 | GCC_C_LANGUAGE_STANDARD = gnu11; 234 | GCC_DYNAMIC_NO_PIC = NO; 235 | GCC_NO_COMMON_BLOCKS = YES; 236 | GCC_OPTIMIZATION_LEVEL = 0; 237 | GCC_PREPROCESSOR_DEFINITIONS = ( 238 | "DEBUG=1", 239 | "$(inherited)", 240 | ); 241 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES; 242 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; 243 | GCC_WARN_UNDECLARED_SELECTOR = YES; 244 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; 245 | GCC_WARN_UNUSED_FUNCTION = YES; 246 | GCC_WARN_UNUSED_VARIABLE = YES; 247 | IPHONEOS_DEPLOYMENT_TARGET = 13.0; 248 | MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE; 249 | MTL_FAST_MATH = YES; 250 | ONLY_ACTIVE_ARCH = YES; 251 | SDKROOT = iphoneos; 252 | SWIFT_ACTIVE_COMPILATION_CONDITIONS = DEBUG; 253 | SWIFT_OPTIMIZATION_LEVEL = "-Onone"; 254 | }; 255 | name = Debug; 256 | }; 257 | 65DB982C22C3585F001CE26D /* Release */ = { 258 | isa = XCBuildConfiguration; 259 | buildSettings = { 260 | ALWAYS_SEARCH_USER_PATHS = NO; 261 | CLANG_ANALYZER_NONNULL = YES; 262 | CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; 263 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; 264 | CLANG_CXX_LIBRARY = "libc++"; 265 | CLANG_ENABLE_MODULES = YES; 266 | CLANG_ENABLE_OBJC_ARC = YES; 267 | CLANG_ENABLE_OBJC_WEAK = YES; 268 | CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; 269 | CLANG_WARN_BOOL_CONVERSION = YES; 270 | CLANG_WARN_COMMA = YES; 271 | CLANG_WARN_CONSTANT_CONVERSION = YES; 272 | CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; 273 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; 274 | CLANG_WARN_DOCUMENTATION_COMMENTS = YES; 275 | CLANG_WARN_EMPTY_BODY = YES; 276 | CLANG_WARN_ENUM_CONVERSION = YES; 277 | CLANG_WARN_INFINITE_RECURSION = YES; 278 | CLANG_WARN_INT_CONVERSION = YES; 279 | CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; 280 | CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; 281 | CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; 282 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; 283 | CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; 284 | CLANG_WARN_STRICT_PROTOTYPES = YES; 285 | CLANG_WARN_SUSPICIOUS_MOVE = YES; 286 | CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; 287 | CLANG_WARN_UNREACHABLE_CODE = YES; 288 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; 289 | COPY_PHASE_STRIP = NO; 290 | DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; 291 | ENABLE_NS_ASSERTIONS = NO; 292 | ENABLE_STRICT_OBJC_MSGSEND = YES; 293 | GCC_C_LANGUAGE_STANDARD = gnu11; 294 | GCC_NO_COMMON_BLOCKS = YES; 295 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES; 296 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; 297 | GCC_WARN_UNDECLARED_SELECTOR = YES; 298 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; 299 | GCC_WARN_UNUSED_FUNCTION = YES; 300 | GCC_WARN_UNUSED_VARIABLE = YES; 301 | IPHONEOS_DEPLOYMENT_TARGET = 13.0; 302 | MTL_ENABLE_DEBUG_INFO = NO; 303 | MTL_FAST_MATH = YES; 304 | SDKROOT = iphoneos; 305 | SWIFT_COMPILATION_MODE = wholemodule; 306 | SWIFT_OPTIMIZATION_LEVEL = "-O"; 307 | VALIDATE_PRODUCT = YES; 308 | }; 309 | name = Release; 310 | }; 311 | 65DB982E22C3585F001CE26D /* Debug */ = { 312 | isa = XCBuildConfiguration; 313 | buildSettings = { 314 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; 315 | CODE_SIGN_STYLE = Automatic; 316 | DEVELOPMENT_TEAM = H72GR44F4M; 317 | INFOPLIST_FILE = "AHAP Tester/Info.plist"; 318 | LD_RUNPATH_SEARCH_PATHS = ( 319 | "$(inherited)", 320 | "@executable_path/Frameworks", 321 | ); 322 | PRODUCT_BUNDLE_IDENTIFIER = "it.fancypixel.AHAP-Tester"; 323 | PRODUCT_NAME = Moby; 324 | SWIFT_VERSION = 5.0; 325 | TARGETED_DEVICE_FAMILY = 1; 326 | }; 327 | name = Debug; 328 | }; 329 | 65DB982F22C3585F001CE26D /* Release */ = { 330 | isa = XCBuildConfiguration; 331 | buildSettings = { 332 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; 333 | CODE_SIGN_STYLE = Automatic; 334 | DEVELOPMENT_TEAM = H72GR44F4M; 335 | INFOPLIST_FILE = "AHAP Tester/Info.plist"; 336 | LD_RUNPATH_SEARCH_PATHS = ( 337 | "$(inherited)", 338 | "@executable_path/Frameworks", 339 | ); 340 | PRODUCT_BUNDLE_IDENTIFIER = "it.fancypixel.AHAP-Tester"; 341 | PRODUCT_NAME = Moby; 342 | SWIFT_VERSION = 5.0; 343 | TARGETED_DEVICE_FAMILY = 1; 344 | }; 345 | name = Release; 346 | }; 347 | /* End XCBuildConfiguration section */ 348 | 349 | /* Begin XCConfigurationList section */ 350 | 65DB981422C3585E001CE26D /* Build configuration list for PBXProject "AHAP Tester" */ = { 351 | isa = XCConfigurationList; 352 | buildConfigurations = ( 353 | 65DB982B22C3585F001CE26D /* Debug */, 354 | 65DB982C22C3585F001CE26D /* Release */, 355 | ); 356 | defaultConfigurationIsVisible = 0; 357 | defaultConfigurationName = Release; 358 | }; 359 | 65DB982D22C3585F001CE26D /* Build configuration list for PBXNativeTarget "AHAP Tester" */ = { 360 | isa = XCConfigurationList; 361 | buildConfigurations = ( 362 | 65DB982E22C3585F001CE26D /* Debug */, 363 | 65DB982F22C3585F001CE26D /* Release */, 364 | ); 365 | defaultConfigurationIsVisible = 0; 366 | defaultConfigurationName = Release; 367 | }; 368 | /* End XCConfigurationList section */ 369 | }; 370 | rootObject = 65DB981122C3585E001CE26D /* Project object */; 371 | } 372 | -------------------------------------------------------------------------------- /AHAP Tester.xcodeproj/project.xcworkspace/contents.xcworkspacedata: -------------------------------------------------------------------------------- 1 | 2 | 4 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /AHAP Tester.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | IDEDidComputeMac32BitWarning 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /AHAP Tester/AppDelegate.swift: -------------------------------------------------------------------------------- 1 | // 2 | // AppDelegate.swift 3 | // AHAP Tester 4 | // 5 | // Created by Andrea Mazzini on 26/06/2019. 6 | // Copyright © 2019 Fancy Pixel. All rights reserved. 7 | // 8 | 9 | import UIKit 10 | 11 | @UIApplicationMain 12 | class AppDelegate: UIResponder, UIApplicationDelegate { 13 | func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]?) -> Bool { 14 | return true 15 | } 16 | } 17 | 18 | -------------------------------------------------------------------------------- /AHAP Tester/AppStoryboards.swift: -------------------------------------------------------------------------------- 1 | // 2 | // AppStoryboards.swift 3 | // AHAP Tester 4 | // 5 | // Created by Andrea Mazzini on 26/06/2019. 6 | // Copyright © 2019 Fancy Pixel. All rights reserved. 7 | // 8 | 9 | import Foundation 10 | import UIKit 11 | 12 | enum AppStoryboard : String { 13 | case Main 14 | 15 | var instance : UIStoryboard { 16 | return UIStoryboard(name: self.rawValue, bundle: Bundle.main) 17 | } 18 | 19 | func viewController(viewControllerClass : T.Type, function : String = #function, line : Int = #line, file : String = #file) -> T { 20 | let storyboardID = (viewControllerClass as UIViewController.Type).storyboardID 21 | guard let scene = instance.instantiateViewController(withIdentifier: storyboardID) as? T else { 22 | fatalError("ViewController with identifier \(storyboardID), not found in \(self.rawValue) Storyboard.\nFile : \(file) \nLine Number : \(line) \nFunction : \(function)") 23 | } 24 | 25 | return scene 26 | } 27 | 28 | func initialViewController() -> UIViewController? { 29 | return instance.instantiateInitialViewController() 30 | } 31 | } 32 | 33 | extension UIViewController { 34 | class var storyboardID : String { 35 | return "\(self)" 36 | } 37 | 38 | static func instantiate(fromAppStoryboard appStoryboard: AppStoryboard) -> Self { 39 | return appStoryboard.viewController(viewControllerClass: self) 40 | } 41 | } 42 | -------------------------------------------------------------------------------- /AHAP Tester/Assets.xcassets/AppIcon.appiconset/AppIcon-1024.0x1024.0@1x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/FancyPixel/moby/bd471894433e7dbe05241c4ec6fc3894ed7f4558/AHAP Tester/Assets.xcassets/AppIcon.appiconset/AppIcon-1024.0x1024.0@1x.png -------------------------------------------------------------------------------- /AHAP Tester/Assets.xcassets/AppIcon.appiconset/AppIcon-20.0x20.0@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/FancyPixel/moby/bd471894433e7dbe05241c4ec6fc3894ed7f4558/AHAP Tester/Assets.xcassets/AppIcon.appiconset/AppIcon-20.0x20.0@2x.png -------------------------------------------------------------------------------- /AHAP Tester/Assets.xcassets/AppIcon.appiconset/AppIcon-20.0x20.0@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/FancyPixel/moby/bd471894433e7dbe05241c4ec6fc3894ed7f4558/AHAP Tester/Assets.xcassets/AppIcon.appiconset/AppIcon-20.0x20.0@3x.png -------------------------------------------------------------------------------- /AHAP Tester/Assets.xcassets/AppIcon.appiconset/AppIcon-29.0x29.0@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/FancyPixel/moby/bd471894433e7dbe05241c4ec6fc3894ed7f4558/AHAP Tester/Assets.xcassets/AppIcon.appiconset/AppIcon-29.0x29.0@2x.png -------------------------------------------------------------------------------- /AHAP Tester/Assets.xcassets/AppIcon.appiconset/AppIcon-29.0x29.0@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/FancyPixel/moby/bd471894433e7dbe05241c4ec6fc3894ed7f4558/AHAP Tester/Assets.xcassets/AppIcon.appiconset/AppIcon-29.0x29.0@3x.png -------------------------------------------------------------------------------- /AHAP Tester/Assets.xcassets/AppIcon.appiconset/AppIcon-40.0x40.0@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/FancyPixel/moby/bd471894433e7dbe05241c4ec6fc3894ed7f4558/AHAP Tester/Assets.xcassets/AppIcon.appiconset/AppIcon-40.0x40.0@2x.png -------------------------------------------------------------------------------- /AHAP Tester/Assets.xcassets/AppIcon.appiconset/AppIcon-40.0x40.0@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/FancyPixel/moby/bd471894433e7dbe05241c4ec6fc3894ed7f4558/AHAP Tester/Assets.xcassets/AppIcon.appiconset/AppIcon-40.0x40.0@3x.png -------------------------------------------------------------------------------- /AHAP Tester/Assets.xcassets/AppIcon.appiconset/AppIcon-60.0x60.0@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/FancyPixel/moby/bd471894433e7dbe05241c4ec6fc3894ed7f4558/AHAP Tester/Assets.xcassets/AppIcon.appiconset/AppIcon-60.0x60.0@2x.png -------------------------------------------------------------------------------- /AHAP Tester/Assets.xcassets/AppIcon.appiconset/AppIcon-60.0x60.0@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/FancyPixel/moby/bd471894433e7dbe05241c4ec6fc3894ed7f4558/AHAP Tester/Assets.xcassets/AppIcon.appiconset/AppIcon-60.0x60.0@3x.png -------------------------------------------------------------------------------- /AHAP Tester/Assets.xcassets/AppIcon.appiconset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "info" : { 3 | "author" : "appicon", 4 | "version" : 1 5 | }, 6 | "images" : [ 7 | { 8 | "size" : "20x20", 9 | "filename" : "AppIcon-20.0x20.0@2x.png", 10 | "idiom" : "iphone", 11 | "scale" : "2x" 12 | }, 13 | { 14 | "size" : "20x20", 15 | "filename" : "AppIcon-20.0x20.0@3x.png", 16 | "idiom" : "iphone", 17 | "scale" : "3x" 18 | }, 19 | { 20 | "size" : "29x29", 21 | "filename" : "AppIcon-29.0x29.0@2x.png", 22 | "idiom" : "iphone", 23 | "scale" : "2x" 24 | }, 25 | { 26 | "size" : "29x29", 27 | "filename" : "AppIcon-29.0x29.0@3x.png", 28 | "idiom" : "iphone", 29 | "scale" : "3x" 30 | }, 31 | { 32 | "size" : "40x40", 33 | "filename" : "AppIcon-40.0x40.0@2x.png", 34 | "idiom" : "iphone", 35 | "scale" : "2x" 36 | }, 37 | { 38 | "size" : "40x40", 39 | "filename" : "AppIcon-40.0x40.0@3x.png", 40 | "idiom" : "iphone", 41 | "scale" : "3x" 42 | }, 43 | { 44 | "size" : "60x60", 45 | "filename" : "AppIcon-60.0x60.0@2x.png", 46 | "idiom" : "iphone", 47 | "scale" : "2x" 48 | }, 49 | { 50 | "size" : "60x60", 51 | "filename" : "AppIcon-60.0x60.0@3x.png", 52 | "idiom" : "iphone", 53 | "scale" : "3x" 54 | }, 55 | { 56 | "size" : "1024x1024", 57 | "filename" : "AppIcon-1024.0x1024.0@1x.png", 58 | "idiom" : "ios-marketing", 59 | "scale" : "1x" 60 | } 61 | ] 62 | } -------------------------------------------------------------------------------- /AHAP Tester/Assets.xcassets/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "info" : { 3 | "version" : 1, 4 | "author" : "xcode" 5 | } 6 | } -------------------------------------------------------------------------------- /AHAP Tester/Assets.xcassets/MainTint.colorset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "info" : { 3 | "version" : 1, 4 | "author" : "xcode" 5 | }, 6 | "colors" : [ 7 | { 8 | "idiom" : "iphone", 9 | "color" : { 10 | "color-space" : "srgb", 11 | "components" : { 12 | "red" : "0x28", 13 | "alpha" : "1.000", 14 | "blue" : "0xA6", 15 | "green" : "0x62" 16 | } 17 | } 18 | }, 19 | { 20 | "idiom" : "iphone", 21 | "appearances" : [ 22 | { 23 | "appearance" : "luminosity", 24 | "value" : "dark" 25 | } 26 | ], 27 | "color" : { 28 | "color-space" : "srgb", 29 | "components" : { 30 | "red" : "0x31", 31 | "alpha" : "1.000", 32 | "blue" : "0xCF", 33 | "green" : "0x7B" 34 | } 35 | } 36 | } 37 | ] 38 | } -------------------------------------------------------------------------------- /AHAP Tester/Assets.xcassets/lines.imageset/Artboard Copy.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/FancyPixel/moby/bd471894433e7dbe05241c4ec6fc3894ed7f4558/AHAP Tester/Assets.xcassets/lines.imageset/Artboard Copy.pdf -------------------------------------------------------------------------------- /AHAP Tester/Assets.xcassets/lines.imageset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "idiom" : "universal", 5 | "filename" : "Artboard Copy.pdf" 6 | } 7 | ], 8 | "info" : { 9 | "version" : 1, 10 | "author" : "xcode" 11 | } 12 | } -------------------------------------------------------------------------------- /AHAP Tester/Base.lproj/LaunchScreen.storyboard: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | -------------------------------------------------------------------------------- /AHAP Tester/Base.lproj/Main.storyboard: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 42 | 48 | 67 | 68 | 69 | 70 | 71 | 72 | 73 | 74 | 75 | 76 | 77 | 78 | 79 | 80 | 81 | 94 | 95 | 96 | 97 | 98 | 99 | 100 | 101 | 102 | 103 | 104 | 105 | 106 | 110 | 121 | 127 | 128 | 129 | 130 | 131 | 132 | 133 | 134 | 135 | 136 | 137 | 138 | 139 | 140 | 141 | 142 | 143 | 144 | 145 | 146 | 147 | 148 | 149 | 150 | 151 | 152 | 153 | 154 | 155 | 156 | 157 | 158 | 159 | 160 | 161 | 162 | 163 | 164 | 165 | 166 | 167 | 168 | 169 | 170 | 171 | 172 | 173 | 174 | 175 | 176 | 177 | 178 | 179 | 180 | 181 | 182 | 183 | 184 | 185 | 186 | 187 | 188 | 189 | 190 | -------------------------------------------------------------------------------- /AHAP Tester/Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | NSAppTransportSecurity 6 | 7 | NSAllowsArbitraryLoads 8 | 9 | 10 | CFBundleDevelopmentRegion 11 | $(DEVELOPMENT_LANGUAGE) 12 | CFBundleExecutable 13 | $(EXECUTABLE_NAME) 14 | CFBundleIdentifier 15 | $(PRODUCT_BUNDLE_IDENTIFIER) 16 | CFBundleInfoDictionaryVersion 17 | 6.0 18 | CFBundleName 19 | $(PRODUCT_NAME) 20 | CFBundlePackageType 21 | $(PRODUCT_BUNDLE_PACKAGE_TYPE) 22 | CFBundleShortVersionString 23 | 1.0 24 | CFBundleVersion 25 | 1 26 | LSRequiresIPhoneOS 27 | 28 | NSCameraUsageDescription 29 | This app uses the camera to scan QR codes 30 | UIApplicationSceneManifest 31 | 32 | UIApplicationSupportsMultipleScenes 33 | 34 | UISceneConfigurations 35 | 36 | UIWindowSceneSessionRoleApplication 37 | 38 | 39 | UILaunchStoryboardName 40 | LaunchScreen 41 | UISceneConfigurationName 42 | Default Configuration 43 | UISceneDelegateClassName 44 | $(PRODUCT_MODULE_NAME).SceneDelegate 45 | UISceneStoryboardFile 46 | Main 47 | 48 | 49 | 50 | 51 | UILaunchStoryboardName 52 | LaunchScreen 53 | UIMainStoryboardFile 54 | Main 55 | UIRequiredDeviceCapabilities 56 | 57 | armv7 58 | 59 | UISupportedInterfaceOrientations 60 | 61 | UIInterfaceOrientationPortrait 62 | 63 | UISupportedInterfaceOrientations~ipad 64 | 65 | UIInterfaceOrientationPortrait 66 | UIInterfaceOrientationPortraitUpsideDown 67 | UIInterfaceOrientationLandscapeLeft 68 | UIInterfaceOrientationLandscapeRight 69 | 70 | 71 | 72 | -------------------------------------------------------------------------------- /AHAP Tester/SceneDelegate.swift: -------------------------------------------------------------------------------- 1 | // 2 | // SceneDelegate.swift 3 | // AHAP Tester 4 | // 5 | // Created by Andrea Mazzini on 26/06/2019. 6 | // Copyright © 2019 Fancy Pixel. All rights reserved. 7 | // 8 | 9 | import UIKit 10 | 11 | class SceneDelegate: UIResponder, UIWindowSceneDelegate { 12 | var window: UIWindow? 13 | } 14 | 15 | -------------------------------------------------------------------------------- /AHAP Tester/ViewControllers/ScanViewController.swift: -------------------------------------------------------------------------------- 1 | // 2 | // ScanViewController.swift 3 | // AHAP Tester 4 | // 5 | // Created by Andrea Mazzini on 26/06/2019. 6 | // Copyright © 2019 Fancy Pixel. All rights reserved. 7 | // 8 | 9 | import UIKit 10 | import AVFoundation 11 | 12 | protocol ScanViewControllerDelegate: class { 13 | func scanViewController(_ controller: ScanViewController, didScan code: String) 14 | } 15 | 16 | class ScanViewController: UIViewController { 17 | private var captureSession = AVCaptureSession() 18 | private var videoPreviewLayer: AVCaptureVideoPreviewLayer? 19 | var delegate: ScanViewControllerDelegate? 20 | 21 | override func viewDidLoad() { 22 | super.viewDidLoad() 23 | 24 | let deviceDiscoverySession = AVCaptureDevice.DiscoverySession(deviceTypes: [.builtInDualCamera], mediaType: AVMediaType.video, position: .back) 25 | 26 | guard let captureDevice = deviceDiscoverySession.devices.first else { 27 | print("Failed to get the camera device") 28 | dismiss(animated: true, completion: nil) 29 | return 30 | } 31 | 32 | do { 33 | let input = try AVCaptureDeviceInput(device: captureDevice) 34 | captureSession.addInput(input) 35 | let captureMetadataOutput = AVCaptureMetadataOutput() 36 | captureSession.addOutput(captureMetadataOutput) 37 | captureMetadataOutput.setMetadataObjectsDelegate(self, queue: DispatchQueue.main) 38 | captureMetadataOutput.metadataObjectTypes = [AVMetadataObject.ObjectType.qr] 39 | } catch { 40 | print(error) 41 | dismiss(animated: true, completion: nil) 42 | return 43 | } 44 | 45 | videoPreviewLayer = AVCaptureVideoPreviewLayer(session: captureSession) 46 | videoPreviewLayer?.videoGravity = AVLayerVideoGravity.resizeAspectFill 47 | videoPreviewLayer?.frame = view.layer.bounds 48 | view.layer.addSublayer(videoPreviewLayer!) 49 | 50 | captureSession.startRunning() 51 | } 52 | } 53 | 54 | extension ScanViewController: AVCaptureMetadataOutputObjectsDelegate { 55 | func metadataOutput(_ output: AVCaptureMetadataOutput, didOutput metadataObjects: [AVMetadataObject], from connection: AVCaptureConnection) { 56 | if metadataObjects.count == 0 { 57 | return 58 | } 59 | 60 | let metadataObj = metadataObjects[0] as! AVMetadataMachineReadableCodeObject 61 | 62 | if metadataObj.type == AVMetadataObject.ObjectType.qr { 63 | if let code = metadataObj.stringValue { 64 | delegate?.scanViewController(self, didScan: code) 65 | captureSession.stopRunning() 66 | dismiss(animated: true, completion: nil) 67 | } 68 | } 69 | } 70 | } 71 | -------------------------------------------------------------------------------- /AHAP Tester/ViewControllers/ViewController.swift: -------------------------------------------------------------------------------- 1 | // 2 | // ViewController.swift 3 | // AHAP Tester 4 | // 5 | // Created by Andrea Mazzini on 26/06/2019. 6 | // Copyright © 2019 Fancy Pixel. All rights reserved. 7 | // 8 | 9 | import UIKit 10 | import CoreHaptics 11 | import AVFoundation 12 | import Combine 13 | 14 | class ViewController: UIViewController { 15 | @IBOutlet private var loadButton: UIButton! 16 | @IBOutlet private var playButton: UIButton! 17 | @IBOutlet private var textField: UITextField! 18 | @IBOutlet private var stateLabel: UILabel! 19 | @IBOutlet private var activityIndicator: UIActivityIndicatorView! 20 | 21 | private var engine: CHHapticEngine? 22 | private var isEngineRunning: Bool = false 23 | private var hapticData: Data? { 24 | didSet { 25 | playButton.alpha = hapticData != nil ? 1 : 0.8 26 | playButton.isEnabled = hapticData != nil 27 | stateLabel.text = hapticData != nil ? "HAPTIC READY" : "NO HAPTIC LOADED" 28 | } 29 | } 30 | private var fetching = false { 31 | didSet { 32 | if fetching { 33 | loadButton.setTitle("", for: .normal) 34 | activityIndicator.startAnimating() 35 | } else { 36 | loadButton.setTitle("LOAD AHAP", for: .normal) 37 | activityIndicator.stopAnimating() 38 | } 39 | } 40 | } 41 | 42 | override func viewDidLoad() { 43 | super.viewDidLoad() 44 | 45 | engine = try? CHHapticEngine() 46 | engine?.stoppedHandler = { [weak self] reason in 47 | print("Stopped for reason: \(reason.rawValue)") 48 | self?.isEngineRunning = false 49 | } 50 | do { 51 | try engine?.start() 52 | isEngineRunning = true 53 | } catch let error { 54 | fatalError("Unable to start: \(error)") 55 | } 56 | 57 | hapticData = nil 58 | } 59 | 60 | @IBAction func loadDemo() { 61 | hapticData = try! Data(contentsOf: Bundle.main.url(forResource: "demo", withExtension: "json")!) 62 | } 63 | 64 | @IBAction func playHaptic() { 65 | guard let hapticData = hapticData else { return } 66 | 67 | try? engine?.playPattern(from: hapticData) 68 | } 69 | 70 | @IBAction func loadHaptic() { 71 | guard let url = URL(string: textField.text ?? ""), !fetching else { return } 72 | 73 | textField.resignFirstResponder() 74 | fetching = true 75 | DispatchQueue(label: "load").async { 76 | do { 77 | let data = try Data(contentsOf: url) 78 | DispatchQueue.main.async { 79 | self.hapticData = data 80 | self.fetching = false 81 | } 82 | } catch let error { 83 | print("Unable to load file: \(error)") 84 | } 85 | } 86 | } 87 | 88 | @IBAction func scanQR() { 89 | let controller = ScanViewController.instantiate(fromAppStoryboard: .Main) 90 | controller.delegate = self 91 | present(controller, animated: true, completion: nil) 92 | } 93 | 94 | override func touchesEnded(_ touches: Set, with event: UIEvent?) { 95 | textField.resignFirstResponder() 96 | } 97 | } 98 | 99 | extension ViewController: ScanViewControllerDelegate { 100 | func scanViewController(_ controller: ScanViewController, didScan code: String) { 101 | textField.text = code 102 | } 103 | } 104 | -------------------------------------------------------------------------------- /AHAP Tester/demo.json: -------------------------------------------------------------------------------- 1 | {"Pattern":[{"Event":{"Time":0.126232741617357,"EventType":"HapticTransient","EventParameters":[{"ParameterID":"HapticIntensity","ParameterValue":0.3411764705882353},{"ParameterID":"HapticSharpness","ParameterValue":0.3411764705882353}]}},{"Event":{"Time":0.252465483234714,"EventType":"HapticTransient","EventParameters":[{"ParameterID":"HapticIntensity","ParameterValue":0.6058823529411764},{"ParameterID":"HapticSharpness","ParameterValue":0.6058823529411764}]}},{"Event":{"Time":0.37606837606837606,"EventType":"HapticTransient","EventParameters":[{"ParameterID":"HapticIntensity","ParameterValue":0.9058823529411765},{"ParameterID":"HapticSharpness","ParameterValue":0.9058823529411765}]}},{"Event":{"Time":0.5003287310979618,"EventType":"HapticContinuous","EventDuration":0.24983563445101908,"EventParameters":[{"ParameterID":"HapticIntensity","ParameterValue":0.3235294117647059},{"ParameterID":"HapticSharpness","ParameterValue":0.3235294117647059}]}},{"Event":{"Time":0.8173570019723867,"EventType":"HapticTransient","EventParameters":[{"ParameterID":"HapticIntensity","ParameterValue":0.9764705882352941},{"ParameterID":"HapticSharpness","ParameterValue":0.9764705882352941}]}},{"Event":{"Time":0.8366863905325443,"EventType":"HapticTransient","EventParameters":[{"ParameterID":"HapticIntensity","ParameterValue":0.8529411764705882},{"ParameterID":"HapticSharpness","ParameterValue":0.8529411764705882}]}},{"Event":{"Time":0.8560157790927022,"EventType":"HapticTransient","EventParameters":[{"ParameterID":"HapticIntensity","ParameterValue":0.7058823529411765},{"ParameterID":"HapticSharpness","ParameterValue":0.7058823529411765}]}},{"Event":{"Time":0.8781065088757397,"EventType":"HapticTransient","EventParameters":[{"ParameterID":"HapticIntensity","ParameterValue":0.5705882352941176},{"ParameterID":"HapticSharpness","ParameterValue":0.5705882352941176}]}},{"Event":{"Time":0.9001972386587772,"EventType":"HapticTransient","EventParameters":[{"ParameterID":"HapticIntensity","ParameterValue":0.47058823529411764},{"ParameterID":"HapticSharpness","ParameterValue":0.47058823529411764}]}},{"Event":{"Time":0.9222879684418146,"EventType":"HapticTransient","EventParameters":[{"ParameterID":"HapticIntensity","ParameterValue":0.3588235294117647},{"ParameterID":"HapticSharpness","ParameterValue":0.3588235294117647}]}},{"Event":{"Time":0.9443786982248522,"EventType":"HapticTransient","EventParameters":[{"ParameterID":"HapticIntensity","ParameterValue":0.2529411764705882},{"ParameterID":"HapticSharpness","ParameterValue":0.2529411764705882}]}},{"Event":{"Time":0.9664694280078896,"EventType":"HapticTransient","EventParameters":[{"ParameterID":"HapticIntensity","ParameterValue":0.15294117647058825},{"ParameterID":"HapticSharpness","ParameterValue":0.15294117647058825}]}},{"Event":{"Time":0.988560157790927,"EventType":"HapticTransient","EventParameters":[{"ParameterID":"HapticIntensity","ParameterValue":0.07058823529411765},{"ParameterID":"HapticSharpness","ParameterValue":0.07058823529411765}]}}]} -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 |

2 | 3 |

4 | 5 | ![Swift 5.1](https://img.shields.io/badge/swift-5.1-orange.svg) 6 | 7 | Moby is a simple app that lets you download and test AHAP (Apple Haptic and Audio Pattern) files. 8 | Please note that Core Haptics is only available in iOS 13, so make sure to run this with Xcode 11. 9 | 10 | # How to design AHAP files 11 | 12 | You can use our [Captain AHAP](http://ahap.fancypixel.it/) web app to design your own haptic files graphically: 13 | 14 |

15 | 16 |

17 | 18 | ## Usage 19 | 20 | Build and run on a device running iOS 13 to feel the haptics. 21 | 22 | # Author 23 | Built by [Fancy Pixel](https://fancypixel.it). We're available for hire, feel free to contact us! 24 | 25 | # MIT License 26 | The MIT License (MIT) 27 | 28 | Copyright (c) 2019 Fancy Pixel S.r.l. 29 | 30 | Permission is hereby granted, free of charge, to any person obtaining a copy of 31 | this software and associated documentation files (the "Software"), to deal in 32 | the Software without restriction, including without limitation the rights to 33 | use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of 34 | the Software, and to permit persons to whom the Software is furnished to do so, 35 | subject to the following conditions: 36 | 37 | The above copyright notice and this permission notice shall be included in all 38 | copies or substantial portions of the Software. 39 | 40 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 41 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 42 | FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 43 | COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 44 | IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 45 | CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 46 | -------------------------------------------------------------------------------- /assets/ahap.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/FancyPixel/moby/bd471894433e7dbe05241c4ec6fc3894ed7f4558/assets/ahap.png -------------------------------------------------------------------------------- /assets/cover.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/FancyPixel/moby/bd471894433e7dbe05241c4ec6fc3894ed7f4558/assets/cover.png --------------------------------------------------------------------------------