在 iOs 应用程序中使用外部点击轮硬件
简介:我有一台 Denon S-52 网络收音机,带有 iPod/iPhone 底座(较旧的 12V 类型,因此较新的设备无法充电,但可以传递音频/控制数据)。该收音机具有一个类似点击轮的外部控件,可以与 iPod nano/classic 等完美配合。由于 iPhone/iPod touch 不再具有任何点击轮功能,因此来自 Denon 点击轮的信号在播放时不再有任何效果(即不再寻找) ,但可以浏览 iOS 上的某些菜单,并且可以播放/暂停。我尝试过的几个点击轮应用程序显然忽略了外部信号。
问题:对于没有 iOs 编程经验(只有 C/C++/C#,加上来自 lynda.com 的客观 C 教程)的人来说,开发一个可以接受信号的基本音频播放器应用有多难从外部 Denon 拨轮在音频文件中寻找(供我自己使用,至少一开始是这样)?我假设这是可能的,因为信号有时会被处理(如上所述),但我很高兴在浪费大量时间和精力之前被证明是错误的。我还假设标准的 99 美元 iOS 开发者会员资格就足够了(因为设备本身已经是 MFi)?或者也许已经存在具有此功能的应用程序?
Intro: I have a Denon S-52 internet radio with an iPod/iPhone dock (the older 12V kind, so charging is not possible with newer devices but audio/control data is passed through). The radio has an external clickwheel-like control that worked beautifully with iPod nano/classic etc. Since the iPhone/iPod touch no longer have any clickwheel functionality, the signals from the Denon clickwheel no longer have any effect while playing (ie no seeking), but can navigate through some menus on iOS, and play/pause works. The few clickwheel apps I've tried obviously ignore the external signals.
Questions: How hard would it be for someone with no iOs programming experience (just C/C++/C#, plus an objective C tutorial from lynda.com) to develop a basic audio player app that would accept signals from the external Denon clickwheel to seek within an audio file (for my own use, at least at first)? I'm assuming this is possible because the signals are sometimes processed (as mentioned above), but I'd be happy to be proven wrong before I waste a lot of time and effort. I also assume a standard $99 iOS developer membership would be enough (since the device itself is already MFi)? Or perhaps an app that has this feature already exists?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
对于没有 iOs 编程经验(只有 C/C++/C#,加上来自 lynda.com 的客观 C 教程)的人来说,开发一个可以接受来自外部 Denon 拨轮的信号的基本音频播放器应用程序有多难?在音频文件中查找(至少在开始时供我自己使用)?
几乎不可能。这不仅仅是弄清楚如何访问坞站连接器并解释感兴趣的信号的挑战。真正的问题是您想要使用这些信号来控制正在播放的音乐,并且您可能正在考虑尝试控制 iPod 应用程序而不是编写自己的音乐播放器。两个应用程序之间的通信充其量是困难的,如果目标应用程序 (iPod) 不提供外部控制机制,则可能无法进行通信。事实上,您是该平台的新手,这并不会让这一切变得更容易。
您最好的希望可能是向 Apple 提交错误,请求此功能,并希望他们能为您添加它。
How hard would it be for someone with no iOs programming experience (just C/C++/C#, plus an objective C tutorial from lynda.com) to develop a basic audio player app that would accept signals from the external Denon clickwheel to seek within an audio file (for my own use, at least at first)?
Nearly impossible. It's not just the challenge of figuring out how to access the dock connector and interpret the signals of interest. The real problem is that you want to use those signals to control music that's playing, and you're probably thinking of trying to control the iPod application rather than writing your own music player. Communicating between two apps is difficult at best, and probably not possible if the target app (iPod) doesn't provide a mechanism for external control. And the fact that you're new to the platform doesn't make any of this easier.
Your best hope is probably to file a bug with Apple requesting this feature and hope that they'll add it for you.
我能够通过越狱我的 iOS 设备来做到这一点,这使我能够访问
/dev/tty.iap
上的 iPod 访问协议通信的串行端口。然后我可以合并类似 iPhone 串行端口教程 中找到的功能(检查 archive.org(如果链接不再有效)来读取传入信号并做出相应响应。更新:一个更好的解决方案似乎是编写一个挂钩到
iPodUI
私有框架的调整并直接拦截命令,然后向音乐播放器发送有关要做什么的消息(有关更多详细信息,请参阅这篇文章)。I was able to do this by jailbreaking my iOS device, which enabled me to access the serial port for iPod Access Protocol communication at
/dev/tty.iap
. Then I could incorporate something like the functions found in this iPhone Serial Port Tutorial (check archive.org if the link no longer works) to read the incoming signals and respond accordingly.Update: An even better solution seems to be to write a tweak hooking into the
iPodUI
private framework and intercept the commands directly, and then message the Music player about what to do (see this post for more details).