-
Notifications
You must be signed in to change notification settings - Fork 316
FAQ
iOS won't allow writing NDEF into un-formatted tags, so you should first format your tags. For type 2 tags (most NTAG2xx), you can use an app like NFC Tools or NXP Tag Writer to do perform formatting.
It's possible to implement the NDEF formatting ourself through this library, here's an example. However, it's actually an naive approach, since we don't handle the case if the tag is already formatted and we provide no extra lock / memory information before NDEF TLV, so use this code snippet with cautions.
The same as above, please check if the tag is properly formatted, and contain at least 1 NdefMessage
- This NdefMessage can contain only one NdefRecord as TNF_EMPTY
Indeed, currently MifareClassic isn't supported by Core NFC in our tests. It is also not listed in Core NFC's NFCMiFareFamily
Note on getLaunchTagEvent: keep in mind that you can only create intent-filters for the very first NDEF record on an NFC tag! If your intent-filter doesn't match the FIRST record your app will launch but it won't get the tag data. Check out for details: https://stackoverflow.com/questions/25504418/get-nfc-tag-with-ndef-android-application-record-aar/25510642
Also you should add
android:launchMode="singleTask"
to your manifest to prevent launching your app as another task when it is already running.