Skip to main content
Visitor II
January 9, 2021
Solved

Read EEPROM sector of m24lr by CR95HF and LABVIEW

  • January 9, 2021
  • 4 replies
  • 1301 views

Hi

I have discovery M24LR and CR95HF demonstration board, I read and write data by ST application software successfully but when I use DLL file and LABVIEW software according to AN3954 I read just strange data, for example when I read data from tag I read:

800D00FF214A886CE15902E05C5700

according to page 42 of AN3954 the main format is correct but I can't understand the read data, my goal is to read the whole data of EEPROM

    This topic has been closed for replies.
    Best answer by Brian TIDAL

    Hi,

    the reading of the EEPROM is achieved by the READ SINGLE BLOCK or READ MULTIPLE BLOCKS commands of the M24LR (see Datasheet §26.3 and 26.5). So, you just need to format on of these commands into a buffer and send this command to the tag thanks to the CR95HFDll_SendReceive API. Up to 32 blocks can be read thanks to READ MULTIPLE BLOCKS command (only 1 block can be read with READ SINGLE BLOCK). The READ SINGLE BLOCK or READ MULTIPLE BLOCKS will have to be repeated until the user memory is read.

    Rgds

    BT

    4 replies

    Technical Moderator
    January 11, 2021

    Hi Saleh,

    the CR95HFDll_SendReceive sends a USB request to the STM32 MCU on the CR95HF demo board. Then the STM32 MCU sends a SendRecv command to the CR95HF IC (see AN3954 § 2.4.1). The "800D00FF214A886CE15902E05C5700" data is the reply of the CR95HF IC to the SendRecv command. The format of CR95HF Commands and Replies is described in the CR95HF/ST25R95 datasheet (see §5.1 for the command/reply format and §5.6 for the Send receive command description).

    Here is the decoding of the "800D00FF214A886CE15902E05C5700"

    80: Response code. 0x80=Frame correctly received (additionally see CRC/Parity information)

    0D:  length of entire data field of the SendRecv reply

    00FF214A886CE15902E0: data received from the tag

    5C57: original received CRC value

    00: protocol error status (CRC, collision, etc.)

    The data received from tag is therefore 00FF214A886CE15902E0. This looks like a reply to the ISO/IEC 15693 Inventory command with UID = E0 02 59 E1 6C 88 4A 21.

    Rgds

    BT

    Shp.1Author
    Visitor II
    January 12, 2021

    Thanks for your reply

    I need to read the user area of M24LR EEPROM, and there is not any example exactly for my goal and it is really the most important issue for everyone to use this tag and reader, please make me an example of how to read the user sector of the tag EEPROM area. Thanks

    Technical Moderator
    January 12, 2021

    Hi,

    the reading of the EEPROM is achieved by the READ SINGLE BLOCK or READ MULTIPLE BLOCKS commands of the M24LR (see Datasheet §26.3 and 26.5). So, you just need to format on of these commands into a buffer and send this command to the tag thanks to the CR95HFDll_SendReceive API. Up to 32 blocks can be read thanks to READ MULTIPLE BLOCKS command (only 1 block can be read with READ SINGLE BLOCK). The READ SINGLE BLOCK or READ MULTIPLE BLOCKS will have to be repeated until the user memory is read.

    Rgds

    BT

    Shp.1Author
    Visitor II
    January 12, 2021

    Thanks for your help

    I can read EEPROM now currently