nfctype3: Support blank tag detection in check presence
authorRavi kumar Veeramally <ravikumar.veeramally@linux.intel.com>
Fri, 17 Aug 2012 11:16:58 +0000 (14:16 +0300)
committerSamuel Ortiz <sameo@linux.intel.com>
Tue, 21 Aug 2012 07:22:35 +0000 (09:22 +0200)
System code 0x12FC is used to find NDEF in Type-3 tags. In case
of blank tags, tag does not support system code 12FC. So polling
with 0xFFFF system code returns ID if tag is in range.

plugins/nfctype3.c

index 8f1bfaa..7dbd577 100644 (file)
@@ -668,8 +668,8 @@ static int nfctype3_check_presence(uint32_t adapter_idx,
 
        /* CMD POLL */
        cmd.cmd  = CMD_POLL;    /* POLL command */
-       cmd.data[0] = 0x12;     /* System code (NFC SC) */
-       cmd.data[1] = 0xFC;
+       cmd.data[0] = 0xFF;     /* System code */
+       cmd.data[1] = 0xFF;
        cmd.data[2] = 01;       /* request code */
        cmd.data[3] = 0x00;     /* time slot */