###前提・実現したいこと
iPhoneをiBeaconにして発信しています。送信間隔、またはiBeaconのdidRangeBeaconsInRegionの受信間隔を変更したく、やり方を調べていました。
発信にはCoreBluetoothを使用しています。ご存知の方、どうか教えてください。お願いします。
###該当のソースコード
/************************* 発信のソース *************************/ var myPheripheralManager:CBPeripheralManager! // この変数から、送信間隔を変えたいです /************************* 受信のソース *************************/ // エラーが出て実行できません locationManager?.rx.didRangeBeaconsInRegion .sample(TimeInterval(5, MainScheduler.sharedInstance)) .subscribeNext { (tuple: ([CLBeacon]?, CLBeaconRegion?)) in debugPrint("beacons: \(tuple.0), region: \(tuple.1)") } .addDisposableTo(Disposable)
あなたの回答
tips
プレビュー