Kaynağa Gözat

修改:ELBluetoothManager(牙刷重复返回透传数据),ToothbrushConnectionViewController(增加离线记录)

tags/v1.5.11
larryzhang 2 yıl önce
ebeveyn
işleme
ed49b75dd8

+ 4
- 4
AILinkBleSDKDemo.xcodeproj/project.pbxproj Dosyayı Görüntüle

@@ -1091,7 +1091,7 @@
buildSettings = {
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
CODE_SIGN_STYLE = Automatic;
CURRENT_PROJECT_VERSION = 20230206;
CURRENT_PROJECT_VERSION = 20230209;
DEVELOPMENT_TEAM = YEU77XR292;
FRAMEWORK_SEARCH_PATHS = (
"$(inherited)",
@@ -1111,7 +1111,7 @@
"$(PROJECT_DIR)/AILinkBleSDKDemo/13_EightScale/HTBodyfat_SDK",
"$(PROJECT_DIR)/AILinkBleSDKDemo/13_EightScale/BhBodyComposition120",
);
MARKETING_VERSION = 1.5.9;
MARKETING_VERSION = 1.5.10_beta01;
OTHER_LDFLAGS = "-ObjC";
PRODUCT_BUNDLE_IDENTIFIER = com.pingwang.AILinkBleSDKDemo;
PRODUCT_NAME = "$(TARGET_NAME)";
@@ -1124,7 +1124,7 @@
buildSettings = {
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
CODE_SIGN_STYLE = Automatic;
CURRENT_PROJECT_VERSION = 20230206;
CURRENT_PROJECT_VERSION = 20230209;
DEVELOPMENT_TEAM = YEU77XR292;
FRAMEWORK_SEARCH_PATHS = (
"$(inherited)",
@@ -1144,7 +1144,7 @@
"$(PROJECT_DIR)/AILinkBleSDKDemo/13_EightScale/HTBodyfat_SDK",
"$(PROJECT_DIR)/AILinkBleSDKDemo/13_EightScale/BhBodyComposition120",
);
MARKETING_VERSION = 1.5.9;
MARKETING_VERSION = 1.5.10_beta01;
OTHER_LDFLAGS = "-ObjC";
PRODUCT_BUNDLE_IDENTIFIER = com.pingwang.AILinkBleSDKDemo;
PRODUCT_NAME = "$(TARGET_NAME)";

+ 44
- 0
AILinkBleSDKDemo/14_WifiBleToothbrush/ToothbrushConnectionViewController.m Dosyayı Görüntüle

@@ -431,10 +431,54 @@ static NSString * const authorizeIntervalKey = @"authorizeIntervalKey";
[[ELToothbrushBleManager shareManager] getBluetoothInfoWithELInetGetCmdType:(ELInetGetCmdTypeGetBatteryState)];
//获取蓝牙和wifi连接状态
[[ELToothbrushBleManager shareManager] getBluetoothInfoWithELInetGetCmdType:(ELInetGetCmdTypeGetConnectState)];
//离线历史记录-步骤1:获取条数
[[ELToothbrushBleManager shareManager] getOfflineDataCount];
}
}
#pragma mark ============ ELBluetoothManagerDelegate ==============

//离线历史记录-步骤2:返回条数
- (void)toothbrushtReceiveToothbrushOfflineDataCount:(unsigned char)count result:(unsigned char)result {
[self addLog:[NSString stringWithFormat:@"离线历史记录:%d条,结果:%d", count, result]];
BOOL success = (result == 0);
if (success && count > 0) {
//离线历史记录-步骤3:请求接收
[self addLog:@"请求接收离线历史记录"];
[[ELToothbrushBleManager shareManager] getOfflineDataStart];
}
}

//离线历史记录-步骤4:上报给APP
- (void)toothbrushtReceiveToothbrushOfflineData:(ToothbrushOfflineData)data {
//离线历史记录-步骤5:通知模块发下一组数据
[self addLog:@"app通知模块可以发送下一组离线历史记录数据"];
[[ELToothbrushBleManager shareManager] getOfflineNextRecord];
}

//离线历史记录-步骤6:发送过程
- (void)toothbrushReceiveRecordDataStatus:(enum ToothbrushOfflineRecrodStatusType)status {
switch (status) {
case ToothbrushOfflineRecrodStatusType_DataCompleted_00: {
[self addLog:@"离线历史记录数据全部发送完成"];
[[ELToothbrushBleManager shareManager] getOfflineDataCancel];
[[ELToothbrushBleManager shareManager] getOfflineDataClear];
}
break;
case ToothbrushOfflineRecrodStatusType_DataAbnormal_01: {
[self addLog:@"离线历史记录数据发送异常"];
[[ELToothbrushBleManager shareManager] getOfflineDataCancel];
[[ELToothbrushBleManager shareManager] getOfflineDataClear];
}
break;
case ToothbrushOfflineRecrodStatusType_SendNextData_02:
break;
default:
break;
}
}

