Android NfcV (ISO 15693) tag

后端 未结 3 1156
旧时难觅i
旧时难觅i 2021-01-07 14:22

Is it possible to write data to specific blocks in memory on the NfcV (ISO 15693) tag? E.g. write data to block# 5 or any specific block#.

I am new to NFC technologi

相关标签:
3条回答
  • 2021-01-07 15:00

    The exact details depend on which ISO 15693 compatible chip is inside the tag. The ISO 15693-3 standard lists different write commands. Support for these are all optional, so your tag may support one or more of these or even use a proprietary command for writing data. I would recommend to look up the datasheet of the chip and/or acquire the ISO standard to find out what the right command is.

    Once you know what the right command is, you can simply pass the bytes of the command in a byte array to the NfcV.transceive() method. (Usually the command bytes consist of a flag byte, followed by a write command byte, one or more block bytes and the data bytes to be written.)

    0 讨论(0)
  • 2021-01-07 15:04

    I guess the android framework does not handle the response from the ISO15693 tags very well. I have been playing with HF-I tags. Few commands work flawlessly and for few other commands the NFC stack throws TAG Lost exception.

    0 讨论(0)
  • 2021-01-07 15:11

    Tried the following: Getting the "Tag was lost" Exception:

            nfc.connect();
            byte[] arrByt = new byte[7];
            arrByt[0] = 0x40;
            arrByt[1] = 0x21;
            arrByt[2] = 0x06;
            arrByt[3] = 0x00;
            arrByt[4] = 0x00;
            arrByt[5] = 0x00;
            arrByt[6] = 0x00;           
            byte[] response = nfc.transceive(arrByt);
    
    0 讨论(0)
提交回复
热议问题