NFC 贴纸/标签编码
因此,我的问题的基本动机有点模糊:
我想跟踪用户对特定商店的忠诚度。每家商店的收银台上都会贴有 NFC 标签。购买时,用户将使用手机上的应用程序(当然可以使用 NFC),贴纸会发回一些指定商店的代码。
现在我的问题是,一,我可以将一个简单的代码发送回我的应用程序,然后将其添加到某个数据库中吗? 此链接位于底部附近,提供“内容选项”的说明我想要其中的。另外,NFC 论坛规范并没有告诉我太多信息(或者我只是没有找对地方)。
另外,我如何实际将此标签/代码粘贴到这些贴纸之一上?如果我自己做,我可以将它们设置为只读吗?
So here is my basic motivation for my question obfuscated a little:
I want to track a users loyalty to a particular store. Each store would have a NFC sticker on the register. On purchase the user would use an app on their phone (NFC available of course) and the sticker would send back some code that designates the store.
Now here is my question, one, can I send a simple code back to my application that is then, for example, added to some database? This link, near the bottom, provides a description of 'Content Options' none of which I want. Also, the NFC-Forum specifications don't tell me much (or I'm just not looking in the right place).
Also, how do I actually put this tag/code onto one of these stickers? If I do it myself can I make them read-only?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
您可以在 NFC 标签上放置任意信息 - 您可以上传的内容和格式没有限制。想象一下 NFC 标签,如果它们是普通的数据存储位置,例如硬盘或 CD,您可以将包含任意内容的任意格式的文件保存到其中。与 NFC 标签相同。
无论如何,有一个推荐的 NFC 论坛标准,名为 NDEF 的内容格式(NFC 论坛数据交换格式是一种轻量级二进制消息格式,旨在
将一个或多个应用程序定义的有效负载封装到单个消息构造中。)
此外,对于特定数据(链接、电话号码、日历事件等),还有另一种推荐的 NFC 论坛标准,称为 RTD(记录类型定义指定用于构建 NFC 论坛应用定义和基于 NDEF 数据格式的第三方使用的标准记录类型的格式和规则)。
因此,实际上您可以使用任意数据格式或 NDEF,对于数据本身,您可以遵循 RTD 建议或不遵循...这取决于您。
对于标签写入,您可以购买一些现有的软件和USB NFC读卡器/写入器,或者您可以编写自己的软件 - 这比较困难,因为您必须知道您想要使用的标签的硬件特性。
所有标签都允许永久数据锁定。
问候,
STeN
www.mautilus.com,[电子邮件受保护]
you can put arbitrary information on the NFC tag - there is no limitation what you can upload and in which format. Think about NFC tags like if they were normal data storage places like e.g. hardrive or CD - to those you can save to them files with arbitrarty format holding the arbitrary content. Same with NFC tags.
Anyway there is recommended NFC Forum standard for the content format called NDEF (NFC Forum Data Exchange Format is a lightweight binary message format designed to
encapsulate one or more application-defined payloads into a single message construct.)
Also for specific data (links, Phone number, calendar event, etc.) there is another recommended NFC Forum standard called RTD (Record Type Definition specifies the format and rules for building standard record types used by NFC Forum application definitions and third parties that are based on the NDEF data format).
So in fact you can use arbitrary data format or NDEF, for the data itself you can follow RTD recommendations or not... It is up to you.
For tag writing you can buy some existing software and USB NFC reader/writer or you can program your own software - this is more difficult, since you must know HW characteristic of tag you would like to use.
All tags allow permanent data locking.
Regards,
STeN
www.mautilus.com, [email protected]
对于 Android 设备,您可以使用所谓的 Android 应用程序记录 (AAR) 创建一个标签。 AAR 包含您的应用程序的包名称,并且 Android 使用一种称为 Beam 的技术自动启动您的应用程序。然后,您可以自由访问 NDEF 消息中包含的其他记录,这些记录可能会以某种方式包含商店的 ID,并联系您的站点。
我已经尝试过 AAR 并且它可以工作,我还创建了一个 NFC Eclipse 插件 当然,如果您有 Android 手机和一些标签,这将使您立即启动并运行;-)
For Android devices, you would create a tag with an so-called Android Application Record (AAR). The AAR contains the package name of your application, and, using a technology called Beam, Android automatically launches your application. You are then free to access the other records contained within the NDEF message, which then probably would contain the id of the shop somehow, and contact your site.
I have tried AAR already and it works, also I have created an NFC Eclipse plugin which would get you up and running in no time, if you have an Android phone and some tag, of course ;-)