概要 Objective-cでのBluetooth接続についてまとめました。 CoreBluetoothを使用しIOS端末とBluetooth機器を接続、バッテリー等の機器情報の取得を行います。 以下の流れで情報を取得します。 1.Blutooth機器の検索→Bluetooth機器の情報取得 2.Blutooth機器に接続 3.通信している情報の取得 4.通信内容から機器情報等の取得 環境 Xcide10.3 Objective-c 端末:IOS12.4 Bluetooth機器:TrackR pixel 初期設定 CoreBluetoothをインポートさせ、centralManagerの初期化を行います。 @import CoreBluetooth; @interface ViewController () <CBCentralManagerDelegate, CBPeripheralDe