diff options
Diffstat (limited to 'libs/ihealth-sdk/ios/ReactNativeIOSLibrary/Communication_SDK/Headers/HSMacroFile.h')
| -rw-r--r-- | libs/ihealth-sdk/ios/ReactNativeIOSLibrary/Communication_SDK/Headers/HSMacroFile.h | 709 |
1 files changed, 709 insertions, 0 deletions
diff --git a/libs/ihealth-sdk/ios/ReactNativeIOSLibrary/Communication_SDK/Headers/HSMacroFile.h b/libs/ihealth-sdk/ios/ReactNativeIOSLibrary/Communication_SDK/Headers/HSMacroFile.h new file mode 100644 index 0000000..fc3e117 --- /dev/null +++ b/libs/ihealth-sdk/ios/ReactNativeIOSLibrary/Communication_SDK/Headers/HSMacroFile.h | |||
| @@ -0,0 +1,709 @@ | |||
| 1 | // | ||
| 2 | // HSMacroFile.h | ||
| 3 | // HSDemoCode | ||
| 4 | // | ||
| 5 | // Created by zhiwei jing on 14-7-23. | ||
| 6 | // Copyright (c) 2014年 zhiwei jing. All rights reserved. | ||
| 7 | // | ||
| 8 | |||
| 9 | #import "HealthUser.h" | ||
| 10 | |||
| 11 | #ifndef HSDemoCode_HSMacroFile_h | ||
| 12 | #define HSDemoCode_HSMacroFile_h | ||
| 13 | |||
| 14 | #define RecordLength 16 | ||
| 15 | |||
| 16 | |||
| 17 | |||
| 18 | /** | ||
| 19 | HS2 Device Error Code | ||
| 20 | */ | ||
| 21 | typedef NS_ENUM(NSInteger,HS2DeviceError){ | ||
| 22 | /// Battery level is low | ||
| 23 | HS2DeviceLowPower = 1, | ||
| 24 | /// The Scale failed to initialize | ||
| 25 | HS2DeviceEr0 = 2, | ||
| 26 | /// Maximum weight has been exceeded | ||
| 27 | HS2DeviceEr1 = 3, | ||
| 28 | /// The Scale can't capture a steady reading | ||
| 29 | HS2DeviceEr2 = 4, | ||
| 30 | /// Bluetooth connection error | ||
| 31 | HS2DeviceEr4 = 5, | ||
| 32 | /// Movement while measuring | ||
| 33 | HS2DeviceEr7 = 6, | ||
| 34 | ///Invalidate | ||
| 35 | HS2DeviceEr8 = 7, | ||
| 36 | /// Scale memory access error | ||
| 37 | HS2DeviceEr9 = 8, | ||
| 38 | /// No memory 9 | ||
| 39 | HS2DataZeor = 9, | ||
| 40 | ///Device disconnect | ||
| 41 | HS2DeviceDisconnect = 10, | ||
| 42 | /// Communication error | ||
| 43 | HS2DeviceSendTimeout = 11, | ||
| 44 | /// DeviceRecWeightError | ||
| 45 | HS2DeviceRecWeightError = 12, | ||
| 46 | }; | ||
| 47 | /** | ||
| 48 | HS2S Device Error Code | ||
| 49 | */ | ||
| 50 | typedef NS_ENUM(int, HS2SDeviceError) { | ||
| 51 | HS2SDeviceError_Unknown = -1,// device send wrong error code | ||
| 52 | HS2SDeviceError_CommunicationTimeout = 0, | ||
| 53 | HS2SDeviceError_ReceivedCommandError, | ||
| 54 | HS2SDeviceError_InputParameterError, | ||
| 55 | HS2SDeviceError_MoreThanMaxNumbersOfUser, | ||
| 56 | HS2SDeviceError_WriteFlashError, | ||
| 57 | HS2SDeviceError_UserNotExist, | ||
| 58 | HS2SDeviceError_StartMeasureError, | ||
| 59 | HS2SDeviceError_MeasureTimeout, | ||
| 60 | HS2SDeviceError_MeasureOverweight, | ||
| 61 | HS2SDeviceError_Disconnect, | ||
| 62 | HS2SDeviceError_Unsupported, | ||
| 63 | }; | ||
| 64 | |||
| 65 | |||
| 66 | /** | ||
| 67 | HS3 Device Error Code | ||
| 68 | */ | ||
| 69 | typedef NS_ENUM(NSInteger,HS3DeviceError){ | ||
| 70 | /// Low battery | ||
| 71 | HS3DeviceLowPower = 1, | ||
| 72 | /// Weight capacity is exceeded | ||
| 73 | HS3DeviceEr2 = 2, | ||
| 74 | /// The Scale calibration error | ||
| 75 | HS3DeviceEr4 = 3, | ||
| 76 | /// Movement while measuring | ||
| 77 | HS3DeviceEr7 = 4, | ||
| 78 | /// No memory | ||
| 79 | HS3DataZeor = 5, //No memory | ||
| 80 | /// Device disconnect | ||
| 81 | HS3DeviceDisconnect = 6, | ||
| 82 | /// Communication error | ||
| 83 | HS3DeviceSendTimeout = 7, | ||
| 84 | }; | ||
| 85 | |||
| 86 | |||
| 87 | /** | ||
| 88 | HS4 Device Error Code | ||
| 89 | */ | ||
| 90 | typedef NS_ENUM(NSInteger,HS4DeviceError){ | ||
| 91 | /// Battery level is low | ||
| 92 | HS4DeviceLowPower = 1, // Battery level is low | ||
| 93 | /// The Scale failed to initialize | ||
| 94 | HS4DeviceEr0 = 2, | ||
| 95 | /// Maximum weight has been exceeded | ||
| 96 | HS4DeviceEr1 = 3, | ||
| 97 | /// The Scale can't capture a steady reading | ||
| 98 | HS4DeviceEr2 = 4, | ||
| 99 | /// Bluetooth connection error | ||
| 100 | HS4DeviceEr4 = 5, | ||
| 101 | /// Movement while measuring | ||
| 102 | HS4DeviceEr7 = 6, | ||
| 103 | /// Invalidate | ||
| 104 | HS4DeviceEr8 = 7, | ||
| 105 | /// Scale memory access error | ||
| 106 | HS4DeviceEr9 = 8, | ||
| 107 | /// No memory | ||
| 108 | HS4DataZeor = 9 , | ||
| 109 | /// Device disconnect | ||
| 110 | HS4DeviceDisconnect = 10, | ||
| 111 | /// Communication error | ||
| 112 | HS4DeviceSendTimeout = 11, // Communication error | ||
| 113 | /// Device Recive Weight Error | ||
| 114 | HS4DeviceRecWeightError = 12, | ||
| 115 | }; | ||
| 116 | |||
| 117 | /** | ||
| 118 | HS5 error | ||
| 119 | */ | ||
| 120 | typedef NS_ENUM(NSInteger,HS5DeviceError){ | ||
| 121 | /// Communication error | ||
| 122 | IHSCOverTimeError = 0, | ||
| 123 | /// Communication Error | ||
| 124 | IHSCUserInScale=5, | ||
| 125 | /// Make sure batteries are installed correctly, if the problem persists, replace with a new set of batteries. | ||
| 126 | IHSCLowPower=6, | ||
| 127 | /// Remove the batteries, wait 1 minute and then replace with a new set of batteries. | ||
| 128 | IHSCScaleEr0=7, | ||
| 129 | /// The current weight may be beyond the measurement range of 330 lbs/150 kg. | ||
| 130 | IHSCScaleEr1=8, | ||
| 131 | /// Stand still on all four electrodes with bare feet. | ||
| 132 | IHSCScaleEr2=9, | ||
| 133 | /// Communication Error | ||
| 134 | IHSCScaleEr7=10, | ||
| 135 | /// Communication Error | ||
| 136 | IHSCScaleEr8=11, | ||
| 137 | /// Communication Error | ||
| 138 | IHSCScaleEr9=12, | ||
| 139 | /// Scale is busy | ||
| 140 | IHScaleBusy=13, | ||
| 141 | /// No memory | ||
| 142 | HS5DataZeor=14,// No memory | ||
| 143 | /// Scale Create User Test Error | ||
| 144 | IHSCScaleCreateUserTestError = 15, | ||
| 145 | /// Device disconnect | ||
| 146 | HS5Disconnect = 16, | ||
| 147 | /// User verify error | ||
| 148 | HS5UserInvalidate = 400 | ||
| 149 | }; | ||
| 150 | |||
| 151 | //HS6 Unit | ||
| 152 | |||
| 153 | /** | ||
| 154 | HS6 Unit | ||
| 155 | |||
| 156 | */ | ||
| 157 | typedef NS_ENUM(NSInteger,IHHS6SDKUnitWeight){ | ||
| 158 | /// kg | ||
| 159 | IHHS6SDKUnitWeight_kg = 0, | ||
| 160 | /// lb | ||
| 161 | IHHS6SDKUnitWeight_lbs, | ||
| 162 | /// st | ||
| 163 | IHHS6SDKUnitWeight_oz, | ||
| 164 | }; | ||
| 165 | |||
| 166 | #pragma mark HS2 Block | ||
| 167 | |||
| 168 | /** | ||
| 169 | Result | ||
| 170 | |||
| 171 | @param resetSuc reset Success | ||
| 172 | */ | ||
| 173 | typedef void (^DisposeHS2Result)(BOOL resetSuc); | ||
| 174 | |||
| 175 | /** | ||
| 176 | HS4 error | ||
| 177 | |||
| 178 | @param errorID error number | ||
| 179 | */ | ||
| 180 | typedef void (^DisposeHS2ErrorBlock)(HS2DeviceError errorID); | ||
| 181 | |||
| 182 | |||
| 183 | /** | ||
| 184 | Start transfer Memory Dictionary(5) | ||
| 185 | |||
| 186 | @param startDataDictionary Memory Data Dictionary | ||
| 187 | */ | ||
| 188 | typedef void (^StartHS2Transmission)(NSDictionary *startDataDictionary); | ||
| 189 | |||
| 190 | /** | ||
| 191 | Memory transmission progress | ||
| 192 | |||
| 193 | @param progress progress 0.0~1.0. | ||
| 194 | */ | ||
| 195 | typedef void (^DisposeHS2Progress)(NSNumber *progress); | ||
| 196 | //data including weight (kg), measurement time,coordinated key:weight,date. | ||
| 197 | |||
| 198 | /** | ||
| 199 | historyDataArray including weight (kg), measurement time,coordinated key:weight,date. | ||
| 200 | |||
| 201 | @param historyDataArray historyDataArray | ||
| 202 | */ | ||
| 203 | typedef void (^HS2MemorryData)(NSArray *historyDataArray); | ||
| 204 | |||
| 205 | /** | ||
| 206 | Finish memory transmission. | ||
| 207 | */ | ||
| 208 | typedef void (^FinishHS2Transmission)(void); | ||
| 209 | //Current weight, (Kg) | ||
| 210 | |||
| 211 | /** | ||
| 212 | Current unstable weight, (Kg) | ||
| 213 | |||
| 214 | @param unStableWeight unStableWeight | ||
| 215 | */ | ||
| 216 | typedef void (^HS2UnStableWeight)(NSNumber *unStableWeight); | ||
| 217 | //Stable weight, (Kg) | ||
| 218 | |||
| 219 | /** | ||
| 220 | StableWeightDictionary including stableweight(kg),time,dataID | ||
| 221 | |||
| 222 | @param StableWeightDic StableWeightDictionary | ||
| 223 | */ | ||
| 224 | typedef void (^HS2StableWeight)(NSDictionary *StableWeightDic); | ||
| 225 | |||
| 226 | /** | ||
| 227 | DisposeSendHS2DataBlock | ||
| 228 | */ | ||
| 229 | typedef void (^DisposeSendHS2DataBlock)(void); | ||
| 230 | |||
| 231 | /** | ||
| 232 | HS2 battery | ||
| 233 | |||
| 234 | @param battary battery | ||
| 235 | */ | ||
| 236 | typedef void (^DisposeHS2BatteryBlock)(NSNumber *battary); | ||
| 237 | |||
| 238 | |||
| 239 | #pragma mark HS3 Block | ||
| 240 | /** | ||
| 241 | deviceID | ||
| 242 | |||
| 243 | @param weightID deviceID | ||
| 244 | */ | ||
| 245 | typedef void(^WeightID)(NSString *weightID); | ||
| 246 | //HS3Error | ||
| 247 | |||
| 248 | /** | ||
| 249 | HS3 Device Error | ||
| 250 | |||
| 251 | @param errorID errorID | ||
| 252 | */ | ||
| 253 | typedef void (^DisposeHS3ErrorBlock)(HS3DeviceError errorID); | ||
| 254 | |||
| 255 | /** | ||
| 256 | Memory Number,0~200. | ||
| 257 | |||
| 258 | @param uploadDataNum Memory Number | ||
| 259 | */ | ||
| 260 | typedef void (^DisposeHS3UploadDataNum)(NSNumber *uploadDataNum); | ||
| 261 | |||
| 262 | /** | ||
| 263 | Memory transmission progress,0.0~1.0. | ||
| 264 | |||
| 265 | @param progress Transmission progress | ||
| 266 | */ | ||
| 267 | typedef void (^DisposeHS3Progress)(float progress); | ||
| 268 | |||
| 269 | /** | ||
| 270 | historyData including weight(kg), measure time,coordinated key:weight、date. | ||
| 271 | |||
| 272 | @param historyDataDic historyDataDictionary | ||
| 273 | */ | ||
| 274 | typedef void (^HS3MemorryData)(NSDictionary *historyDataDic); | ||
| 275 | //Start transmission | ||
| 276 | |||
| 277 | /** | ||
| 278 | Start transmission | ||
| 279 | |||
| 280 | @param startTransmission YES or NO | ||
| 281 | */ | ||
| 282 | typedef void (^StartHS3Transmission)(BOOL startTransmission); | ||
| 283 | |||
| 284 | /** | ||
| 285 | Finish memory transmission. | ||
| 286 | */ | ||
| 287 | typedef void (^FinishHS3Transmission)(void); | ||
| 288 | |||
| 289 | /** | ||
| 290 | Stable weight (Kg) | ||
| 291 | |||
| 292 | @param StableWeightDic StableWeightNSDictionary | ||
| 293 | */ | ||
| 294 | typedef void (^StableHS3Weight)(NSDictionary *StableWeightDic); | ||
| 295 | |||
| 296 | /** | ||
| 297 | FinishHS3Init | ||
| 298 | */ | ||
| 299 | typedef void (^FinishHS3Init)(void); | ||
| 300 | |||
| 301 | /** | ||
| 302 | DisposeResult | ||
| 303 | |||
| 304 | @param resetSuc YES or NO | ||
| 305 | */ | ||
| 306 | typedef void (^DisposeResult)(BOOL resetSuc); | ||
| 307 | |||
| 308 | |||
| 309 | #pragma mark HS4 Block | ||
| 310 | /** | ||
| 311 | DisposeResult | ||
| 312 | |||
| 313 | @param resetSuc YES or NO | ||
| 314 | */ | ||
| 315 | typedef void (^DisposeResult)(BOOL resetSuc); | ||
| 316 | |||
| 317 | /** | ||
| 318 | HS4 error | ||
| 319 | |||
| 320 | @param errorID errorID | ||
| 321 | */ | ||
| 322 | typedef void (^DisposeHS4ErrorBlock)(HS4DeviceError errorID); | ||
| 323 | |||
| 324 | /** | ||
| 325 | Start Memory transmission | ||
| 326 | |||
| 327 | @param startDataDictionary startDataDictionary | ||
| 328 | */ | ||
| 329 | typedef void (^StartHS4Transmission)(NSDictionary *startDataDictionary); | ||
| 330 | |||
| 331 | /** | ||
| 332 | Memory transmission progress,0.0~1.0. | ||
| 333 | |||
| 334 | @param progress progress | ||
| 335 | */ | ||
| 336 | typedef void (^DisposeProgress)(NSNumber *progress); | ||
| 337 | |||
| 338 | /** | ||
| 339 | historyDataArray data including weight (kg), measurement time,coordinated key:weight,date. | ||
| 340 | |||
| 341 | @param historyDataArray historyDataArray | ||
| 342 | */ | ||
| 343 | typedef void (^MemorryData)(NSArray *historyDataArray); | ||
| 344 | |||
| 345 | /** | ||
| 346 | Finish memory transmission. | ||
| 347 | */ | ||
| 348 | typedef void (^FinishHS4Transmission)(void); | ||
| 349 | |||
| 350 | /** | ||
| 351 | Current unstableweight, (Kg) | ||
| 352 | |||
| 353 | @param unStableWeight unStableWeight | ||
| 354 | */ | ||
| 355 | typedef void (^UnStableWeight)(NSNumber *unStableWeight); | ||
| 356 | |||
| 357 | /** | ||
| 358 | Stable weight,(Kg) | ||
| 359 | |||
| 360 | @param StableWeightDic StableWeightDictionary | ||
| 361 | */ | ||
| 362 | typedef void (^StableWeight)(NSDictionary *StableWeightDic); | ||
| 363 | |||
| 364 | /** | ||
| 365 | SendHS4DataBlock | ||
| 366 | */ | ||
| 367 | typedef void (^DisposeSendHS4DataBlock)(void); | ||
| 368 | |||
| 369 | |||
| 370 | #pragma mark HS5 Block | ||
| 371 | |||
| 372 | /** | ||
| 373 | Existing user info in HS5,including serialNub、Position of users. Related key: serialNumber、position | ||
| 374 | |||
| 375 | @param userListDataArray userListDataArray | ||
| 376 | */ | ||
| 377 | typedef void (^MemorryUserListHS5Data)(NSArray *userListDataArray); | ||
| 378 | |||
| 379 | /** | ||
| 380 | HS5 result | ||
| 381 | |||
| 382 | @param resetSuc reset success | ||
| 383 | */ | ||
| 384 | typedef void (^DisposeHS5Result)(BOOL resetSuc); | ||
| 385 | |||
| 386 | /** | ||
| 387 | HS5 error | ||
| 388 | |||
| 389 | @param errorID errorID | ||
| 390 | */ | ||
| 391 | typedef void (^DisposeHS5ErrorBlock)(HS5DeviceError errorID); | ||
| 392 | |||
| 393 | /** | ||
| 394 | Start memory transmission. | ||
| 395 | |||
| 396 | @param startHS5Transmission startHS5Transmission | ||
| 397 | */ | ||
| 398 | typedef void (^StartHS5Transmission)(BOOL startHS5Transmission); | ||
| 399 | |||
| 400 | /** | ||
| 401 | progress: Memory transmission progress,0.0~1.0. | ||
| 402 | |||
| 403 | @param progress progress | ||
| 404 | */ | ||
| 405 | typedef void (^DisposeHS5Progress)(NSNumber *progress); | ||
| 406 | |||
| 407 | /** | ||
| 408 | Record data,More details and key refer Measure API. Additionally add time-measure property, related key: date. | ||
| 409 | |||
| 410 | @param historyDataDic historyDataDictionary | ||
| 411 | */ | ||
| 412 | typedef void (^MemorryHS5Data)(NSDictionary *historyDataDic); | ||
| 413 | |||
| 414 | /** | ||
| 415 | Finish Memory Transmission | ||
| 416 | |||
| 417 | @param finishHS5Transmission YES or NO | ||
| 418 | */ | ||
| 419 | typedef void (^FinishHS5Transmission)(BOOL finishHS5Transmission); | ||
| 420 | |||
| 421 | /** | ||
| 422 | Current unstableweight, (kg) | ||
| 423 | |||
| 424 | @param unStableWeight unStableWeight | ||
| 425 | */ | ||
| 426 | typedef void (^UnStableHS5Weight)(NSNumber *unStableWeight); | ||
| 427 | |||
| 428 | /** | ||
| 429 | Stable weight, (kg) | ||
| 430 | |||
| 431 | @param StableWeight StableWeight | ||
| 432 | */ | ||
| 433 | typedef void (^StableHS5Weight)(NSNumber *StableWeight); | ||
| 434 | |||
| 435 | /** | ||
| 436 | Weight by impedence, (kg) | ||
| 437 | |||
| 438 | @param ImpedanceWeight ImpedanceWeight | ||
| 439 | */ | ||
| 440 | typedef void (^ImpedanceWeight)(NSNumber*ImpedanceWeight); | ||
| 441 | |||
| 442 | /** | ||
| 443 | body info, includes weight(kg), fat content(%), water content(%), muscle content(%), bone mass, visceral fat level, DCI(Kcal). keys: weight, weightFatValue, waterValue, muscleValue, skeletonValue, VFatLevelValue, DCIValue | ||
| 444 | |||
| 445 | |||
| 446 | @param BodyCompositionInforDic BodyCompositionInforDictionary | ||
| 447 | */ | ||
| 448 | typedef void (^BodyCompositionMeasurements)(NSDictionary*BodyCompositionInforDic); | ||
| 449 | |||
| 450 | /** | ||
| 451 | superPassword | ||
| 452 | |||
| 453 | @param superPassword superPassword | ||
| 454 | */ | ||
| 455 | typedef void (^GetScaleSuperPassword)(NSString*superPassword); | ||
| 456 | |||
| 457 | /** | ||
| 458 | CurrentSerialNub | ||
| 459 | |||
| 460 | @param serialNub serialNub | ||
| 461 | */ | ||
| 462 | typedef void (^CurrentSerialNub)(NSInteger serialNub); | ||
| 463 | |||
| 464 | /** | ||
| 465 | SendHS5DataBlock | ||
| 466 | */ | ||
| 467 | typedef void (^DisposeSendHS5DataBlock)(void); | ||
| 468 | |||
| 469 | |||
| 470 | #pragma mark HS6 Block | ||
| 471 | |||
| 472 | /** | ||
| 473 | Set HS6 wifi success with device infomation | ||
| 474 | |||
| 475 | @param deviceInfo deviceInfo | ||
| 476 | */ | ||
| 477 | typedef void (^DisposeHS6SuccessBlock)(NSDictionary* deviceInfo); | ||
| 478 | |||
| 479 | /** | ||
| 480 | Set HS6 wifi fail | ||
| 481 | |||
| 482 | @param failmsg fail message | ||
| 483 | */ | ||
| 484 | typedef void (^DisposeHS6FailBlock)(NSString* failmsg); | ||
| 485 | |||
| 486 | /** | ||
| 487 | Set HS6 end | ||
| 488 | |||
| 489 | @param deviceDic deviceDictionary | ||
| 490 | */ | ||
| 491 | typedef void (^DisposeHS6EndBlock)(NSDictionary* deviceDic); | ||
| 492 | |||
| 493 | /** | ||
| 494 | HS6 error | ||
| 495 | |||
| 496 | @param error error number | ||
| 497 | */ | ||
| 498 | typedef void (^DisposeHS6ErrorBlock)(NSNumber* error); | ||
| 499 | |||
| 500 | /** | ||
| 501 | Binding QR Device | ||
| 502 | |||
| 503 | @param resultArray resultArray | ||
| 504 | */ | ||
| 505 | typedef void(^BinedQRDeviceBlock)(NSArray *resultArray); | ||
| 506 | /** | ||
| 507 | Binding QR Device error | ||
| 508 | |||
| 509 | @param errorCode errorCode | ||
| 510 | */ | ||
| 511 | typedef void(^BinedQRDeviceErrorBlock)(NSString *errorCode); | ||
| 512 | |||
| 513 | /** | ||
| 514 | unbind QRDevice | ||
| 515 | |||
| 516 | @param resultArray resultArray | ||
| 517 | */ | ||
| 518 | typedef void(^DisBinedQRDeviceBlock)(NSArray *resultArray); | ||
| 519 | |||
| 520 | /** | ||
| 521 | unbind QRDevice error | ||
| 522 | |||
| 523 | @param errorCode errorCode | ||
| 524 | */ | ||
| 525 | typedef void(^DisBinedQRDeviceErrorBlock)(NSString *errorCode); | ||
| 526 | |||
| 527 | /** | ||
| 528 | getOpenApi | ||
| 529 | |||
| 530 | @param openAPIInfoDic openAPIInfoDictionary | ||
| 531 | */ | ||
| 532 | typedef void (^DisposeHS6GetOpenAPISuccessBlock)(NSDictionary* openAPIInfoDic); | ||
| 533 | |||
| 534 | /** | ||
| 535 | GetOpenAPIError | ||
| 536 | |||
| 537 | @param errorCode errorCode | ||
| 538 | */ | ||
| 539 | typedef void (^DisposeHS6GetOpenAPIErrorBlock)(NSDictionary *errorCode); | ||
| 540 | |||
| 541 | /** | ||
| 542 | sync Weight Unit | ||
| 543 | |||
| 544 | @param syncWeightUnit syncWeightUnit | ||
| 545 | */ | ||
| 546 | typedef void (^DisposeHS6SyncWeightUnitSuccessBlock)(BOOL syncWeightUnit); | ||
| 547 | |||
| 548 | /** | ||
| 549 | Sync Weight Unit Error | ||
| 550 | |||
| 551 | @param errorCode errorCode | ||
| 552 | */ | ||
| 553 | typedef void (^DisposeHS6SyncWeightUnitErrorBlock)(NSString *errorCode); | ||
| 554 | |||
| 555 | |||
| 556 | //typedef void (^BlockUserAuthentication)(UserAuthenResult result); | ||
| 557 | |||
| 558 | /** | ||
| 559 | the result of userID | ||
| 560 | |||
| 561 | @param dataArray dataArray | ||
| 562 | */ | ||
| 563 | |||
| 564 | typedef void (^BlockDataFromCloud)(NSArray *dataArray); | ||
| 565 | |||
| 566 | typedef void (^BlockHS6DataFromCloud)(NSDictionary *dataDic); | ||
| 567 | |||
| 568 | typedef void (^BlockHS6LastTSFromCloud)(NSNumber *lastTS); | ||
| 569 | |||
| 570 | #pragma mark HS2S Block | ||
| 571 | |||
| 572 | |||
| 573 | /** | ||
| 574 | Result | ||
| 575 | |||
| 576 | @param deviceInfo deviceInfo | ||
| 577 | */ | ||
| 578 | typedef void (^DisposeHS2SDeviceInfo)(NSDictionary*deviceInfo); | ||
| 579 | |||
| 580 | /** | ||
| 581 | HS2S error | ||
| 582 | |||
| 583 | @param errorID error number | ||
| 584 | */ | ||
| 585 | typedef void (^DisposeHS2SErrorBlock)(HS2SDeviceError errorID); | ||
| 586 | |||
| 587 | /** | ||
| 588 | HS2S battery | ||
| 589 | |||
| 590 | @param battary battery | ||
| 591 | */ | ||
| 592 | typedef void (^DisposeHS2SBatteryBlock)(NSNumber *battary); | ||
| 593 | |||
| 594 | /** | ||
| 595 | HS2S UserInfo | ||
| 596 | |||
| 597 | |||
| 598 | @param userInfo userInfo | ||
| 599 | */ | ||
| 600 | typedef void (^DisposeHS2SUserInfo)(NSDictionary*userInfo); | ||
| 601 | |||
| 602 | /** | ||
| 603 | Result | ||
| 604 | |||
| 605 | @param result reset Success | ||
| 606 | */ | ||
| 607 | typedef void (^DisposeHS2SResult)(BOOL result); | ||
| 608 | |||
| 609 | /** | ||
| 610 | HS2S memory count | ||
| 611 | |||
| 612 | @param count count | ||
| 613 | */ | ||
| 614 | typedef void (^DisposeHS2SMemoryCountBlock)(NSNumber *count); | ||
| 615 | |||
| 616 | /** | ||
| 617 | HS2S memory data | ||
| 618 | |||
| 619 | @param data data | ||
| 620 | */ | ||
| 621 | typedef void (^DisposeHS2SMemoryDataBlock)(NSArray *data); | ||
| 622 | |||
| 623 | /** | ||
| 624 | HS2S memory count | ||
| 625 | |||
| 626 | @param count count | ||
| 627 | */ | ||
| 628 | typedef void (^DisposeHS2SAnonymousMemoryCountBlock)(NSNumber *count); | ||
| 629 | |||
| 630 | /** | ||
| 631 | HS2S memory data | ||
| 632 | |||
| 633 | @param data data | ||
| 634 | */ | ||
| 635 | typedef void (^DisposeHS2SAnonymousMemoryDataBlock)(NSArray *data); | ||
| 636 | /** | ||
| 637 | Current unstableweight, (Kg) | ||
| 638 | |||
| 639 | @param unStableWeight unStableWeight | ||
| 640 | */ | ||
| 641 | typedef void (^DisposeHS2SUnStableWeight)(NSNumber *unStableWeight); | ||
| 642 | |||
| 643 | /** | ||
| 644 | Stable weight,(Kg) | ||
| 645 | |||
| 646 | @param stableWeight StableWeight | ||
| 647 | */ | ||
| 648 | typedef void (^DisposeHS2SStableWeight)(NSNumber *stableWeight); | ||
| 649 | |||
| 650 | /** | ||
| 651 | weightAndBodyInfoDic | ||
| 652 | |||
| 653 | @param weightAndBodyInfoDic weightAndBodyInfoDic | ||
| 654 | */ | ||
| 655 | typedef void (^DisposeHS2SWeightAndBodyInfo)(NSDictionary *weightAndBodyInfoDic); | ||
| 656 | |||
| 657 | |||
| 658 | /** | ||
| 659 | Heart Result | ||
| 660 | |||
| 661 | @param heartResultDic | ||
| 662 | */ | ||
| 663 | typedef void (^DisposeHS2SHeartResult)(NSDictionary *heartResultDic); | ||
| 664 | |||
| 665 | |||
| 666 | /** | ||
| 667 | MeasurementStatus | ||
| 668 | |||
| 669 | @param measurementStatus | ||
| 670 | */ | ||
| 671 | typedef void (^DisposeHS2SMeasurementStatus)(NSNumber *measurementStatus); | ||
| 672 | |||
| 673 | |||
| 674 | |||
| 675 | typedef void (^DisposeHS2SMeasureFinish)(void); | ||
| 676 | |||
| 677 | #define HS3ConnectNoti @"HS3ConnectNoti" | ||
| 678 | #define HS3DisConnectNoti @"HS3DisConnectNoti" | ||
| 679 | |||
| 680 | #define HS2Discover @"HS2Discover" | ||
| 681 | #define HS2ConnectFailed @"HS2ConnectFailed" | ||
| 682 | #define HS2ConnectNoti @"HS2ConnectNoti" | ||
| 683 | #define HS2DisConnectNoti @"HS2DisConnectNoti" | ||
| 684 | |||
| 685 | #define HS2SDiscover @"HS2SDiscover" | ||
| 686 | #define HS2SConnectFailed @"HS2SConnectFailed" | ||
| 687 | #define HS2SConnectNoti @"HS2SConnectNoti" | ||
| 688 | #define HS2SDisConnectNoti @"HS2SDisConnectNoti" | ||
| 689 | |||
| 690 | #define HS4Discover @"HS4Discover" | ||
| 691 | #define HS4ConnectFailed @"HS4ConnectFailed" | ||
| 692 | #define HS4ConnectNoti @"HS4ConnectNoti" | ||
| 693 | #define HS4DisConnectNoti @"HS4DisConnectNoti" | ||
| 694 | |||
| 695 | |||
| 696 | #define HS5ConnectNoti @"HS5ConnectNoti" | ||
| 697 | #define HS5DisConnectNoti @"HS5DisConnectNoti" | ||
| 698 | |||
| 699 | #define HSDeviceID @"ID" | ||
| 700 | #define HSSDKRightApi @"OpenApiWeight" | ||
| 701 | |||
| 702 | |||
| 703 | #define ContinuaHSDiscover @"ContinuaHSDiscover" | ||
| 704 | #define ContinuaHSConnectFailed @"ContinuaHSConnectFailed" | ||
| 705 | #define ContinuaHSConnectNoti @"ContinuaHSConnectNoti" | ||
| 706 | #define ContinuaHSDisConnectNoti @"ContinuaHSDisConnectNoti" | ||
| 707 | |||
| 708 | |||
| 709 | #endif | ||
