iOS版 - 如何在我的应用程序的蓝牙设备集成 [英] iOS - How to integrate bluetooth devices in my app

查看:216
本文介绍了iOS版 - 如何在我的应用程序的蓝牙设备集成的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我试图创造一些应用程序,连接到蓝牙设备。一个简单的事情像蓝牙棒code扫描仪,扫描并发送一个数字我的应用程序。我想知道我的应用程序可以与我的应用程序吧code扫描仪集成到使用它的框架或东西。是否有任何API或例子或教程等,可以帮助我实现这样的事情呢?

I'm trying to create some application that connects to blue tooth devices. A simple thing like a bluetooth barcode scanner that scans and sends a number to my app. I want to know which framework or something to be used in my app that can integrate the barcode scanner with my app. Is there any API or examples or tutorials etc that can help me implement such things?

推荐答案

苹果公司提供了一个名为<一个一个API href=\"https://developer.apple.com/library/ios/#documentation/ExternalAccessory/Reference/ExternalAccessoryFrameworkReference/_index.html\"相对=nofollow>外部附件框架时,它可以用来与通过有线连接配对的蓝牙设备或设备进行交互,苹果连接在该装置的底部。

Apple provides an API called the External Accessory framework, which can be used to interact with paired Bluetooth devices or devices connected through wired, Apple Connector at the base of the device.

不过,为了能够为你的愿望,你将不得不被设计成与iOS设备(意思是兼容的设备使用配对的设备从你的应用程序中,制造商必须在的苹果MFI计划)和设备制造商提供最,你必须添加到您的应用程序的协议的info.plist 文件。

However, to be able to use a paired device from within your application as you desire, you will have to a device that is designed to be compatible with iOS devices (meaning, the manufacturer must be a member of the Apple MFi program) and the device manufacturer most provide a protocol that you must add to your applications info.plist file.

如果您购买一个现成的货架,蓝牙棒code的读者,有一个公平的机会,你不能做你正在尝试做的。如果设备说,它可以集成到定制的iOS应用程序,请咨询设备制造商了解有关设置您的应用程序与他们的硬件交互的进一步支持。

If you have bought an off-the-shelf, Bluetooth barcode reader, there is a fair chance that you can not do what you are trying to do. If the device states that it can be integrated into custom iOS applications, consult the device manufacturer for further support regarding setting up your application to interact with their hardware.

这篇关于iOS版 - 如何在我的应用程序的蓝牙设备集成的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