質問編集履歴
1
説明不足と文章が足りないからです
test
CHANGED
File without changes
|
test
CHANGED
@@ -1,18 +1,34 @@
|
|
1
1
|
###前提・実現したいこと
|
2
2
|
|
3
|
-
iPhoneをiBeaconにして発信しています。送信間隔を変更したく、やり方を調べていました。
|
3
|
+
iPhoneをiBeaconにして発信しています。送信間隔、またはiBeaconのdidRangeBeaconsInRegionの受信間隔を変更したく、やり方を調べていました。
|
4
4
|
|
5
|
-
発信にはCoreBluetoothを使用しています
|
5
|
+
発信にはCoreBluetoothを使用しています。ご存知の方、どうか教えてください。お願いします。
|
6
6
|
|
7
7
|
###該当のソースコード
|
8
8
|
|
9
9
|
```ここに言語を入力
|
10
10
|
|
11
|
-
|
11
|
+
/************************* 発信のソース *************************/
|
12
12
|
|
13
|
-
//
|
13
|
+
var myPheripheralManager:CBPeripheralManager! // この変数から、送信間隔を変えたいです
|
14
14
|
|
15
|
+
|
16
|
+
|
17
|
+
/************************* 受信のソース *************************/
|
18
|
+
|
19
|
+
// エラーが出て実行できません
|
20
|
+
|
21
|
+
locationManager?.rx.didRangeBeaconsInRegion
|
22
|
+
|
23
|
+
.sample(TimeInterval(5, MainScheduler.sharedInstance))
|
24
|
+
|
25
|
+
.subscribeNext { (tuple: ([CLBeacon]?, CLBeaconRegion?)) in
|
26
|
+
|
15
|
-
|
27
|
+
debugPrint("beacons: \(tuple.0), region: \(tuple.1)")
|
28
|
+
|
29
|
+
}
|
30
|
+
|
31
|
+
.addDisposableTo(Disposable)
|
16
32
|
|
17
33
|
```
|
18
34
|
|
@@ -20,12 +36,4 @@
|
|
20
36
|
|
21
37
|
###試したこと
|
22
38
|
|
23
|
-
http://hamasyou.com/blog/2015/11/25/rxswift-de-ibeacon-false-rangebeaconsinregion-wo-5miao-jian-ge-deshou-kequ-rufang-fa/のサイトのRxSwiftを使用して間隔を変えることを試しましたが、「locationManager.rx
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
###補足情報(言語/FW/ツール等のバージョンなど)
|
28
|
-
|
29
|
-
swift3
|
30
|
-
|
31
|
-
xcode8
|
39
|
+
http://hamasyou.com/blog/2015/11/25/rxswift-de-ibeacon-false-rangebeaconsinregion-wo-5miao-jian-ge-deshou-kequ-rufang-fa/のサイトのRxSwiftを使用して間隔を変えることを試しましたが、「locationManager.rx.didRangeBeaconsInRegion」が使用できませんでした。
|