//
-(void)bluetoothManagerReceiveDeviceAuthorizeResult:(ELBluetoothDeviceAuthorizeResult)result{
if (result == ELBluetoothDeviceAuthorizeResultNoAuth) {

BIN
AILinkBleSDKDemo/AILinkBleSDK.framework/AILinkBleSDK Dosyayı Görüntüle


+ 1
- 0
AILinkBleSDKDemo/AILinkBleSDK.framework/Headers/AILinkBleSDK-umbrella.h Dosyayı Görüntüle

@@ -80,6 +80,7 @@
#import "ELCoffeeScaleBleDataModel.h"
#import "ELCoffeeScaleBleHeader.h"
#import "ELCoffeeScaleBleManager.h"
#import "AILinkBleSDK_Version.h"
#import "ELBlePublicTool.h"
#import "ELBluetoothManager+BleWifi.h"
#import "ELBluetoothManager+BleWifi_Callback.h"

+ 14
- 0
AILinkBleSDKDemo/AILinkBleSDK.framework/Headers/AILinkBleSDK_Version.h Dosyayı Görüntüle

@@ -0,0 +1,14 @@
//
// AILinkBleSDK_Version.h
// Pods
//
// Created by LarryZhang on 2023/2/9.
//

#ifndef AILinkBleSDK_Version_h
#define AILinkBleSDK_Version_h

//版本号 SDK Version
#define AiLinkBleSDKVersion @"1.5.10_beta01" //20230209 优化牙刷

#endif /* AILinkBleSDK_Version_h */

+ 1
- 4
AILinkBleSDKDemo/AILinkBleSDK.framework/Headers/ELBluetoothManager.h Dosyayı Görüntüle

@@ -12,10 +12,7 @@
#import "ELBlePublicTool.h"
#import "ELBluetoothManager+Settings_Callback.h"
#import "ELBluetoothManager+BleWifi_Callback.h"


//版本号 SDK Version
#define AiLinkBleSDKVersion @"1.5.9" //20230206 增加身高体脂秤 (Add Height Body Fat Scale)
#import "AILinkBleSDK_Version.h"


NS_ASSUME_NONNULL_BEGIN

+ 15
- 15
AILinkBleSDKDemo/AILinkBleSDK.framework/Headers/ELToothbrushBleManager.h Dosyayı Görüntüle

@@ -111,39 +111,39 @@ NS_ASSUME_NONNULL_BEGIN
//Get supported gear(获取支持的档位)
- (void)getGear;

/// Set brushing mode(设置刷牙模式)
/// Set brushing mode(设置刷牙模式) //******** wifi 牙刷专用方法
/// @param gearType Brushing mode(刷牙模式)
/// @param interval Brushing time (0: do not modify the working time, before keeping)(刷牙时间(0:不修改工作时长,保留之前))
/// @param supportType Which gear is it(是哪个档位)
- (void)setWorkGear:(ToothbrushGearType)gearType interval:(int)interval supportGearType:(ToothSupportGearType)supportType;
//******** 通用牙刷专用方法
- (void)setWorkGear:(ToothbrushGearType)gearType interval:(int)interval supportGearType:(ToothSupportGearType)supportType withCid:(ELSupportDeviceType)cid;

/// Get the current working gear(获取当前工作的档位)
/// Get the current working gear(获取当前工作的档位) //******** wifi 牙刷专用方法
- (void)getWorkGear;
//******** 通用牙刷专用方法
- (void)getWorkGearWithCid:(ELSupportDeviceType)cid;

/// try out(试用)
/// try out(试用) //******** wifi 牙刷专用方法
/// @param gear Gear (ToothbrushGearTypeStop_00 means stop trial)(档位(ToothbrushGearTypeStop_00 表示停止试用))
/// @param supportType Which gear(第几档)
/// @param frequency 频率
/// @param duty 占空比
- (void)tryGear:(ToothbrushGearType)gear supportType:(ToothSupportGearType)supportType frequency:(int)frequency duty:(int)duty;
//******** 通用牙刷专用方法
- (void)tryGear:(ToothbrushGearType)gear supportType:(ToothSupportGearType)supportType frequency:(int)frequency duty:(int)duty withCid:(ELSupportDeviceType)cid;

/// Get the current work stage(获取当前工作阶段)
/// Get the current work stage(获取当前工作阶段) //******** wifi 牙刷专用方法
- (void)getWorkPhase;
//******** 通用牙刷专用方法
- (void)getWorkPhaseWithCid:(ELSupportDeviceType)cid;

/// Set manual setting gear(设置手动设置档位)
/// Set manual setting gear(设置手动设置档位) //******** wifi 牙刷专用方法
/// @param frequency 频率
/// @param duty 占空比
/// @param interval 时间
- (void)setCustomGearData:(int)frequency duty:(int)duty interval:(int)interval;
//******** 通用牙刷专用方法
- (void)setCustomGearData:(int)frequency duty:(int)duty interval:(int)interval withCid:(ELSupportDeviceType)cid;

/// Get manual profile data(获取手动设置档数据)
@@ -177,19 +177,19 @@ NS_ASSUME_NONNULL_BEGIN
//Get three-axis data(获取三轴数据)
- (void)getTriaxialData;

//Set the second gear default gear(设置二档默认档位)
//Set the second gear default gear(设置二档默认档位) //******** wifi 牙刷专用方法
- (void)setTwoGearDefaultGear:(ToothbrushGearType)gear;
//******** 通用牙刷专用方法
- (void)setTwoGearDefaultGear:(ToothbrushGearType)gear withCid:(ELSupportDeviceType)cid;

//Get the second gear default gear(获取二档默认档位)
- (void)getTwoGearDefualt;
//******** 通用牙刷专用方法
- (void)getTwoGearDefualtWithCid:(ELSupportDeviceType)cid;

//Report the results of receiving brushing data(上报刷牙数据接收结果)
//Report the results of receiving brushing data(上报刷牙数据接收结果) //******** wifi 牙刷专用方法
- (void)reportReceiveResultOfToothbrushData:(BOOL)result;
//******** 通用牙刷专用方法
- (void)reportReceiveResultOfToothbrushData:(BOOL)result withCid:(ELSupportDeviceType)cid;

///清除wifi记录指令

Loading…
İptal
Kaydet