iOS模拟器仅显示空白屏幕

时间:2016-01-11 05:57:05

标签: ios ios-simulator xcode7

我已经将我的几个macminis升级到El Capitan 10.11.2并安装了Xcode 7.1。但iOS模拟器显示出一些问题。比如,Xcode 7.1的默认iOS是9.1,当我从SDK 9.1在iOS模拟器中启动任何设备时,它只是向我显示黑屏。

所以要检查一下,我去了Xcode>首选项和下载的SDK 9.0和8.4。当我从SDK 9.0或8.4切换到任何设备时,它们工作正常。但我不知道它的默认SDK 9.1会发生什么。

我在下面尝试了解决问题的方法。

  1. 重新安装Xcode。
  2. 重置设备内容。
  3. 在SDK 9.1下再次删除了设备文件夹和已创建的设备。
  4. 删除并重新创建/ private / tmp /并拥有正确的权限。
  5. 更多。
  6. 他们都没有工作。

    当我切换到SDK 9.1下的任何设备时,我已经粘贴了一些CoreSimulator.log日志。

    CoreSimulator.log

    Jan 10 21:45:21  CoreSimulatorService[331] : Error looking up host support port
    Jan 10 21:45:21  CoreSimulatorService[331] : Error Domain=com.apple.CoreSimulator.SimError Code=159 "Invalid device state" UserInfo={NSLocalizedDescription=Invalid device state}
    Jan 10 21:45:21  CoreSimulatorService[331] : Error Domain=NSPOSIXErrorDomain Code=3 "No such process"
    Jan 10 21:45:21  CoreSimulatorService[331] : Error looking up host support port
    Jan 10 21:45:21  CoreSimulatorService[331] : Error Domain=com.apple.CoreSimulator.SimError Code=159 "Invalid device state" UserInfo={NSLocalizedDescription=Invalid device state}
    Jan 10 21:45:21  CoreSimulatorService[331] : Error Domain=NSPOSIXErrorDomain Code=3 "No such process"
    Jan 10 21:45:21  CoreSimulatorService[331] : Error Domain=NSPOSIXErrorDomain Code=3 "No such process"
    Jan 10 21:45:21  CoreSimulatorService[331] : Error Domain=NSPOSIXErrorDomain Code=3 "No such process"
    Jan 10 21:45:21  CoreSimulatorService[331] : Error Domain=NSPOSIXErrorDomain Code=3 "No such process"
    Jan 10 21:45:21  com.apple.iphonesimulator[447] : Error looking up host support port
    Jan 10 21:45:21  com.apple.iphonesimulator[447] : Error looking up host support port
    Jan 10 21:45:21  com.apple.iphonesimulator[447] : Error looking up host support port

    Simulator.log文件

    Jan 10 20:56:58  Simulator[381] : Error communicating with SimulatorBridge: NSObjectNotAvailableException - Unable to connect to SimulatorBridge
    Jan 10 20:56:58  Simulator[381] : Error communicating with SimulatorBridge: NSObjectNotAvailableException - Unable to connect to SimulatorBridge
    Jan 10 20:59:39  Simulator[416] : Error communicating with SimulatorBridge: NSObjectNotAvailableException - Unable to connect to SimulatorBridge
    Jan 10 20:59:39  Simulator[416] : Error communicating with SimulatorBridge: NSObjectNotAvailableException - Unable to connect to SimulatorBridge
    Jan 10 21:00:21  Simulator[429] : Error communicating with SimulatorBridge: NSObjectNotAvailableException - Unable to connect to SimulatorBridge
    Jan 10 21:00:21  Simulator[429] : Error communicating with SimulatorBridge: NSObjectNotAvailableException - Unable to connect to SimulatorBridge
    Jan 10 21:02:45  Simulator[447] : Error communicating with SimulatorBridge: NSObjectNotAvailableException - Unable to connect to SimulatorBridge
    Jan 10 21:02:45  Simulator[447] : Error communicating with SimulatorBridge: NSObjectNotAvailableException - Unable to connect to SimulatorBridge
    Jan 10 21:14:06  Simulator[447] : Error communicating with SimulatorBridge: NSObjectNotAvailableException - Unable to connect to SimulatorBridge
    Jan 10 21:14:06  Simulator[447] : Error communicating with SimulatorBridge: NSObjectNotAvailableException - Unable to connect to SimulatorBridge
    Jan 10 21:45:21  Simulator[447] : Error communicating with SimulatorBridge: NSObjectNotAvailableException - Unable to connect to SimulatorBridge
    Jan 10 21:45:21  Simulator[447] : Error communicating with SimulatorBridge: NSObjectNotAvailableException - Unable to connect to SimulatorBridge

1 个答案:

答案 0 :(得分:0)

退出xcode并杀死pid并关闭并退出模拟器。 再次午餐xcode并转到窗口 - > divices - >删除所有设备并添加它,它将起作用。