Tuesday, February 22, 2011

[android-developers] Question about intent filters for NFC tags (tech)

I'm reading the documentation on NFC tags and intent filters to match
on. For an action of ACTION_TECH_DISCOVERED, the intent filter must
list the technologies to match on, using a filter file. What I wanted
clarification on is whether or not I need to also specify for example
NfcA when I'm looking for a Mifare Utralight tag.

For the Mifare Ultralight tag, the documentation says this:
NfcA will also be enumerated on the tag, because all MIFARE Ultralight
tags are also NfcA tags.

This suggests to me that my XML filter file should say this:

<resources xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
<tech-list>
<tech>android.nfc.tech.NfcA</tech>
<tech>android.nfc.tech.MifareUltralight</tech>
</tech-list>
</resources>

because if the tag is enumerating NfcA in addition to
MifareUltralight, my intent filter will only match if I specify both
technologies, not just MifareUltralight. Is that true? This applies to
IsoDep as well, which enumerates both NfcA and NfcB, in which case I
would need to specify all three. True? I don't have available hardware
to test this for myself. Thanks for your help.

--
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscribe@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

0 Comments:

Post a Comment

Subscribe to Post Comments [Atom]

<< Home


Real Estate