What to use to do NFC tag emulation in Android app

2.9k views Asked by At

Is there an opportunity to emulate the NFC tag through an android application? So that it is exactly the tag that is read by another device without a third-party application. That is, it is not the implementation of data reception and transmission that is needed, but an imitation, for example, NFC cards that can be used as a key to some command on a smartphone (for example, a wifi connection).

HCE is not sure what is suitable in this case, but I may be wrong.

If it is possible, please tell me what and how to use it?

P2P data transmission via NFC is not suitable because it requires a receiver application

1

There are 1 answers

2
Andrew On

Android HCE can emulate a specific type of NFC Tag, a NFC Type 4A (it cannot emulate the other 4 main NFC standard types, or propitiatory types like Mifare Classic)

This type of Tag is very flexible in how it responds to a reader, but because of the flexibility the Tag response needs to be matched to what the NFC reader is expecting, if you are programming the NFC reader then this should not be a problem.

As a more specific example here is a fully working example of HCE on Android that responds as a Type 4A Tag with a Standard Ndef data format message (This can be read automatically by most phones, but most USB readers can only read this if they are programmed to).

As the question is very vague, it is difficult to give more direction other than study details about Type 4 Tags and the working example of HCE.