代码拉取完成,页面将自动刷新
//
// blueToothModel.swift
// 智慧魔盒
//
// Created by 梓简王 on 2017/4/4.
// Copyright © 2017年 DW. All rights reserved.
//
import Foundation
import CoreBluetooth
class blueToothModel {
//设备名字:(必填)
var perName:String?
//服务字段:(必填)
var serviceUUID:CBUUID?
//设备字段:(必填)
var peripheralUUID:CBUUID?
var scanUUIDS:[CBUUID]?
//notify字段:(必填)
var notifyCharacteristicUUID:String?
//writeable/readable字段唯一标识符
var chaUUIDS:[CBUUID]?
//读取状态标识
var isWrite:Bool?
//切入状态标识
var isRead:Bool?
//分包长度:(必填)
var bagLength:Int?
//申请一个中心管理设备
var centerManager: CBCentralManager?
//申请链接的periphere
var connectPer:CBPeripheral?
//申请链接的服务
var connectSer:CBService?
//链接状态记录
var isConnect:Bool?
//申请写入的Character
var targetCha:[CBCharacteristic]?
//申请notice的Character:
var noticCha:CBCharacteristic?
//收到的数据集合
var receiveResult:String?
//报文开头标记:(必填)
var messageHeaderFlag:String?
//报文结尾标记:(必填)
var messageTailFlag:String?
required init(){
perName = nil
serviceUUID = nil
peripheralUUID = nil
scanUUIDS = []
notifyCharacteristicUUID = ""
chaUUIDS = []
isWrite = false
isRead = false
bagLength = 20
centerManager = nil
connectPer = nil
isConnect = false
targetCha = nil
noticCha = nil
connectSer = nil
receiveResult = ""
messageHeaderFlag = ""
messageTailFlag = ""
}
}
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。