有效的iBeacon/BLE beacon应用程序代码示例 [英] Working iBeacon/BLE beacon app code example
本文介绍了有效的iBeacon/BLE beacon应用程序代码示例的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我正在寻找经过测试的android应用示例代码,该示例代码创建了一个虚拟信标并开始对其进行广告宣传.香港专业教育学院已经测试了几个教程/示例,但没有成功.我的目标环境是Galaxy S7上的Android7.
感谢你的帮助.
!
I am looking for a tested working example code of android app that creates a virtual beacon and starts advertising it. Ive tested already couple of tutorials/examples but without success. My target environment is Android 7 on Galaxy S7.
Appreciate your help.
!
推荐答案
Android信标库示例页面上有一个发射机部分,位于此处:
There is a transmitter section on the Android Beacon Library sample page here:
http://altbeacon.github.io/android-beacon-library/samples.html
两项工作的技巧,以便其他应用可以检测到.
Two tips to making this work so it is detectable by another app.
- 设置要传输的信标类型的正确BeaconLayout.您可以在此处查看各种信标类型的信标布局字符串:
https://beaconlayout.wordpress.com
- 如果要传输iBeacon,请确保将公司代码设置为Apple(0x004c),以便将其识别为Apple iBeacon格式.
这篇关于有效的iBeacon/BLE beacon应用程序代码示例的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文