Android Host Card Emulation with Arduino

余生颓废 提交于 2019-12-04 19:13:51

With Android HCE you emulate an ISO 14443-4 (ISO-DEP) contactless smartcard. This smartcard only understands ISO 7816-4 APDU commands. So your Android app registers for certain AIDs (smartcard application DF names). In order to communicate with your app, you need to select your app by issuing a SELECT [by DF name] APDU for one of these AIDs. After this SELECT command, all properly formatted APDU commands will be forwarded to your app's HCE service until another AID is selected with a fresh SELECT [by DF name] command.

Your Arduino application, however, tries to access a MIFARE Classic card (i.e. it issues authenticate, write and read commands). MIFARE Classic uses a different protocol (neither compliant to ISO 14443-4 nor using ISO 7816-4 APDUs), so this protocol cannot be used to interact with an Android HCE emulated smartcard.

As far as I know, the Arduino library for the NFC shield curently does not implement ISO-DEP communication, so you would need to implement that protocol and operation mode of the PN532 on your own.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!