简体   繁体   English

带有蓝牙4.0的iOS XCode Simulator

[英]iOS XCode Simulator with Bluetooth 4.0

I have a question about using BLE with the iOS Simulator. 我有一个关于将BLE与iOS模拟器一起使用的问题。

I followed these instructions to set up XCode simulator with BLE: http://developer.apple.com/library/ios/#technotes/tn2295/_index.html 我按照以下说明使用BLE设置了XCode模拟器: http : //developer.apple.com/library/ios/#technotes/tn2295/_index.html

I use a Macbook Pro Retina with built-in BLE and a CSR USB BLE Dongle. 我使用具有内置BLE和CSR USB BLE加密狗的Macbook Pro Retina。 Mac OS X discovers the USB Dongle, because it is shown in the System Information. Mac OS X发现USB加密狗,因为它在系统信息中显示。

After that I enter this command: 之后,我输入以下命令:

sudo nvram bluetoothHostControllerSwitchBehavior="never" 须藤nvram bluetoothHostControllerSwitchBehavior =“ never”

to have the Broadcom chip again. 再次拥有Broadcom芯片。

When I start XCode there is no way to turn on Bluetooth, it is always rotating and I always get this on debug: -[CentralManager state] will return the CBCentralManagerStatePoweredOff 当我启动XCode时,无法打开蓝牙,它一直在旋转,并且我总是在调试时得到它:-[CentralManager state]将返回CBCentralManagerStatePoweredOff

So what the problem here? 那么这里出什么问题呢?

Thanks for help! 感谢帮助!

Bye 再见

I had a similar problem. 我有一个类似的问题。 Unplugging and then plugging back in the CSR USB BLE Dongle caused the simulator to immediately switch from rotating to on. 拔下然后再插回CSR USB BLE加密狗会使模拟器立即从旋转状态切换为开启状态。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM