NFC Access Control Doorlock System/Nexus as RFID tag

3.5k Views Asked by At

I've got a pet project that is to essentially build out an NFC access control doorlocking system for my house. I originally wanted to replicate my office keycard on my nexus s but ran into a wall after I learned that card emulation is impossible without a firmware hack on the secure element. My question is, if I were to create my own security eco-system, hardwaring my own RFID system into a pre-existing electronic lock, is there anything stopping me from using my phone as the RFID tag even without access to the secure element?

in short, can the phone itself be the tag without the info being in the secure element?

would i have to create a P2P relationship with the reader?

1

There are 1 best solutions below

5
On

You can write an application that emulates an NFC tag.

Assuming you have an Android phone

NdefRecord record = new NdefRecord(...);
NdefMessage message = new NdefMessage(new NdefRecord[] {
    textRecord
});
NfcAdapter nfcAdapter = NfcAdapter.getDefaultAdapter(getContext());

if (nfcAdapter != null) {
    nfcAdapter.setNdefPushMessage(message, activity);
}

http://developer.android.com/reference/android/nfc/NfcAdapter.html

This Android Ndef Push Example uses an older version of the API.

If you have a Blackberry, they have a similar API.

NDEFMessage message = /* create a message */;
virtualTag = new VirtualNDEFTag(message);
virtualTag.startEmulation();

http://www.blackberry.com/developers/docs/7.1.0api/net/rim/device/api/io/nfc/emulation/VirtualNDEFTag.html