[英]iOS External accessories framework to connect iPod using bluetooth
I am using EADemo from apple 我正在使用Apple的EADemo
https://developer.apple.com/library/content/samplecode/EADemo/Introduction/Intro.html#//apple_ref/doc/uid/DTS40010079-Intro-DontLinkElementID_2 https://developer.apple.com/library/content/samplecode/EADemo/Introduction/Intro.html#//apple_ref/doc/uid/DTS40010079-Intro-DontLinkElementID_2
This is basically External Accessories framework demo code 这基本上是外部附件框架的演示代码
My info.plist have 我的info.plist有
<key>UIBackgroundModes</key>
<array>
<string>audio</string>
<string>bluetooth-central</string>
<string>bluetooth-peripheral</string>
<string>external-accessory</string>
<string>fetch</string>
<string>location</string>
<string>newsstand-content</string>
<string>remote-notification</string>
</array>
<key>UISupportedExternalAccessoryProtocols</key>
<array>
<string>com.apple.p1</string>
<string>com.apple.p2</string>
</array>
_eaSessionController = [EADSessionController sharedController];
_accessoryList = [[NSMutableArray alloc] initWithArray:[[EAAccessoryManager sharedAccessoryManager] connectedAccessories]];
if ([_accessoryList count] == 0) {
[_noExternalAccessoriesPosterView setHidden:NO];
} else {
[_noExternalAccessoriesPosterView setHidden:YES];
}
The count is always 0. I have paired a Mac Mini and an iPod with the device I am using and I believe these two are MFi complaint obviously. 该计数始终为0。我已将Mac Mini和iPod与正在使用的设备配对,我相信这两个显然是MFi投诉。
What am I missing ? 我想念什么? can anybody help please ? 有人可以帮忙吗?
Okay After a huge research I found this. 好吧,经过大量研究,我发现了这一点。 First of all apple does not take an iPod connected through cable or Bluetooth as an accessory. 首先,苹果不带通过电缆或蓝牙连接的iPod作为附件。
Next if any accessories connected through, it will show but you cant communicate with it if it is not under apple's MFi (Made for iOS) licence program and it is induced from iOS 10. Now how do you know the protocol string if the device is under MFi already. 接下来,如果连接了任何附件,它将显示,但如果它不在Apple的MFi(适用于iOS的Made)许可计划下,并且无法从iOS 10导出,则无法与之通信。现在,您如何知道设备使用的协议字符串在MFi下。 Here you need to contact the vendor or manufacturer to get the protocol string as it is sensitive data. 在这里,您需要联系供应商或制造商以获取协议字符串,因为它是敏感数据。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.