Переглянути джерело

增加:WIFI 血压计 Demo 优化;SDK问题修复

tags/1.11.0^0
LarryZhang 2 місяці тому
джерело
коміт
25059b3ce1
19 змінених файлів з 415 додано та 88 видалено
  1. 4
    4
      AILinkBleSDKDemo.xcodeproj/project.pbxproj
  2. BIN
      AILinkBleSDKDemo/AILinkBleSDK.framework/AILinkBleSDK
  3. 1
    1
      AILinkBleSDKDemo/AILinkBleSDK.framework/Headers/AILinkBleSDK_Version.h
  4. 12
    5
      AILinkBleSDKDemo/AILinkBleSDK.framework/Headers/ELAILinkBleManager.h
  5. 4
    0
      AILinkBleSDKDemo/AILinkBleSDK.framework/Headers/ELBluetoothManager.h
  6. 6
    0
      AILinkBleSDKDemo/AILinkBleSDK.framework/Headers/ELBodyFatScaleBleHeader.h
  7. 14
    1
      AILinkBleSDKDemo/AILinkBleSDK.framework/Headers/ELBodyFatScaleBleManager.h
  8. 39
    3
      AILinkBleSDKDemo/AILinkBleSDK.framework/Headers/ELCM02_BleHeader.h
  9. 28
    6
      AILinkBleSDKDemo/AILinkBleSDK.framework/Headers/ELCM02_BleManager.h
  10. 7
    0
      AILinkBleSDKDemo/AILinkBleSDK.framework/Headers/ELExSupportDeviceType.h
  11. 17
    0
      AILinkBleSDKDemo/AILinkBleSDK.framework/Headers/ELHeightBodyFatScaleBleManager.h
  12. 25
    0
      AILinkBleSDKDemo/AILinkBleSDK.framework/Headers/ELHeightBodyFatScaleBleWeightBodyModel.h
  13. 28
    3
      AILinkBleSDKDemo/AILinkBleSDK.framework/Headers/ELThermometerBleManager.h
  14. BIN
      AILinkBleSDKDemo/AILinkBleSDK.framework/Info.plist
  15. BIN
      AILinkBleSDKDemo/AILinkBleSDK.framework/PrivacyInfo.bundle/Info.plist
  16. 171
    48
      AILinkBleSDKDemo/DeviceDemo/05B_WIFI_BLE_BloodPressure/ELWIFIBloodPressureVC.m
  17. 58
    16
      AILinkBleSDKDemo/DeviceDemo/05B_WIFI_BLE_BloodPressure/ELWIFIBloodPressureVC.xib
  18. BIN
      AILinkBleSDKDemo/PrivacyInfo.bundle/Info.plist
  19. 1
    1
      README.md

+ 4
- 4
AILinkBleSDKDemo.xcodeproj/project.pbxproj Переглянути файл

