tagsnfcrfidiso-15693

Can not read more than 32 blocks in a single READ MULTIPLE BLOCKS command from M24LR


I am trying to read multiple blocks (all of them in a single READ MULTIPLE BLOCKS command) from a M24LR chip through NFC-V.

let writeData = new Uint8Array(5);
writeData[0] = 0x0A; // Flags
writeData[1] = 0x23; // Read multiple block
writeData[2] = 0x00; // Address of starting block (first 8bit) 
writeData[3] = 0x00; // Address (second 8bit)
writeData[4] = 0x1F; // Numbers of block (0x20 is not working)
nfc.transceive(writeData.buffer)
  .then(response => {
    console.log('response: ' + response);
  })
  .catch(error => {
    console.log('error transceive: ' + JSON.stringify(error));
  });

If I am asking for 32 blocks it works well, if I ask for 33 blocks, the command fails with an error.

Is it something that I am doing wrong? Does the READ MULTIPLE BLOCKS command have a limit?


Solution

  • See the datasheet (M24LR64-R: Dynamic NFC/RFID tag IC with 64-Kbit EEPROM with I²C bus and ISO 15693 RF interface, DocID15170 Rev 16, section 26.5; the same also applies to M24LR64E-R, M24LR16E-R, and M24LR04E-R):

    The maximum number of blocks is fixed at 32 assuming that they are all located in the same sector. If the number of blocks overlaps sectors, the M24LR64-R returns an error code.

    Thus, the READ MULTIPLE BLOCKS command for these chips is limited to 32 blocks.