2

我正在尝试通过 NFC-V从M24LR芯片读取多个块(所有这些块都在一个 READ MULTIPLE BLOCKS 命令中)。

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));
  });

如果我要求 32 个块,它运行良好,如果我要求 33 个块,则命令失败并出现错误。

我做错了什么吗?READ MULTIPLE BLOCKS 命令是否有限制?

4

1 回答 1

2

请参阅数据表(M24LR64-R:具有 64-Kbit EEPROM 和 I²C 总线和 ISO 15693 RF 接口的动态 NFC/RFID 标签 IC,DocID15170 Rev 16,第 26.5 节;同样适用于M24LR64E-RM24LR16E-RM24LR04E -R ):

假设它们都位于同一扇区中,则最大块数固定为 32。如果块数与扇区重叠,则 M24LR64-R 返回错误代码。

因此,这些芯片的 READ MULTIPLE BLOCKS 命令被限制为 32 个块。

于 2018-07-30T09:49:48.087 回答