@@ -1337,7 +1337,7 @@
buildSettings = {
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
CODE_SIGN_STYLE = Automatic;
CURRENT_PROJECT_VERSION = 20240910;
CURRENT_PROJECT_VERSION = 20250305;
DEVELOPMENT_TEAM = YEU77XR292;
FRAMEWORK_SEARCH_PATHS = (
"$(inherited)",
@@ -1359,7 +1359,7 @@
"$(PROJECT_DIR)/AILinkBleSDKDemo/DeviceDemo/13_EightScale/HTBodyfat_SDK",
"$(PROJECT_DIR)/AILinkBleSDKDemo/DeviceDemo/13_EightScale/BhBodyComposition120",
);
MARKETING_VERSION = 1.10.0;
MARKETING_VERSION = 1.11.0;
OTHER_LDFLAGS = "-ObjC";
PRODUCT_BUNDLE_IDENTIFIER = com.ellinkthings.ailinksdk.app;
PRODUCT_NAME = "$(TARGET_NAME)";
@@ -1372,7 +1372,7 @@
buildSettings = {
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
CODE_SIGN_STYLE = Automatic;
CURRENT_PROJECT_VERSION = 20240910;
CURRENT_PROJECT_VERSION = 20250305;
DEVELOPMENT_TEAM = YEU77XR292;
FRAMEWORK_SEARCH_PATHS = (
"$(inherited)",
@@ -1394,7 +1394,7 @@
"$(PROJECT_DIR)/AILinkBleSDKDemo/DeviceDemo/13_EightScale/HTBodyfat_SDK",
"$(PROJECT_DIR)/AILinkBleSDKDemo/DeviceDemo/13_EightScale/BhBodyComposition120",
);
MARKETING_VERSION = 1.10.0;
MARKETING_VERSION = 1.11.0;
OTHER_LDFLAGS = "-ObjC";
PRODUCT_BUNDLE_IDENTIFIER = com.ellinkthings.ailinksdk.app;
PRODUCT_NAME = "$(TARGET_NAME)";

BIN
AILinkBleSDKDemo/AILinkBleSDK.framework/AILinkBleSDK Переглянути файл


+ 1
- 1
AILinkBleSDKDemo/AILinkBleSDK.framework/Headers/AILinkBleSDK_Version.h Переглянути файл

@@ -9,6 +9,6 @@
#define AILinkBleSDK_Version_h

//版本号 SDK Version
#define AiLinkBleSDKVersion @"1.10.0" // 20240910
#define AiLinkBleSDKVersion @"1.11.0" // 20250305

#endif /* AILinkBleSDK_Version_h */

+ 12
- 5
AILinkBleSDKDemo/AILinkBleSDK.framework/Headers/ELAILinkBleManager.h Переглянути файл

@@ -90,8 +90,6 @@ NS_ASSUME_NONNULL_BEGIN
#pragma mark - connect
@interface ELAILinkBleManager (connect)

//- (void)connectPeripheral:(CBPeripheral *)peripheral;

- (void)disconnectPeripheral;

- (void)connectAILinkPeripheral:(ELAILinkPeripheral * _Nonnull)ailinkPeripheral;
@@ -111,17 +109,26 @@ NS_ASSUME_NONNULL_BEGIN

/// base method of 'sendA7Payload' & 'sendA6Payload'
- (void)sendCmd:(NSData *)cmdData;
//直接发送
- (void)sendDirectCmd:(NSData *)cmdData;

//最大发送数据长度
- (NSUInteger)maximumWriteValueLength;
- (NSUInteger)maximumWriteValueLength DEPRECATED_MSG_ATTRIBUTE("use 'maximumWriteValueLengthForWriteWithResponse' or 'maximumWriteValueLengthForWriteWithoutResponse' instead");
//最大发送A7 payload长度
- (NSUInteger)maximumWriteA7PayloadLength;
- (NSUInteger)maximumWriteA7PayloadLength DEPRECATED_MSG_ATTRIBUTE("use 'maximumWriteValueLengthForWriteWithResponse' or 'maximumWriteValueLengthForWriteWithoutResponse' instead");
//最大发送A6 payload长度
- (NSUInteger)maximumWriteA6PayloadLength;
- (NSUInteger)maximumWriteA6PayloadLength DEPRECATED_MSG_ATTRIBUTE("use 'maximumWriteValueLengthForWriteWithResponse' or 'maximumWriteValueLengthForWriteWithoutResponse' instead");

//可发送的最大字节数
@property(nonatomic, assign, readonly) NSUInteger maximumWriteValueLengthForWriteWithResponse;
//可发送的最大字节数
@property(nonatomic, assign, readonly) NSUInteger maximumWriteValueLengthForWriteWithoutResponse;

//发送队列发送周期
- (void)configWriteDataQueueInterval:(CGFloat)interval;

- (void)configWriteCharacteristicWriteType:(CBCharacteristicWriteType)type;

@end

#pragma mark - Open

+ 4
- 0
AILinkBleSDKDemo/AILinkBleSDK.framework/Headers/ELBluetoothManager.h Переглянути файл

@@ -120,6 +120,7 @@ static NSString *GET_A7_DECRYPT_BLE_PAYLOAD_DATA_CONTENT = @"GET_A7_DECRYPT_BLE_
@param type Equipment type(设备类型)
*/
-(void)sendCmdToMCUWithA7PayloadData:(NSData *)data deviceType:(ELSupportDeviceType)type;
- (void)sendCmdToMCUWithA7PayloadDataNew:(NSData *)data deviceType:(ELSupportDeviceType)type;

/// 直接发送A7命令,不加载在队列中
-(void)immediatelySendCmdToMCUWithA7PayloadData:(NSData *)data deviceType:(ELSupportDeviceType)type;
@@ -131,6 +132,9 @@ static NSString *GET_A7_DECRYPT_BLE_PAYLOAD_DATA_CONTENT = @"GET_A7_DECRYPT_BLE_
*/
-(void)sendData:(NSData *)data;

//恢复出厂设置
- (void)setFactoryDataReset;


#pragma mark ============ Please rewrite the following methods in the subclass(请在子类重写以下方法) BEGIN==============


+ 6
- 0
AILinkBleSDKDemo/AILinkBleSDK.framework/Headers/ELBodyFatScaleBleHeader.h Переглянути файл

@@ -81,6 +81,12 @@ typedef NS_ENUM(NSInteger , ELBodyFatScaleBleDataType) {
ELBodyFatScaleBleDataType_ReceivedDataResult = 0xFE ,
/** 设备上发错误码 */
ELBodyFatScaleBleDataType_MCUBackErrorCode = 0xFF ,
/** APP请求支持的显示项 */
ELBodyFatScaleBleDataType_MCUBackSupportDataList = 0x11 ,
/** 6.1.11APP下发显示项和顺序 */
ELBodyFatScaleBleDataType_DeliverDisplayItemsTheirSequence = 0x10 ,
};



+ 14
- 1
AILinkBleSDKDemo/AILinkBleSDK.framework/Headers/ELBodyFatScaleBleManager.h Переглянути файл

@@ -118,6 +118,15 @@ MCU requests user information( MCU 请求用户信息)
* @param mode : 0:体脂模式(默认),1:体重模式(没有阻抗和体脂数据)
*/
- (void)bodyFatScaleManagerCallBackReportingMode:(NSInteger)mode;


/** MCU 返回支持数据类型列表
*/
- (void)bodyFatScaleManagerCallBackSupportDataList:(NSMutableArray*)dataList;

/** MCU 返回显示项和顺序
*/
- (void)bodyFatScaleManagerCallBackDisplayItemOrder:(NSMutableArray*)dataList;
@end


@@ -136,7 +145,11 @@ MCU requests user information( MCU 请求用户信息)
- (void)sendCurrentUserToBle:(ELBodyFatScaleBleUserModel *)usr;

-(void)sendReceivedDataResult:(BOOL)result;

//APP请求支持的显示项(0x0076)
- (void)get0x0076SupportDataTypeList;
//APP下发显示项和顺序(0x10)
- (void)readDeliverDisplayItemsTheirSequence;
- (void)sendDeliverDisplayItemsTheirSequence:(NSMutableArray*)dataList;
#pragma mark ============ 下发A6指令 ==============

-(void)sendOfflineUserListToBle:(NSArray <ELBodyFatScaleBleUserModel *> *)userListArr;

+ 39
- 3
AILinkBleSDKDemo/AILinkBleSDK.framework/Headers/ELCM02_BleHeader.h Переглянути файл

@@ -39,6 +39,12 @@ typedef NS_ENUM(NSInteger, CM02_BleDataType) {
CM02_BleDataType_ControlVersion = 0x10 ,
/** 查询仪表固件版本 */
CM02_BleDataType_DashboardVersion = 0x11 ,
/** 天气信息 */
CM02_BleDataType_WeatherPush = 0x13 ,
/** 导航数据 */
CM02_BleDataType_NaviData = 0x14 ,
/** 当前时区*/
CM02_BleDataType_CurrentTimeZone = 0x15 ,
/** 开始仪表OTA指令 */
CM02_BleDataType_StartOTA = 0xA0 ,
@@ -80,11 +86,17 @@ typedef NS_ENUM(NSInteger, CM02_PasswordCorrect_Type) {
/** 开锁相关的功能枚举定义 */
typedef NS_ENUM(NSInteger, CM02_LockState_Type) {
/** 解锁 */
CM02_LockState_Type_UnLock = 0 ,
CM02_LockState_Type_UnLock = 0 ,
/** 上锁 */
CM02_LockState_Type_Lock = 1 ,
CM02_LockState_Type_Lock = 1 ,
/** 验证密码 */
CM02_LockState_Type_VerifyPassword = 2 ,
CM02_LockState_Type_VerifyPassword = 2 ,
/** 查询仪表开锁验证密码功能状态 */
CM02_LockState_Type_Query_VerifyPassword_Status = 3 ,
/** 打开仪表开锁验证密码功能(需要携带密码) */
CM02_LockState_Type_VerifyPassword_On = 4 ,
/** 关闭仪表开锁验证密码功能(需要携带密码) */
CM02_LockState_Type_VerifyPassword_Off = 5 ,
};

/** 结果枚举定义 */
@@ -113,5 +125,29 @@ typedef NS_ENUM(NSInteger, CM02_DeviceType) {
CM02_DeviceType_BlePassThrough = 1 ,
};

/** 导航状态 */
typedef NS_ENUM(NSInteger, ElectricScooter_NavigationState) {
/** 关闭导航 */
ElectricScooter_NavigationState_Off = 0 ,
/** 开启导航 */
ElectricScooter_NavigationState_On ,
/** 更新导航数据 */
ElectricScooter_NavigationState_UpdateData ,
};

/** 导航方向代码 */
typedef NS_ENUM(NSInteger, ElectricScooter_NavigationPushCode) {
/** 直行 */
ElectricScooter_NavigationPushCode_Straight = 0 ,
/** 左转 */
ElectricScooter_NavigationPushCode_TurnLeft ,
/** 右转 */
ElectricScooter_NavigationPushCode_TurnRight ,
/** 左转掉头 */
ElectricScooter_NavigationPushCode_TurnRoundLeft ,
/** 右转掉头 */
ElectricScooter_NavigationPushCode_TurnRoundRight ,
};


#endif /* ELCM02_BleHeader_h */

+ 28
- 6
AILinkBleSDKDemo/AILinkBleSDK.framework/Headers/ELCM02_BleManager.h Переглянути файл

@@ -53,7 +53,7 @@ NS_ASSUME_NONNULL_BEGIN
/** CM02回复仪表编号,硬件版本和软件版本号 */
- (void)CM02ManagerBackDashboardCode:(NSString *)code hardwareVersion:(NSString *)hardwareVersion softwareVersion:(NSString *)softwareVersion;

#pragma mark - 仪表OTA
#pragma mark - 仪表OTA

/** 返回ota是否可以升级和可以接收的最大长度 */
- (void)CM02ManagerBackCanOTA:(BOOL)can maxLength:(int)length;
@@ -64,14 +64,14 @@ NS_ASSUME_NONNULL_BEGIN
/** 返回ota升级结果 */
- (void)CM02ManagerBackOTAUpdateResult:(BOOL)result;

#pragma mark -
#pragma mark -

@end

@interface ELCM02_BleManager : ELBluetoothManager

@property (nonatomic, weak) id<CM02_BleDelegate> CM02Delegate;
@property (nonatomic, assign) ELSupportDeviceType deviceType;
+ (ELCM02_BleManager *)shareManager;

///** 查询接收端类型及支持的功能 */
@@ -106,9 +106,18 @@ NS_ASSUME_NONNULL_BEGIN
/** 修改密码 */
- (void)updatePasswordWithOldPassword:(NSString *)oldPassword newPassword:(NSString *)newPassword;

/** 解锁或者锁车(锁车无需传密码) */
/** 解锁或者锁车(锁车无需传密码) 、查询仪表开锁验证密码功能状态、打开/关闭仪表开锁验证密码功能(需要携带密码)*/
- (void)setLockState:(enum CM02_LockState_Type)lock password:(NSString *)password;

//查询仪表开锁验证密码功能状态
- (void)requestUnlockPasswordState;

//打开仪表开锁验证密码功能(需要携带密码)
- (void)setUnlockPasswordOn:(NSString *)password;

//关闭仪表开锁验证密码功能(需要携带密码)
- (void)setUnlockPasswordOff:(NSString *)password;

/** 查询售后密码 */
- (void)getAfterSalesPassword;

@@ -128,7 +137,20 @@ NS_ASSUME_NONNULL_BEGIN
/** 查询仪表盘固件版本 */
- (void)getDashboardVersion;

#pragma mark - 仪表OTA
/** 导航推送
* @param state : 更新导航数据 、开启导航、关闭导航
* @param code : 导航方向代码
* @param segmentRemainDistance : 当前方向剩余路程 m
* @param routeRemainDistance : 总剩余路程 m
*/
- (void)setNavigationPushWithState:(enum ElectricScooter_NavigationState)state code:(enum ElectricScooter_NavigationPushCode)code segmentRemainDistance:(NSInteger)segmentRemainDistance routeRemainDistance:(NSInteger)routeRemainDistance;

/// 当前时区
/// @param positive YES:东时区,NO:西时区
/// @param value 时区,范围0-12
- (void)setCurrentTimeZoneWithPositive:(BOOL)positive value:(NSUInteger)value;

#pragma mark - 仪表OTA

/** 发送OTA开始指令
* @param size : ota文件长度
@@ -143,7 +165,7 @@ NS_ASSUME_NONNULL_BEGIN
/** 发送OTA完成指令 */
- (void)sendEndOTACommand;

#pragma mark - 断开设备清除缓存信息
#pragma mark - 断开设备清除缓存信息

- (void)cleanData;


+ 7
- 0
AILinkBleSDKDemo/AILinkBleSDK.framework/Headers/ELExSupportDeviceType.h Переглянути файл

@@ -107,6 +107,10 @@ typedef NS_ENUM(NSUInteger, ELSupportDeviceType) {

ELSupportDeviceTypeAIFitScale = 0x005E, //好身材体脂秤(蓝牙连接)
ELSupportDeviceTypeBodyCompositionAnalyzer = 0x0065, //人体成份分析仪(蓝牙连接)

ELSupportDeviceTypeHMIBodyFatScale = 0x0076, //HMI体脂秤 CID:0x0076(118)
ELSupportDeviceTypeBroadcastScale = (0xffff +0x01) , //655536 Broadcast body fat scale(AILink广播体脂秤)
ELSupportDeviceTypeBroadcastHeightGauge = (0xffff + 0x03) , //65538 广播身高仪
ELSupportDeviceTypeBroadcastScale_Lingyang = (0xffff +0x16) , //65557 凌阳广播体脂秤
@@ -120,6 +124,9 @@ typedef NS_ENUM(NSUInteger, ELSupportDeviceType) {
ELSupportDeviceTypeBroadcastScale_T6 = (0xffff + 0x09) , //65544 T6广播体脂秤

ELSupportDeviceType_dualFrequencyEightelectrodeMCUAlgorithm = 0x0068, //双频八电极MCU算法秤
ELSupportDeviceTypeElectricScooter_CM01TouchScreen = 0x0025, // 电动滑板车(邦凯定制)-CM01触摸屏
ELSupportDeviceTypeElectricScooter_4G = 0x0046, //电动滑板车(4G)
};

#endif /* ELExSupportDeviceType_h */

+ 17
- 0
AILinkBleSDKDemo/AILinkBleSDK.framework/Headers/ELHeightBodyFatScaleBleManager.h Переглянути файл

@@ -14,6 +14,8 @@ NS_ASSUME_NONNULL_BEGIN

@class ELHeightBodyFatScaleBleWeightBodyModel;
@class ELPeripheralModel;
@class ELEightScaleBleDataModel;


@protocol ELHeightBodyFatScaleBleDelegate <NSObject>

@@ -37,6 +39,10 @@ NS_ASSUME_NONNULL_BEGIN
/** MCU回复单位设置结果 */
- (void)heightBodyFatScaleManagerReportUnitResult:(HeightBodyFatScale_SetupResult)result;

/** 人体成份分析仪 MCU回复单位设置结果 */
- (void)heightBodyFatScaleManagerReportHeightUnit:(ELDeviceHeightUnit)heightUnit weightUnit:(ELDeviceWeightUnit)weightUnit;


/** MCU回复工作模式设置结果 */
- (void)heightBodyFatScaleManagerWorkModeResult:(HeightBodyFatScale_SetupResult)result;

@@ -54,6 +60,9 @@ NS_ASSUME_NONNULL_BEGIN
- (void)heightBodyFatScaleManagerReportDevStateWithWorkMode:(HeightBodyFatScale_WorkModeType)mode power:(NSInteger)power charging:(BOOL)charging weightUnit:(ELDeviceWeightUnit)weightUnit height:(ELDeviceHeightUnit)heightUnit videoState:(BOOL)video DEPRECATED_MSG_ATTRIBUTE("use 'voiceState' instead");
- (void)heightBodyFatScaleManagerReportDevStateWithWorkMode:(HeightBodyFatScale_WorkModeType)mode power:(NSInteger)power charging:(BOOL)charging weightUnit:(ELDeviceWeightUnit)weightUnit height:(ELDeviceHeightUnit)heightUnit voiceState:(BOOL)voice;

/** MCU回复设备支持模式 */
- (void)heightBodyFatScaleManagerReportDevModeArray:(NSArray *)modeArray;

#pragma mark - 身高体脂秤模式

/** MCU上报称重状态 */
@@ -81,9 +90,17 @@ NS_ASSUME_NONNULL_BEGIN
/** MCU上报身高数据 */
- (void)heightBodyFatScaleManagerReportHeightDataWithHeight:(NSInteger)height unit:(ELDeviceHeightUnit)unit point:(NSInteger)point;


/** MCU上报体脂数据 */
- (void)heightBodyFatScaleManagerReportBodyFatDataWithDataModel:(ELHeightBodyFatScaleBleWeightBodyModel *)model;

/** // 人体成份分析仪 MCU上报阻抗数据
*/
- (void)heightBodyFatScaleManagerReportAdcDataWithImpedanceState:(HeightBodyFatScale_AdcStateType)state bleDataModelWith:(ELEightScaleBleDataModel *)bleDataModel UseAppAlgorithm:(BOOL)useAppAlgorithm;

///// 人体成份分析仪 MCU请求补全体脂数据
- (void)heightBodyFatScaleManagerCompletionBodyFatDataWith:(ELEightScaleBleDataModel *)bleDataModel;

#pragma mark - 抱婴模式

/** MCU上报称重状态

+ 25
- 0
AILinkBleSDKDemo/AILinkBleSDK.framework/Headers/ELHeightBodyFatScaleBleWeightBodyModel.h Переглянути файл

@@ -39,6 +39,31 @@ NS_ASSUME_NONNULL_BEGIN
@property (nonatomic, assign) NSUInteger obesityGrade;



//以下10个数据的单位以单位和小数点以weight的为准
//体脂-右上
@property (nonatomic, assign) NSUInteger fatMassRightTop;
//体脂-右下
@property (nonatomic, assign) NSUInteger fatMassRightBottom;
//体脂-左上
@property (nonatomic, assign) NSUInteger fatMassLeftTop;
//体脂-左下
@property (nonatomic, assign) NSUInteger fatMassLeftBottom;
//体脂-躯干
@property (nonatomic, assign) NSUInteger fatMassBody;
//肌肉-右上
@property (nonatomic, assign) NSUInteger musleMassRightTop;
//肌肉-右下
@property (nonatomic, assign) NSUInteger musleMassRightBottom;
//肌肉-左上
@property (nonatomic, assign) NSUInteger musleMassLeftTop;
//肌肉-左下
@property (nonatomic, assign) NSUInteger musleMassLeftBottom;
//肌肉-躯干
@property (nonatomic, assign) NSUInteger musleMassBody;


@end

NS_ASSUME_NONNULL_END


+ 28
- 3
AILinkBleSDKDemo/AILinkBleSDK.framework/Headers/ELThermometerBleManager.h Переглянути файл

@@ -23,6 +23,12 @@ typedef NS_ENUM(NSInteger , ThermometerBleDataType) {
ThermometerBleDataType_GetRecordData = 0x03 ,
/// 6.2.3返回历史数据
ThermometerBleDataType_BackRecordData = 0x04 ,
/// APP获取历史记录
ThermometerBleDataType_RequestHistoryRecord = 0x10,
/// 返回历史记录
ThermometerBleDataType_ReceiveHistoryRecord = 0x11,
/// 6.2.4获取设备支持功能/返回支持功能
ThermometerBleDataType_SupportFunction = 0x80 ,
@@ -32,8 +38,8 @@ typedef NS_ENUM(NSInteger , ThermometerBleDataType) {
/** The MCU replies to the setting result(MCU回复设置结果) */
ThermometerBleDataType_BackSendUnit = 0x82 ,
/// 6.2.6获取设备当前单位/返回当前单位
ThermometerBleDataType_NowUnit = 0x83 ,
/// App同步unix时间给MCU
ThermometerBleDataType_AsyncUnixTime = 0x83 ,
/// 6.2.7获取设备测温模式/返回测试模式
ThermometerBleDataType_GetMeasureTemMode = 0x84 ,
@@ -96,7 +102,17 @@ typedef NS_ENUM(NSInteger, ThermometerBleMeasureTemMode) {
ThermometerBleMeasureTemMode_Repeatedly = 0x01 ,
};


/// 获取历史记录状态定义
typedef NS_ENUM(NSInteger, ThermometerBleRequestHistoryRecordStatus) {
/// 开始获取历史数据
ThermometerBleRequestHistoryRecordStatus_Start = 0x00 ,
/// 接收到一帧,请发下一帧
ThermometerBleRequestHistoryRecordStatus_Continous = 0x01 ,
/// 数据接收完毕
ThermometerBleRequestHistoryRecordStatus_End = 0x02 ,
/// 删除历史记录
ThermometerBleRequestHistoryRecordStatus_Delete = 0x03 ,
};

/// 体温计蓝牙代理方法
@protocol ELThermometerBleDelegate <NSObject>
@@ -165,6 +181,12 @@ typedef NS_ENUM(NSInteger, ThermometerBleMeasureTemMode) {
/** App release unit settings(app下发单位设置 )*/
- (void)changeThermometerUnit:(ELDeviceTemperatureUnit)unit;

/// 同步unix时间
- (void)setUnixTime:(long long)unixTime;

/// 同步北京时间
- (void)setBeijingTimeWithYear:(UInt8)year month:(UInt8)month day:(UInt8)day hour:(UInt8)hour minute:(UInt8)minute second:(UInt8)second weekday:(UInt8)weakday;

/// 获取设备当前单位
- (void)getNowUnit;

@@ -182,6 +204,9 @@ typedef NS_ENUM(NSInteger, ThermometerBleMeasureTemMode) {
/// @param model 不需要设置时间字段和dataType
- (void)setHighTemAlarmValue:(ELThermometerBleModel *)model;

/// APP 获取历史记录
- (void)getHistoryRecordWithStatus:(ThermometerBleRequestHistoryRecordStatus)status;

@end

NS_ASSUME_NONNULL_END

BIN
AILinkBleSDKDemo/AILinkBleSDK.framework/Info.plist Переглянути файл


BIN
AILinkBleSDKDemo/AILinkBleSDK.framework/PrivacyInfo.bundle/Info.plist Переглянути файл


+ 171
- 48
AILinkBleSDKDemo/DeviceDemo/05B_WIFI_BLE_BloodPressure/ELWIFIBloodPressureVC.m Переглянути файл

@@ -42,9 +42,9 @@
NSString *log = @"开始扫描";
[self addLog:log];
self.urlTexField.text = @"iot.elink.com";
self.portTexField.text = @"80";
self.pathTexField.text = @"";
self.urlTexField.text = self.defaultURL;//@"iot.elink.com";
self.portTexField.text = self.defaultPort;//@"80";
self.pathTexField.text = self.defaultPath;//@"";
self.dataSource = [NSMutableArray array];
}
@@ -61,6 +61,21 @@

#pragma mark - Action

- (IBAction)requestWifiNameAction:(id)sender {
[[ElBloodBleWifiManager shareManager] getBluetoothInfoWithELInetGetCmdType:ELInetGetCmdTypeBleWifiName];

NSString *log = @"获取当前 wifi 名称";
[self addLog:log];
}

- (IBAction)requestDeviceStatusAcion:(id)sender {
//获取蓝牙和WiFi连接状态
[[ElBloodBleWifiManager shareManager] getBluetoothInfoWithELInetGetCmdType:(ELInetGetCmdTypeGetConnectState)];
NSString *log = [NSString stringWithFormat:@"获取蓝牙和WiFi连接状态"];
[self addLog:log];
}

- (IBAction)requestWifiListAction:(id)sender {
[self.dataSource removeAllObjects];
[self.tableView reloadData];
@@ -75,6 +90,10 @@
NSString *port = self.portTexField.text;
NSString *path = self.pathTexField.text;
self.defaultURL = url;
self.defaultPort = port;
self.defaultPath = path;
[[ElBloodBleWifiManager shareManager] setDevAccessIpAddress:url portNumber:port.intValue path:path];
NSString *log = @"设置 服务器信息";
@@ -90,6 +109,14 @@
[self addLog:log];
}

- (IBAction)requestDeviceIdAcion:(id)sender {
//获取wifi设备的SN号,即设备id
[[ElBloodBleWifiManager shareManager] getBluetoothInfoWithELInetGetCmdType:ELInetGetCmdTypeBleWifiGetSNNumber];
NSString *log = @"获取 设备ID";
[self addLog:log];
}

- (IBAction)switchUintAction:(id)sender {
static BOOL value = YES;
if (value) {
@@ -136,6 +163,25 @@
[self addLog:log];
}

- (IBAction)restoreFactoryAction:(id)sender {
UIAlertController *alert = [UIAlertController alertControllerWithTitle:@"恢复出厂设置" message:@"确认要恢复出厂设置吗?" preferredStyle:UIAlertControllerStyleAlert];
UIAlertAction *conform = [UIAlertAction actionWithTitle:@"确认" style:UIAlertActionStyleDefault handler:^(UIAlertAction * _Nonnull action) {
NSLog(@"点击了确认按钮");
[[ElBloodBleWifiManager shareManager] setFactoryDataReset];
NSString *log = @"恢复出厂设置";
[self addLog:log];
}];
UIAlertAction *cancel = [UIAlertAction actionWithTitle:@"取消" style:UIAlertActionStyleCancel handler:^(UIAlertAction * _Nonnull action) {
NSLog(@"点击了取消按钮");
}];
[alert addAction:conform];
[alert addAction:cancel];
[self presentViewController:alert animated:YES completion:nil];
}

- (IBAction)clearAction:(id)sender {
self.logTextView.text = @"";
}
@@ -143,6 +189,35 @@
- (IBAction)shareLogAction:(id)sender {
}

#pragma mark -

- (NSString *)defaultURL {
return [[NSUserDefaults standardUserDefaults] stringForKey:@"defaultURL"];
}

- (void)setDefaultURL:(NSString *)defautlURL {
[[NSUserDefaults standardUserDefaults] setObject:defautlURL forKey:@"defaultURL"];
[[NSUserDefaults standardUserDefaults] synchronize];
}

- (NSString *)defaultPort {
return [[NSUserDefaults standardUserDefaults] stringForKey:@"defaultPort"];
}

- (void)setDefaultPort:(NSString *)defaultPort {
[[NSUserDefaults standardUserDefaults] setObject:defaultPort forKey:@"defaultPort"];
[[NSUserDefaults standardUserDefaults] synchronize];
}

- (NSString *)defaultPath {
return [[NSUserDefaults standardUserDefaults] stringForKey:@"defaultPath"];
}

- (void)setDefaultPath:(NSString *)defaultPath {
[[NSUserDefaults standardUserDefaults] setObject:defaultPath forKey:@"defaultPath"];
[[NSUserDefaults standardUserDefaults] synchronize];
}
#pragma mark - textField Delegate

- (void)textFieldDidEndEditing:(UITextField *)textField {
@@ -231,9 +306,14 @@
// NSString *log = @"正在连接...";
// [self addLog:log];
} else if (state == ELBluetoothStateDidValidationPass) {
self.bleStatusLabel.text = @"连接成功";
NSString *log = @"连接成功";
self.bleStatusLabel.text = [@"连接成功 " stringByAppendingString:self.per.macAddressString];
NSString *log = [@"连接成功 " stringByAppendingString:self.per.macAddressString];
[self addLog:log];
// //获取蓝牙和WiFi连接状态
// [[ElBloodBleWifiManager shareManager] getBluetoothInfoWithELInetGetCmdType:(ELInetGetCmdTypeGetConnectState)];
// log = [NSString stringWithFormat:@"获取蓝牙和WiFi连接状态"];
// [self addLog:log];
} else if (state == ELBluetoothStateDidDisconnect) {
self.bleStatusLabel.text = @"连接已断开";
NSString *log = @"连接已断开";
@@ -357,9 +437,9 @@ Callback WIFI password(回调WIFI密码)
[[ElBloodBleWifiManager shareManager] bleWifiSetupWifiConnect:YES];
} else if (type == ELInetSetCmdTypeBleWifiSetConnectWifi){
//获取连接状态,更新Wi-Fi列表
[self.dataSource removeAllObjects];
[self.tableView reloadData];
[[ElBloodBleWifiManager shareManager] getBluetoothInfoWithELInetGetCmdType:ELInetGetCmdTypeBleWifiGetNearbyWifi];
// [self.dataSource removeAllObjects];
// [self.tableView reloadData];
// [[ElBloodBleWifiManager shareManager] getBluetoothInfoWithELInetGetCmdType:ELInetGetCmdTypeBleWifiGetNearbyWifi];
}
} else {
//TODO:Wifi配置过程中失败的情况自行处理
@@ -377,65 +457,108 @@ Callback WIFI password(回调WIFI密码)
//失败
}
NSString *log = [NSString stringWithFormat:@"bleWifiReceiveWifiSNCode :%@", @(code)];
NSString *log = [NSString stringWithFormat:@"会话码(deviceId): %@", @(code)];
[self addLog:log];
}

/** 返回wifi名称 */
- (void)bleWifiName:(NSString *)wifiName {
NSLog(@"## bleWifiName() wifiName:%@", wifiName);
NSLog(@"## bleWifiName() wifi名称: %@", wifiName);
NSString *log = [NSString stringWithFormat:@"bleWifiName:%@", wifiName];
NSString *log = [NSString stringWithFormat:@"wifi名称: %@", wifiName];
[self addLog:log];
}

- (void)bluetoothManagerReceiveMCUConnectedState:(struct ELMCUStateStruct)stateStrct {
NSLog(@"## bluetoothManagerReceiveMCUConnectedState");
BleWiFiConnectState wifiState = stateStrct.wifiState;
//请求会话码
[[ElBloodBleWifiManager shareManager] getBluetoothInfoWithELInetGetCmdType:ELInetGetCmdTypeBleWifiGetSNNumber];
//MARK:1.WiFi配置提示用户配网
//TODO:注意:wifi配置过程必须保持蓝牙与设备的连接
if (wifiState == BleWiFiConnectStateNoWiFi) {
//1.如果没有配网,则提示用户去配网
//MARK:2.WiFi配置先获取wifi列表
[self.dataSource removeAllObjects];
[self.tableView reloadData];
[[ElBloodBleWifiManager shareManager] getBluetoothInfoWithELInetGetCmdType:ELInetGetCmdTypeBleWifiGetNearbyWifi];
NSString *log = @"获取附近 wifi 列表";
[self addLog:log];
} else if (wifiState == BleWiFiConnectStateSuccess) {
[[ElBloodBleWifiManager shareManager] getBluetoothInfoWithELInetGetCmdType:ELInetGetCmdTypeBleWifiName];
NSString *log = @"获取当前 wifi 名称";
[self addLog:log];
} else {
// //MARK:2.没网也可以获取Wi-Fi列表,如果需要更新Wi-Fi的话
//- (void)bluetoothManagerReceiveMCUConnectedState:(struct ELMCUStateStruct)stateStrct {
// NSLog(@"## bluetoothManagerReceiveMCUConnectedState");
// BleWiFiConnectState wifiState = stateStrct.wifiState;
//
//// //请求会话码
//// [[ElBloodBleWifiManager shareManager] getBluetoothInfoWithELInetGetCmdType:ELInetGetCmdTypeBleWifiGetSNNumber];
// //MARK:1.WiFi配置提示用户配网
// //TODO:注意:wifi配置过程必须保持蓝牙与设备的连接
// if (wifiState == BleWiFiConnectStateNoWiFi) {
// //1.如果没有配网,则提示用户去配网
// //MARK:2.WiFi配置先获取wifi列表
// [self.dataSource removeAllObjects];
// [self.tableView reloadData];
// [[ElBloodBleWifiManager shareManager] getBluetoothInfoWithELInetGetCmdType:ELInetGetCmdTypeBleWifiGetNearbyWifi];
// NSString *log = @"获取附近 wifi 列表";
// [self addLog:log];
// } else if (wifiState == BleWiFiConnectStateSuccess) {
// [[ElBloodBleWifiManager shareManager] getBluetoothInfoWithELInetGetCmdType:ELInetGetCmdTypeBleWifiName];
//
// NSString *log = @"获取当前 wifi 名称";
// [self addLog:log];
// } else {
//// //MARK:2.没网也可以获取Wi-Fi列表,如果需要更新Wi-Fi的话
//// [self.dataSource removeAllObjects];
//// [self.tableView reloadData];
//// [[ElBloodBleWifiManager shareManager] getBluetoothInfoWithELInetGetCmdType:ELInetGetCmdTypeBleWifiGetNearbyWifi];
// }
//
// ///MARK:9.wifi配置结果
// //wifi相关的其他指令和数据接收,请查看ELBluetoothManager.h文件
// if (stateStrct.wifiState == BleWiFiConnectStateSuccess) {
// //成功
// //MARK:10.获取wifi设备的SN号,即设备id
// [[ElBloodBleWifiManager shareManager] getBluetoothInfoWithELInetGetCmdType:ELInetGetCmdTypeBleWifiGetSNNumber];
// }
//}

-(void)bluetoothManagerReceiveWMState:(ELWMStateStruct)stateStrct {
NSString *bleString = @"0_无连接";
if (stateStrct.bleState == WMBleStateConnected) {
bleString = @"1_已连接";
} else if (stateStrct.bleState == WMBleStatePaired) {
bleString = @"2_配对完成";
}
///MARK:9.wifi配置结果
//wifi相关的其他指令和数据接收,请查看ELBluetoothManager.h文件
if (stateStrct.wifiState == BleWiFiConnectStateSuccess) {
//成功
//MARK:10.获取wifi设备的SN号,即设备id
[[ElBloodBleWifiManager shareManager] getBluetoothInfoWithELInetGetCmdType:ELInetGetCmdTypeBleWifiGetSNNumber];
NSString *wifiString = @"0_未配置AP";
if (stateStrct.wifiState == WMWiFiStateConnectAPFail) {
wifiString = @"1_连接AP失败";
} else if (stateStrct.wifiState == WMWiFiStateConnectServerFail) {
wifiString = @"2_与服务器通讯失败";
} else if (stateStrct.wifiState == WMWiFiStateConnectedAP) {
wifiString = @"3_成功连接上AP";
} else if (stateStrct.wifiState == WMWiFiStateConnectingAP) {
wifiString = @"4_正在连接AP";
}
}

-(void)bluetoothManagerReceiveWMState:(ELWMStateStruct)stateStrct {
NSLog(@"## bluetoothManagerReceiveMCUConnectedState");
}

-(void)bluetoothManagerReceiveWMStateFailCode:(WMWorkStateFailCode)failCode {
NSLog(@"## bluetoothManagerReceiveMCUConnectedState");
NSString *workString = @"0_唤醒";
if (stateStrct.workState == WMWorkStateSleep) {
workString = @"1_进入休眠";
} else if (stateStrct.workState == WMWorkStateReady) {
workString = @"2_模块准备就绪";
}
NSString *errorString = @"0_未知原因";
if (stateStrct.failCode == WMWorkStateFailCodeAPSignalBad) {
errorString = @"1_AP信号差";
} else if (stateStrct.failCode == WMWorkStateFailCodeWrongPassword) {
errorString = @"2_密码错误";
} else if (stateStrct.failCode == WMWorkStateFailCodeNoIP) {
errorString = @"3_获取不到IP";
} else {
errorString = @"";
}
NSLog(@"## bluetoothManagerReceiveMCUConnectedState()模块状态 蓝牙状态: %@, wifi状态: %@, 工作状态: %@ 失败原因: %@", bleString, wifiString, workString, errorString);
if (errorString.length > 0) {
NSString *log = [NSString stringWithFormat:@"模块状态 蓝牙状态: %@, wifi状态: %@, 工作状态: %@ 失败原因: %@", bleString, wifiString, workString, errorString];
[self addLog:log];
} else {
NSString *log = [NSString stringWithFormat:@"模块状态\n 蓝牙状态: %@,\n wifi状态: %@,\n 工作状态: %@", bleString, wifiString, workString];
[self addLog:log];
}
}

//-(void)bluetoothManagerReceiveWMStateFailCode:(WMWorkStateFailCode)failCode {
// NSLog(@"## bluetoothManagerReceiveMCUConnectedState");
//
//}

#pragma mark - ELBloodBleWifiManagerDelegate

/**

+ 58
- 16
AILinkBleSDKDemo/DeviceDemo/05B_WIFI_BLE_BloodPressure/ELWIFIBloodPressureVC.xib Переглянути файл

@@ -1,9 +1,9 @@
<?xml version="1.0" encoding="UTF-8"?>
<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="21701" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" useSafeAreas="YES" colorMatched="YES">
<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="22505" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" useSafeAreas="YES" colorMatched="YES">
<device id="retina6_12" orientation="portrait" appearance="light"/>
<dependencies>
<deployment version="4352" identifier="iOS"/>
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="21679"/>
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="22504"/>
<capability name="Safe area layout guides" minToolsVersion="9.0"/>
<capability name="System colors in document resources" minToolsVersion="11.0"/>
<capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
@@ -88,19 +88,39 @@
<outlet property="delegate" destination="-1" id="dnB-TL-dMo"/>
</connections>
</tableView>
<button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" buttonType="system" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="BzV-lX-bbk">
<rect key="frame" x="8" y="317" width="69.666666666666671" height="35"/>
<state key="normal" title="Button"/>
<buttonConfiguration key="configuration" style="filled" title="wifi名"/>
<connections>
<action selector="requestWifiNameAction:" destination="-1" eventType="touchUpInside" id="Cll-bf-THn"/>
</connections>
</button>
<button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" buttonType="system" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="mMG-sS-kXc">
<rect key="frame" x="229.33333333333334" y="317" width="123.66666666666666" height="35"/>
<rect key="frame" x="264" y="317" width="89" height="35"/>
<state key="normal" title="Button"/>
<buttonConfiguration key="configuration" style="filled" title="获取wifi 列表"/>
<buttonConfiguration key="configuration" style="filled" title="wifi 列表"/>
<connections>
<action selector="requestWifiListAction:" destination="-1" eventType="touchUpInside" id="kAf-G6-Pi8"/>
</connections>
</button>
<button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" buttonType="system" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="OWb-s3-hjD">
<rect key="frame" x="133.66666666666666" y="317" width="94" height="35"/>
<state key="normal" title="Button"/>
<buttonConfiguration key="configuration" style="filled" title="设备状态"/>
<connections>
<action selector="requestDeviceStatusAcion:" destination="-1" eventType="touchUpInside" id="2s0-hz-E2t"/>
</connections>
</button>
</subviews>
<color key="backgroundColor" systemColor="systemBackgroundColor"/>
<constraints>
<constraint firstItem="OWb-s3-hjD" firstAttribute="centerX" secondItem="31J-19-s41" secondAttribute="centerX" id="772-0r-j6p"/>
<constraint firstAttribute="bottom" secondItem="OWb-s3-hjD" secondAttribute="bottom" constant="8" id="8ZO-0P-ys1"/>
<constraint firstAttribute="height" constant="360" id="8u9-ew-SWT"/>
<constraint firstAttribute="trailing" secondItem="mMG-sS-kXc" secondAttribute="trailing" constant="8" id="DhH-2G-SjA"/>
<constraint firstItem="BzV-lX-bbk" firstAttribute="leading" secondItem="31J-19-s41" secondAttribute="leading" constant="8" id="Guj-8h-L8n"/>
<constraint firstAttribute="bottom" secondItem="BzV-lX-bbk" secondAttribute="bottom" constant="8" id="N1Q-aX-RVV"/>
<constraint firstItem="29h-tk-062" firstAttribute="leading" secondItem="31J-19-s41" secondAttribute="leading" id="RvA-4i-asg"/>
<constraint firstAttribute="bottom" secondItem="29h-tk-062" secondAttribute="bottom" id="fTi-ml-ReU"/>
<constraint firstAttribute="bottom" secondItem="mMG-sS-kXc" secondAttribute="bottom" constant="8" id="jRj-dV-3d6"/>
@@ -123,18 +143,18 @@
<textInputTraits key="textInputTraits"/>
</textField>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="Port:" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="TV8-xg-2Rl">
<rect key="frame" x="8.0000000000000036" y="69" width="49.333333333333343" height="21"/>
<rect key="frame" x="8" y="69" width="40.666666666666664" height="21"/>
<fontDescription key="fontDescription" type="system" pointSize="17"/>
<nil key="textColor"/>
<nil key="highlightedColor"/>
</label>
<textField opaque="NO" contentMode="scaleToFill" horizontalHuggingPriority="248" contentHorizontalAlignment="left" contentVerticalAlignment="center" borderStyle="roundedRect" textAlignment="natural" minimumFontSize="17" translatesAutoresizingMaskIntoConstraints="NO" id="yit-et-mIS">
<rect key="frame" x="65.333333333333343" y="62.666666666666629" width="287.66666666666663" height="34"/>
<rect key="frame" x="56.666666666666657" y="62.666666666666629" width="296.33333333333337" height="34"/>
<fontDescription key="fontDescription" type="system" pointSize="14"/>
<textInputTraits key="textInputTraits"/>
</textField>
<textField opaque="NO" contentMode="scaleToFill" horizontalHuggingPriority="248" contentHorizontalAlignment="left" contentVerticalAlignment="center" borderStyle="roundedRect" textAlignment="natural" minimumFontSize="17" translatesAutoresizingMaskIntoConstraints="NO" id="54X-qt-4AG">
<rect key="frame" x="68" y="107.66666666666663" width="285" height="34"/>
<rect key="frame" x="59.333333333333343" y="107.66666666666663" width="293.66666666666663" height="34"/>
<fontDescription key="fontDescription" type="system" pointSize="14"/>
<textInputTraits key="textInputTraits"/>
</textField>
@@ -148,7 +168,7 @@
</connections>
</button>
<button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" buttonType="system" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="Hu4-ND-jL9">
<rect key="frame" x="294.33333333333331" y="157" width="58.666666666666686" height="35"/>
<rect key="frame" x="82.666666666666671" y="157" width="58.666666666666671" height="35"/>
<inset key="imageEdgeInsets" minX="0.0" minY="0.0" maxX="2.2250738585072014e-308" maxY="0.0"/>
<state key="normal" title="Button"/>
<buttonConfiguration key="configuration" style="filled" title="读取"/>
@@ -156,8 +176,17 @@
<action selector="requestServerInfoAcion:" destination="-1" eventType="touchUpInside" id="9sH-7O-oVc"/>
</connections>
</button>
<button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" buttonType="system" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="IXX-Pw-cTG">
<rect key="frame" x="276" y="157" width="77" height="35"/>
<inset key="imageEdgeInsets" minX="0.0" minY="0.0" maxX="2.2250738585072014e-308" maxY="0.0"/>
<state key="normal" title="Button"/>
<buttonConfiguration key="configuration" style="filled" title="读取ID"/>
<connections>
<action selector="requestDeviceIdAcion:" destination="-1" eventType="touchUpInside" id="l23-2p-AIJ"/>
</connections>
</button>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="Path:" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="jUZ-AG-RFL">
<rect key="frame" x="8" y="114" width="52" height="21"/>
<rect key="frame" x="8" y="114" width="43.333333333333336" height="21"/>
<fontDescription key="fontDescription" type="system" pointSize="17"/>
<nil key="textColor"/>
<nil key="highlightedColor"/>
@@ -165,7 +194,6 @@
</subviews>
<color key="backgroundColor" systemColor="systemBackgroundColor"/>
<constraints>
<constraint firstAttribute="trailing" secondItem="Hu4-ND-jL9" secondAttribute="trailing" constant="8" id="7MZ-xz-dwV"/>
<constraint firstItem="TV8-xg-2Rl" firstAttribute="top" secondItem="Mec-fH-uxd" secondAttribute="bottom" constant="24" id="Aq2-tv-HYZ"/>
<constraint firstItem="Mec-fH-uxd" firstAttribute="top" secondItem="t03-yu-cqg" secondAttribute="top" constant="24" id="BIV-xf-Hfq"/>
<constraint firstItem="qEW-eA-90Z" firstAttribute="leading" secondItem="Mec-fH-uxd" secondAttribute="trailing" constant="8" id="Bx8-zO-Nfq"/>
@@ -178,9 +206,12 @@
<constraint firstItem="54X-qt-4AG" firstAttribute="centerY" secondItem="jUZ-AG-RFL" secondAttribute="centerY" id="J2t-rF-Qen"/>
<constraint firstItem="yit-et-mIS" firstAttribute="centerY" secondItem="TV8-xg-2Rl" secondAttribute="centerY" id="JZp-UT-ceZ"/>
<constraint firstItem="TV8-xg-2Rl" firstAttribute="leading" secondItem="t03-yu-cqg" secondAttribute="leading" constant="8" id="NMo-nC-T3p"/>
<constraint firstItem="Hu4-ND-jL9" firstAttribute="leading" secondItem="r1G-Pa-LaR" secondAttribute="trailing" constant="16" id="Qra-vo-6dg"/>
<constraint firstItem="r1G-Pa-LaR" firstAttribute="leading" secondItem="t03-yu-cqg" secondAttribute="leading" constant="8" id="R7K-1y-jZW"/>
<constraint firstAttribute="bottom" secondItem="IXX-Pw-cTG" secondAttribute="bottom" constant="8" id="amO-cP-nt3"/>
<constraint firstAttribute="trailing" secondItem="yit-et-mIS" secondAttribute="trailing" constant="8" id="bXo-XR-uvU"/>
<constraint firstAttribute="trailing" secondItem="qEW-eA-90Z" secondAttribute="trailing" constant="8" id="fTu-II-Jt5"/>
<constraint firstAttribute="trailing" secondItem="IXX-Pw-cTG" secondAttribute="trailing" constant="8" id="iId-60-XWf"/>
<constraint firstItem="yit-et-mIS" firstAttribute="leading" secondItem="TV8-xg-2Rl" secondAttribute="trailing" constant="8" id="ou3-vt-M7k"/>
<constraint firstAttribute="height" constant="200" id="uDP-93-x7c"/>
<constraint firstItem="jUZ-AG-RFL" firstAttribute="top" secondItem="TV8-xg-2Rl" secondAttribute="bottom" constant="24" id="w43-3H-5c6"/>
@@ -208,6 +239,15 @@
<action selector="switchSpeechAtion:" destination="-1" eventType="touchUpInside" id="No5-ou-AYf"/>
</connections>
</button>
<button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" buttonType="system" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="DgV-dr-yv8">
<rect key="frame" x="8" y="59" width="93.333333333333329" height="35"/>
<inset key="imageEdgeInsets" minX="0.0" minY="0.0" maxX="2.2250738585072014e-308" maxY="0.0"/>
<state key="normal" title="Button"/>
<buttonConfiguration key="configuration" style="filled" title="开始测量"/>
<connections>
<action selector="startMeasureAction:" destination="-1" eventType="touchUpInside" id="7kX-En-EC0"/>
</connections>
</button>
<button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" buttonType="system" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="Xk8-z8-roi">
<rect key="frame" x="109.33333333333334" y="59" width="93.333333333333343" height="35"/>
<inset key="imageEdgeInsets" minX="0.0" minY="0.0" maxX="2.2250738585072014e-308" maxY="0.0"/>
@@ -217,13 +257,13 @@
<action selector="stopMeasureAction:" destination="-1" eventType="touchUpInside" id="544-Zk-s6x"/>
</connections>
</button>
<button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" buttonType="system" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="DgV-dr-yv8">
<rect key="frame" x="8" y="59" width="93.333333333333329" height="35"/>
<button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" buttonType="system" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="PfS-7r-ESZ">
<rect key="frame" x="259" y="65" width="94" height="35"/>
<inset key="imageEdgeInsets" minX="0.0" minY="0.0" maxX="2.2250738585072014e-308" maxY="0.0"/>
<state key="normal" title="Button"/>
<buttonConfiguration key="configuration" style="filled" title="开始测量"/>
<buttonConfiguration key="configuration" style="filled" title="恢复出厂"/>
<connections>
<action selector="startMeasureAction:" destination="-1" eventType="touchUpInside" id="7kX-En-EC0"/>
<action selector="restoreFactoryAction:" destination="-1" eventType="touchUpInside" id="l8W-fz-9Cm"/>
</connections>
</button>
</subviews>
@@ -236,8 +276,10 @@
<constraint firstItem="DgV-dr-yv8" firstAttribute="leading" secondItem="Or7-ND-XyK" secondAttribute="leading" constant="8" id="GJN-8E-Dpd"/>
<constraint firstAttribute="height" constant="108" id="QS8-L3-8uv"/>
<constraint firstItem="DgV-dr-yv8" firstAttribute="top" secondItem="0Vr-iT-QuB" secondAttribute="bottom" constant="16" id="TAP-ER-p9t"/>
<constraint firstAttribute="trailing" secondItem="PfS-7r-ESZ" secondAttribute="trailing" constant="8" id="WIz-FJ-JJb"/>
<constraint firstItem="Xk8-z8-roi" firstAttribute="top" secondItem="6Nt-Z0-hPE" secondAttribute="bottom" constant="16" id="WTW-9s-pwH"/>
<constraint firstItem="6Nt-Z0-hPE" firstAttribute="top" secondItem="Or7-ND-XyK" secondAttribute="top" constant="8" id="oJ9-I1-mlF"/>
<constraint firstAttribute="bottom" secondItem="PfS-7r-ESZ" secondAttribute="bottom" constant="8" id="tDC-S8-vEL"/>
<constraint firstItem="0Vr-iT-QuB" firstAttribute="top" secondItem="Or7-ND-XyK" secondAttribute="top" constant="8" id="zAf-d1-0ZK"/>
</constraints>
</view>
@@ -293,10 +335,10 @@
</objects>
<resources>
<systemColor name="labelColor">
<color red="0.0" green="0.0" blue="0.0" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
<color white="0.0" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
</systemColor>
<systemColor name="opaqueSeparatorColor">
<color red="0.77647058823529413" green="0.77647058823529413" blue="0.78431372549019607" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
<color red="0.77647058820000003" green="0.77647058820000003" blue="0.7843137255" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
</systemColor>
<systemColor name="systemBackgroundColor">
<color white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>

BIN
AILinkBleSDKDemo/PrivacyInfo.bundle/Info.plist Переглянути файл


+ 1
- 1
README.md Переглянути файл

@@ -16,4 +16,4 @@
| 1.9.0 | 20240603 | larry | 修改 增加 Privacy Manifest |
| 1.9.0(Demo v1.9.2) | 20240628 | larry | 修改 增加 温湿度计 Demo |
| 1.10.0 | 20240910 | larry | 修改 增加 带屏食物探针盒 多探针盒子 |
| 1.11.0 | 20250305 | larry | WIFI 血压计 Demo 优化;SDK问题修复 |

Завантаження…
Відмінити
Зберегти