我开发了汽车 CarPlay 应用程序。应用程序适用于 iOS 11 和 12 Carplay 模拟器。我正在尝试在 iOS 13 CarPlay 模拟器上运行应用程序,但应用程序未出现在 CarPlay 模拟器上。
我运行了以下命令:
defaults write com.apple.iphonesimulator CarPlayExtraOptions -bool YES
defaults write com.apple.iphonesimulator CarPlayProtocols -array-add com.mycarbundle.app
defaults write com.apple.iphonesimulator CarPlay -bool YES
1.Carplay Connect
NotificationCenter.default
.addObserver(forName: UIScreen.didConnectNotification,
object: nil,
queue: .main) { (notification) in
print("Carplay Connected")
}
2.Carplay DisConnect
NotificationCenter.default
.addObserver(forName: UIScreen.didDisconnectNotification,
object: nil,
queue: .main) { (notification) in
print("Carplay DisConnected")
}
这个方法没有被调用。 如果有人在 iOS 13 中做过,请帮助我?
谢谢
最佳答案
Xcode 11.0 和 11.2.1 版本未在模拟器中显示 carplay 应用程序。这是一个 xcode 错误。它现在可以在 Xcode 11.3 beta 上运行。
关于swift - Carplay 应用程序未在 iOS 13 模拟器上显示,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/59031529/